Skip to content

Update Effect to 4.0.0 - #66

Merged
adelrodriguez merged 5 commits into
mainfrom
update-effect-4.0.0
Oct 2, 2026
Merged

adelrodriguez merged 5 commits into
mainfrom
update-effect-4.0.0

Conversation

@adelrodriguez

@adelrodriguez adelrodriguez commented Oct 1, 2026 •

Copy link
Copy Markdown
Owner

Effect v4 has a stable release now, so we move from 4.0.0-rc.118 to 4.0.0. The one breaking change that affects us: Array.partition now returns [passes, fails] instead of [fails, passes]. All five call sites have the destructuring swapped. The type checker catches four of them. At install.ts:154, both sides have the same type, so only the install tests catch a wrong order there. ADR 0001 now states the new order. The Packref reference for Effect is synced to 4.0.0 too.

adamantite moves to 0.42.0 too. 0.41.0 pinned Effect rc.115, and a fresh resolve paired it with @effect/platform-node-shared@4.0.0, so adamantite check and adamantite analyze crashed. 0.42.0 runs on Effect 4.0.0, so the lockfile now holds a single Effect version.

A new pnpm-workspace.yaml exempts adamantite from pnpm 12's default one-day minimumReleaseAge. We maintain adamantite, so its new releases install right away. All other packages still need to be one day old.

Verified locally: adamantite check, adamantite analyze, unit tests, and build:verify pass.

Changes made by Claude Opus 5.5 in Claude Code.

🤖 Generated with Claude Code

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

ℹ️ No critical issues. There are two documentation nits.

Reviewed changes

This review covers the change from Effect 4.0.0-rc.118 to 4.0.0 and the updates to the Array.partition call sites.

  • Effect pins moved to 4.0.0. effect and @effect/platform-node changed in package.json, pnpm-lock.yaml, and the Packref lock entry. The upstream tag effect@4.0.0 exists, so packref install can resolve the entry.
  • Array.partition destructuring swapped. All five call sites in install.ts, remove.ts, and sync.ts now read [passes, fails]. This agrees with the 4.0.0 implementation in effect/src/Array.ts. In rc.118 and 4.0.0, Effect.partition, Option.partition, Record.partition, and Array.separate also swap their order. src/ does not use them.
  • The tsc claim is not true for one site. At install.ts:156, both sides of the partition are PackageEntry, so the type checker cannot find a wrong order. I reverted only that swap as a test: tsc stayed clean, and 10 tests failed in the two install.test.ts files. The tests cover this site.
  • adamantite's Effect copy stays on rc.116. The lockfile entry that was kept by hand is the same as on main, and pnpm install --frozen-lockfile accepts it.

With a temporary minimumReleaseAge: 0 override, these all pass: check, tsc --noEmit, analyze, the unit tests (293 passed), and build:verify.

ℹ️ ADR 0001 still gives the old Array.partition order

docs/adr/0001-use-packref-for-dependency-source-inspection.md tells contributors and agents that "the locked Effect version" returns "transformed failure and success arrays as a tuple". After this PR, the locked version returns successes first. An agent that follows the ADR can write [failures, successes]. If both sides have the same type, as at install.ts:156, tsc does not find the error.

Technical details
# ADR 0001 describes the rc-era `Array.partition` tuple order

## Affected sites
- docs/adr/0001-use-packref-for-dependency-source-inspection.md:21-22 — "returns transformed failure and success arrays as a tuple" states the `rc.118` order `[excluded, satisfying]`.

## Required outcome
- The ADR states the `4.0.0` order: `[passes, fails]` (success array first, failure array second).

Pullfrog  | Fix all ➔ | Fix 👍s ➔ | View workflow run | Using claude-opus-5-5 | 𝕏

Comment thread .changeset/stable-effect-four.md

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Important

The fresh lockfile resolution makes the repository check command fail.

Reviewed changes

This review covers the lockfile rebuilt after the prior Pullfrog review.

  • Re-resolved the dependency graph. pnpm-lock.yaml refreshed transitive packages, including Redis, Vite, and Changesets dependencies.
  • Changed Adamantite's nested Effect graph. Adamantite still uses effect@4.0.0-rc.115, but its @effect/platform-node-shared resolution moved to stable 4.0.0.

Pullfrog  | Fix all ➔ | Fix 👍s ➔ | View workflow run | Using gpt-5.6-terra | 𝕏

Comment thread pnpm-lock.yaml Outdated

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

ℹ️ No new issues found in this delta. A prior documentation follow-up remains open.

Reviewed changes

This review covers the Adamantite 0.42.0 update since the prior Pullfrog review.

  • Updated Adamantite to stable Effect dependencies. The nested effect, @effect/platform-node, and shared platform package now resolve to compatible stable 4.0.0 releases.
  • Refreshed the development tool dependency graph. The lockfile updates Adamantite and its resolved tooling dependencies.

Pullfrog  | Fix it ➔ | View workflow run | Using gpt-5.6-terra | 𝕏

@pullfrog pullfrog Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

ℹ️ No new issues found in this delta. The prior documentation follow-up remains open.

Reviewed changes

This review covers the pnpm workspace policy added since the prior Pullfrog review.

  • Excluded Adamantite from the release-age policy. The new pnpm-workspace.yaml permits the maintained adamantite update while it keeps the default policy for all other packages.
  • Restored normal frozen installs. pnpm install --frozen-lockfile --prefer-offline and pnpm run check both passed with the committed configuration.

Pullfrog  | Fix it ➔ | View workflow run | Using gpt-5.6-terra | 𝕏

adelrodriguez and others added 5 commits October 2, 2026 10:12
Effect 4.0.0 returns `[passes, fails]` from `Array.partition`, so the
destructuring order at each call site is swapped.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
adamantite 0.42.0 runs on Effect 4.0.0, so `adamantite check` and
`adamantite analyze` no longer crash on a mixed Effect install.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
We maintain adamantite, so a new release does not need the one-day
waiting period before Packref can install it.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
…t line

ADR 0001 now states that `Array.partition` returns `[passes, fails]`.
The pending changeset no longer names `4.0.0-rc.118`, so the release
notes give only one Effect version.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@adelrodriguez
adelrodriguez merged commit a5f7c77 into main Oct 2, 2026
7 checks passed
@adelrodriguez
adelrodriguez deleted the update-effect-4.0.0 branch October 2, 2026 14:35
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