|
| 1 | +name: HTTP 1252 precompile probe |
| 2 | + |
| 3 | +on: |
| 4 | + workflow_dispatch: |
| 5 | + push: |
| 6 | + branches: |
| 7 | + - codex/http-1252-precompile-probe |
| 8 | + |
| 9 | +jobs: |
| 10 | + precompile: |
| 11 | + name: Julia ${{ matrix.julia-version }} / ${{ matrix.os }} / workload=${{ matrix.workload }} |
| 12 | + runs-on: ${{ matrix.os }} |
| 13 | + timeout-minutes: 20 |
| 14 | + strategy: |
| 15 | + fail-fast: false |
| 16 | + matrix: |
| 17 | + os: |
| 18 | + - ubuntu-22.04 |
| 19 | + - ubuntu-24.04 |
| 20 | + julia-version: |
| 21 | + - '1.10.11' |
| 22 | + - '1.11.9' |
| 23 | + - '1.12.6' |
| 24 | + workload: |
| 25 | + - enabled |
| 26 | + - disabled |
| 27 | + |
| 28 | + steps: |
| 29 | + - uses: actions/checkout@v4 |
| 30 | + |
| 31 | + - uses: julia-actions/setup-julia@v2 |
| 32 | + with: |
| 33 | + version: ${{ matrix.julia-version }} |
| 34 | + |
| 35 | + - name: Show platform |
| 36 | + run: | |
| 37 | + uname -a |
| 38 | + julia -e 'versioninfo()' |
| 39 | +
|
| 40 | + - name: Instantiate clean repro project |
| 41 | + env: |
| 42 | + JULIA_PKG_PRECOMPILE_AUTO: "0" |
| 43 | + HTTP1252_WORKLOAD: ${{ matrix.workload }} |
| 44 | + run: | |
| 45 | + set -euxo pipefail |
| 46 | + mkdir repro |
| 47 | + cd repro |
| 48 | + julia --project=. -e ' |
| 49 | + using Pkg |
| 50 | + Pkg.add(Pkg.PackageSpec(name="HTTP", version="2.0.0")) |
| 51 | + Pkg.add(Pkg.PackageSpec(name="Reseau", version="1.1.4")) |
| 52 | + if get(ENV, "HTTP1252_WORKLOAD", "enabled") == "disabled" |
| 53 | + Pkg.add(Pkg.PackageSpec(name="Preferences")) |
| 54 | + using Preferences |
| 55 | + set_preferences!("HTTP", "precompile_workload" => false; force=true) |
| 56 | + end |
| 57 | + Pkg.status() |
| 58 | + ' |
| 59 | +
|
| 60 | + - name: Precompile with interrupt diagnostics |
| 61 | + run: | |
| 62 | + set -euxo pipefail |
| 63 | + cd repro |
| 64 | + cat > run_precompile.jl <<'JL' |
| 65 | + using Pkg |
| 66 | + Pkg.precompile() |
| 67 | + JL |
| 68 | + julia --project=. run_precompile.jl & |
| 69 | + pid=$! |
| 70 | + deadline=$((SECONDS + 300)) |
| 71 | + while kill -0 "$pid" 2>/dev/null; do |
| 72 | + if [ "$SECONDS" -ge "$deadline" ]; then |
| 73 | + echo "::warning::Pkg.precompile still running after 300s; sending SIGINT for stack diagnostics" |
| 74 | + kill -INT "$pid" || true |
| 75 | + sleep 20 |
| 76 | + if kill -0 "$pid" 2>/dev/null; then |
| 77 | + echo "::warning::Pkg.precompile still running after SIGINT; sending SIGTERM" |
| 78 | + kill -TERM "$pid" || true |
| 79 | + fi |
| 80 | + wait "$pid" |
| 81 | + exit $? |
| 82 | + fi |
| 83 | + sleep 5 |
| 84 | + done |
| 85 | + wait "$pid" |
0 commit comments