Skip to content

fix: publish registry-compatible SDK dependencies - #811

Merged
roncohen merged 1 commit into
mainfrom
fix/published-workspace-dependencies
Nov 20, 2026
Merged

roncohen merged 1 commit into
mainfrom
fix/published-workspace-dependencies

Conversation

@roncohen

Copy link
Copy Markdown
Contributor

Problem

The published v2 prereleases cannot be installed outside this monorepo: Node ships @reflag/flag-evaluation: workspace:*, React/Vue ship @reflag/browser-sdk: workspace:^, and React Native ships @reflag/react-sdk: workspace:^.

Changesets publishes package directories through npm, which does not perform Yarn's workspace-range rewriting. Successful workspace builds and yarn pack checks therefore missed the broken published manifests.

Changes

  • Use registry-compatible dependency versions in Node, React, Vue and React Native, including Native's development dependency on Node. Yarn still transparently links the matching v2 workspaces locally.
  • Preserve the published evaluator 2.0.0 and the existing v1 OpenFeature dependencies.
  • Validate every non-private workspace manifest before the normal Changesets publish command. Reject workspace: ranges in dependency, optional, peer and development dependency sections; private examples can keep them.
  • Run guard regressions in the existing CI release-safeguard suite. Exercise actual Changesets prerelease versioning to verify regular semver dependency ranges advance correctly, and retain local-link/v1-isolation checks.
  • Add patch Changesets for the four affected SDKs. The current release plan selects 2.0.0-next.2 for Node, React, Vue and React Native; Browser's existing prerelease needs no packaging change.

Verification

  • yarn install --immutable
  • yarn test:release: 17 passing release safeguards
  • yarn lerna run test:ci --stream --concurrency 1: 1,015 passing tests plus 48 Browser E2E cases across Chromium, Firefox and WebKit
  • Sequential evaluator, Node, Browser, React, Vue, Native, both OpenFeature providers and CLI builds; Management TypeScript build from its checked-in generated sources
  • yarn docs, yarn fmt, yarn lint:fix, and whitespace checks. Lint has no errors and retains the existing generated Next.js triple-slash-reference warning.
  • Packed all five SDKs using npm's underlying pacote directory packer, without Yarn manifest rewriting. Installed the candidate artifacts through a temporary loopback registry into a fresh external Yarn consumer, using registry dependencies without workspace links or resolutions. Strict direct-value TypeScript checks pass for all five SDKs; Node/evaluator/Browser/React/Vue runtime imports pass. These are locally packed current-version candidates, not newly published releases.
  • Negative control: the publication guard rejects all four original broken source manifests.

Local build limitation: the root yarn build stops at Management SDK generation because Java is not installed. All package builds listed above, the Management TypeScript build, docs and the full test target pass; the full generator-backed build remains for CI.

Scope and rollout

No package publication, npm-tag changes, deployment, live flag/configuration changes or application migration is included. A reviewed version/release PR and corrected prerelease publication are still required; already published versions cannot be overwritten. The separate, uncommitted CLI v2 generator work is intentionally not bundled into this packaging fix and remains an application-migration prerequisite.

@reflag-review reflag-review Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Risk: medium

no actionable findings

@roncohen
roncohen added this pull request to the merge queue Nov 20, 2026
Merged via the queue into main with commit 9654308 Nov 20, 2026
9 checks passed
@roncohen
roncohen deleted the fix/published-workspace-dependencies branch November 20, 2026 09:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant