Fix Windows binary builds and decouple npm publish from all-binaries-succeed requirement#144
Merged
jasdeepkhalsa merged 2 commits intomasterfrom Mar 7, 2026
Merged
Conversation
Windows binary builds: - Add `spc.exe doctor --auto-fix` before download/build (mirrors Unix) - Pre-create `source/` directory to fix SPC v2.8.2 Windows bug where `7za | tar -C source\php-src` fails with 'system cannot find path' Publish job (npm + GitHub Release): - Change `needs: build-binary` → `needs: [build-phar, build-binary]` with `if: !cancelled() && build-phar succeeded` so publish runs even when individual platform binary builds fail - Replace hard-fail `cp` with `copy_binary()` helper that warns and continues when a binary artifact is missing - Skip npm publish for packages without a binary (checks both dbdiff and dbdiff.exe to handle Unix and Windows packages correctly) - Use glob patterns in GitHub Release `files:` so only existing binaries are attached (missing ones silently omitted, already warned about in the copy step) Co-authored-by: jas-os <262199218+jas-os@users.noreply.github.com>
|
Copilot
AI
changed the title
[WIP] Fix binary failures in DBDiff release and adjust npm step
Fix Windows binary builds and decouple npm publish from all-binaries-succeed requirement
Mar 7, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



Windows builds (
win32-x64,win32-arm64) consistently failed in the Release workflow, and thepublishjob was blocked from running whenever any binary failed.Windows fix
Root cause: SPC v2.8.2 on Windows runs
7za -so archive.tar.xz | tar -C source\php-src --strip-components 1duringspc build, but never createssource\php-srcbeforehand — tar exits with "The system cannot find the path specified." Thedoctor --auto-fixstep present on Unix was also absent from the Windows path.Fix: Mirror Unix behaviour — run
doctor --auto-fixfirst, then pre-create thesource\directory beforedownload/build:Note:
darwin-x64was listed as failed but was actually cancelled mid-run by a manual workflow cancellation — not a genuine build failure.Resilient publish job
Root cause:
needs: build-binaryrequires every matrix job to succeed; one Windows failure skipped the publish entirely — blocking the PHAR, Docker, and all successful Linux/macOS binaries from being released.Changes:
needs: build-binary→needs: [build-phar, build-binary]withif: ${{ !cancelled() && needs.build-phar.result == 'success' }}— publish runs whenever the PHAR is ready, regardless of individual binary failurescopy_binary()helper that emits::warning::and continues on missing files instead of abortingdbdiffanddbdiff.exe)files:uses globs (binaries/dbdiff-*/dbdiff,binaries/dbdiff-*/dbdiff.exe) so only produced binaries are attached; missing ones are silently omitted (already warned in the copy step)Warning
Firewall rules blocked me from connecting to one or more addresses (expand for details)
I tried to connect to the following addresses, but was blocked by firewall rules:
static-php.dev/home/REDACTED/work/_temp/ghcca-node/node/bin/node /home/REDACTED/work/_temp/ghcca-node/node/bin/node --enable-source-maps /home/REDACTED/work/_temp/copilot-developer-action-main/dist/index.js(dns block)If you need me to access, download, or install something from one of these locations, you can either:
💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.