Skip to content

debug: round 4 — stage dump inside workspace for artifact upload #5

debug: round 4 — stage dump inside workspace for artifact upload

debug: round 4 — stage dump inside workspace for artifact upload #5

Workflow file for this run

name: debug-mcpp230
on:
push:
branches: [ "debug/mcpp230-windows-repro" ]
permissions:
contents: read
env:
MCPP_VERSION: "0.0.95"
jobs:
win-repro:
runs-on: windows-latest
timeout-minutes: 30
steps:
- uses: actions/checkout@v4
- name: Download mcpp
shell: bash
run: |
curl -L -fsS -o mcpp.zip \
"https://github.com/mcpp-community/mcpp/releases/download/v${MCPP_VERSION}/mcpp-${MCPP_VERSION}-windows-x86_64.zip"
powershell -NoProfile -Command "Expand-Archive -Force -Path 'mcpp.zip' -DestinationPath '.'"
root="$PWD/mcpp-${MCPP_VERSION}-windows-x86_64"
mkdir -p "$HOME/.mcpp/registry"
cp -a "$root/registry/." "$HOME/.mcpp/registry/"
echo "MCPP=$(cygpath -m "$root/bin/mcpp.exe")" >> "$GITHUB_ENV"
- name: repro (expect 0xC0000409)
shell: powershell
continue-on-error: true
env:
MCPP_INDEX_MIRROR: GLOBAL
run: |
cd tests\examples\archive
$p = Start-Process -FilePath $env:MCPP -ArgumentList "test" -NoNewWindow -Wait -PassThru `
-RedirectStandardOutput out.txt -RedirectStandardError err.txt
"RAW EXIT CODE: 0x{0:X8}" -f $p.ExitCode
- name: analyze minidump with cdb
if: always()
shell: powershell
run: |
$cdb = "C:\Program Files (x86)\Windows Kits\10\Debuggers\x64\cdb.exe"
if (!(Test-Path $cdb)) { "cdb not found"; Get-ChildItem "C:\Program Files (x86)\Windows Kits" -Recurse -Filter cdb.exe -ErrorAction SilentlyContinue | Select-Object -First 3 FullName; exit 0 }
$dmp = Get-ChildItem "$env:LOCALAPPDATA\CrashDumps\mcpp.exe.*.dmp" | Select-Object -First 1
if (!$dmp) { "no dump found"; exit 0 }
& $cdb -z $dmp.FullName -c ".exr -1; .ecxr; k 40; lm m mcpp; q"
- name: stage dump into workspace
if: always()
shell: bash
run: |
mkdir -p crashdump
cp "$LOCALAPPDATA"/CrashDumps/mcpp.exe.*.dmp crashdump/ 2>/dev/null || true
cp tests/examples/archive/out.txt tests/examples/archive/err.txt crashdump/ 2>/dev/null || true
ls -la crashdump/
- name: upload dump artifact
if: always()
uses: actions/upload-artifact@v4
with:
name: mcpp-crash-dump
path: crashdump/
if-no-files-found: warn