Skip to content

ci(release): build dashmate packages from the release's own npm tarballs - #5235

Merged
QuantumExplorer merged 1 commit into
v5.0-devfrom
ci/dashmate-pack-local-npm-tarballs
Oct 1, 2026
Merged

QuantumExplorer merged 1 commit into
v5.0-devfrom
ci/dashmate-pack-local-npm-tarballs

Conversation

@QuantumExplorer

@QuantumExplorer QuantumExplorer commented Oct 1, 2026 •

Copy link
Copy Markdown
Member

Basic explanation

When we publish a release, CI builds the dashmate installers (deb, Windows, macOS, tarballs). Building them installs dashmate's own packages (wallet-lib, dapi-client, wasm-dpp and so on) from npm. Those packages were uploaded to npm a moment earlier in the same run, and npm can take a long time to start serving a version it has just accepted. So the build waited up to 15 minutes for npm and then gave up.

That is what happened in the 5.0.0-beta.1 release: npm accepted @dashevo/wasm-dpp2 at 00:23:02 but only served it from 00:41:19, so all four installer builds failed and no dashmate installers were attached to the release.

This PR builds the installers from the npm tarballs the release job already has on disk, the same files it uploads to npm. Nothing waits on npm any more.

Issue being fixed or feature implemented

Release run 36792086924 for v5.0.0-beta.1: every "Build Dashmate packages" job failed at "Wait for published NPM packages to become resolvable" with

Timed out after 900s waiting for npm packages to become resolvable:
@dashevo/wasm-dpp2@5.0.0-beta.1

and every "Release Dashmate packages" job then failed for lack of an installer.

What was done?

  • scripts/pack_dashmate.sh takes an optional DASHMATE_NPM_TARBALLS_DIR, a directory of npm tarballs. When it is set, the script reads each tarball's package name and adds a resolutions entry pointing at the tarball, so yarn installs every one of those packages (direct or transitive) from disk. The paths are absolute because oclif pack installs again from a copy of the lockfile in its own tmp directory. Without the variable, the script installs from the registry as before.
  • release.yml sets DASHMATE_NPM_TARBALLS_DIR to the npm-packages/ directory the job already downloads from the js-build artifact, and drops the wait step.
  • scripts/wait_for_npm_packages.sh is removed. That step was its only user.

Before, the packaged dashmate's lockfile resolved its workspace packages from the registry:

"@dashevo/wallet-lib@npm:12.0.0-beta.1":

After, from the release's tarballs:

"@dashevo/wallet-lib@file:/home/runner/work/platform/platform/npm-packages/dashevo-wallet-lib-12.0.0-beta.1.tgz::locator=dashmate%40workspace%3A.":

The tarballs are the bytes release-npm validates and publishes, and the packaging job already ran code from the same artifact, so this adds no new source of code.

How Has This Been Tested?

Locally, with the 22 tarballs published for 5.0.0-beta.1 downloaded from npm in place of the CI artifact (the same files), CI=true, and the published dashmate tarball standing in for the yarn pack step, which needs a full monorepo build:

  • pack_dashmate.sh tarballs ran to completion: yarn install, oclif manifest, and oclif pack built both the linux-x64 and linux-arm64 tarballs.
  • In the packaged dashmate's yarn.lock, all 7 workspace packages it pulls in (dapi-client, dapi-grpc, dash-spv, grpc-common, wallet-lib, wasm-dpp, withdrawals-contract) resolve from file: tarballs, and none from npm.
  • The packaged CLI starts: dashmate --version prints dashmate/5.0.0-beta.1.
  • actionlint passes on release.yml.

The real check is the next release run.

Breaking Changes

None.

Checklist:

  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have added or updated relevant unit/integration/functional/e2e tests
  • I have made corresponding changes to the documentation

For repository code-owners and collaborators only

  • I have assigned this pull request to a milestone

🤖 Generated with Claude Code

PR Hygiene · 9421321

  • Bots — coderabbitai not yet · thepastaclaw not yet — /skip-bots proceeds without the ones not yet reported
  • Self-review — post /self-reviewed once the bots are done
  • Within your 5 open PRs
  • Build running
  • Approvals
    • github (.github/workflows/release.yml) — ktechmidas or shumkov
    • files with no dedicated owner — you own it

When every box is checked the PR Hygiene check passes and this can merge.

The dashmate packaging jobs installed dashmate's workspace dependencies
from the npm registry, so they first waited for every just-published
version to become resolvable, giving up after 15 minutes. In the
5.0.0-beta.1 release npm accepted @dashevo/wasm-dpp2 at 00:23:02 but
only served it from 00:41:19, so all four packaging jobs timed out and
no dashmate installers were attached.

pack_dashmate.sh now takes DASHMATE_NPM_TARBALLS_DIR, a directory of
npm tarballs, and resolves every package in it from its tarball through
`resolutions` with absolute `file:` paths (oclif pack installs again
from a copy of the lockfile in its own tmp directory). The release job
points it at the npm-packages/ tarballs it already downloads, the same
files release-npm publishes, and the wait step and its script go away.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@QuantumExplorer QuantumExplorer added this to the v5.0.0 milestone Oct 1, 2026
@github-actions github-actions Bot added the waiting-bots Waiting for the review bots to report on this head label Oct 1, 2026
@coderabbitai

coderabbitai Bot commented Oct 1, 2026

Copy link
Copy Markdown
Contributor

Review in Change Stack →

Navigate logical layers of code changes, visualize relationships, and explore their blast radius.

Note

Currently processing new changes in this PR. This may take a few minutes, please wait...

⚙️ Run configuration

Configuration used: Repository: dashpay/platform/.coderabbit.yaml

Review profile: CHILL

Plan: Advanced

Run ID: c2d9d59f-b0d4-4250-9c52-109d90e47890

📥 Commits

Reviewing files that changed from the base of the PR and between b95849a and 9421321.

📒 Files selected for processing (3)
  • .github/workflows/release.yml
  • scripts/pack_dashmate.sh
  • scripts/wait_for_npm_packages.sh
 _______________________________________________________________________________________
< Analyze workflow to improve concurrency. Exploit concurrency in your user's workflow. >
 ---------------------------------------------------------------------------------------
  \
   \   (\__/)
       (•ㅅ•)
       /   づ
✨ Finishing Touches
📝 Generate docstrings
  • Commit to this branch
  • Create a new PR
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR
  • Autopilot · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Autopilot is currently an internal CodeRabbit preview.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

waiting-bots Waiting for the review bots to report on this head

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant