fix: migrate to effect 4.0.0-beta.97 Schedule/Config APIs#370
Merged
Conversation
effect 4.0.0-beta.94–97 removed Schedule.either/Schedule.both/Schedule.tapOutput:
- Schedule.either(a, b) -> Schedule.min([a, b])
- Schedule.both(a, b) -> Schedule.max([a, b])
- Schedule.tapOutput(f) -> Schedule.tap(f) with Metadata callback ({ attempt } is 1-based)
- Schedule.modifyDelay callbacks now receive Metadata instead of the bare delay Duration
Also provide a fresh ConfigProvider.fromEnv() in readServerRetryHintCapMsFromEnv / resolveServerRetryHintCapMs since the new default ConfigProvider caches env reads.
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Contributor
|
Install the packages built from this commit: @distilled.cloud/core bun add @distilled.cloud/core@https://pkg.distilled.cloud/core/4a00825@distilled.cloud/aws bun add @distilled.cloud/aws@https://pkg.distilled.cloud/aws/4a00825@distilled.cloud/axiom bun add @distilled.cloud/axiom@https://pkg.distilled.cloud/axiom/4a00825@distilled.cloud/azure bun add @distilled.cloud/azure@https://pkg.distilled.cloud/azure/4a00825@distilled.cloud/cloudflare bun add @distilled.cloud/cloudflare@https://pkg.distilled.cloud/cloudflare/4a00825@distilled.cloud/coinbase bun add @distilled.cloud/coinbase@https://pkg.distilled.cloud/coinbase/4a00825@distilled.cloud/expo-eas bun add @distilled.cloud/expo-eas@https://pkg.distilled.cloud/expo-eas/4a00825@distilled.cloud/fly-io bun add @distilled.cloud/fly-io@https://pkg.distilled.cloud/fly-io/4a00825@distilled.cloud/gcp bun add @distilled.cloud/gcp@https://pkg.distilled.cloud/gcp/4a00825@distilled.cloud/kubernetes bun add @distilled.cloud/kubernetes@https://pkg.distilled.cloud/kubernetes/4a00825@distilled.cloud/mongodb-atlas bun add @distilled.cloud/mongodb-atlas@https://pkg.distilled.cloud/mongodb-atlas/4a00825@distilled.cloud/neon bun add @distilled.cloud/neon@https://pkg.distilled.cloud/neon/4a00825@distilled.cloud/planetscale bun add @distilled.cloud/planetscale@https://pkg.distilled.cloud/planetscale/4a00825@distilled.cloud/posthog bun add @distilled.cloud/posthog@https://pkg.distilled.cloud/posthog/4a00825@distilled.cloud/prisma-postgres bun add @distilled.cloud/prisma-postgres@https://pkg.distilled.cloud/prisma-postgres/4a00825@distilled.cloud/stripe bun add @distilled.cloud/stripe@https://pkg.distilled.cloud/stripe/4a00825@distilled.cloud/supabase bun add @distilled.cloud/supabase@https://pkg.distilled.cloud/supabase/4a00825@distilled.cloud/turso bun add @distilled.cloud/turso@https://pkg.distilled.cloud/turso/4a00825@distilled.cloud/typesense bun add @distilled.cloud/typesense@https://pkg.distilled.cloud/typesense/4a00825@distilled.cloud/workos bun add @distilled.cloud/workos@https://pkg.distilled.cloud/workos/4a00825 |
The standalone repo still resolved effect@4.0.0-beta.66, so CI failed on the beta.97 Schedule APIs that the parent workspace already compiles against. - bump the effect catalog floor from beta.66 to beta.97 and refresh bun.lock - extend minimumReleaseAgeExcludes with fast-check and the @effect/* platform packages so the fresh effect resolves - remove "noCheck": true from aws/cloudflare/gcp/azure tsconfigs so tsgo actually type-checks those packages again - oxfmt drift in aws/src/hash from the refreshed toolchain Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Both packages were verified to type-check clean against effect@4.0.0-beta.97, but full checking is too heavy for these generated codebases as a routine build step. gcp and azure stay checked. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
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.
Migrate to the Schedule/Config APIs in
effect@4.0.0-beta.97(beta.94–97 removedSchedule.either,Schedule.both, andSchedule.tapOutput, breaking downstream consumers — see theTypeError: Schedule.either is not a functionreport against alchemy).Schedule.either(a, b)→Schedule.min([a, b])(union: recur while any recurs, shortest delay)Schedule.both(a, b)→Schedule.max([a, b])(intersection: recur while all recur, longest delay)Schedule.tapOutput(f)→Schedule.tap(f)— the callback now receives scheduleMetadata;attemptis 1-based (the oldrecursoutput was 0-based), so(attempt + 1) * 10becomesattempt * 10Schedule.modifyDelaycallbacks now receiveMetadatainstead of the delay:(duration) => ...→({ duration }) => ...ConfigProvidercaches env reads, soreadServerRetryHintCapMsFromEnv/resolveServerRetryHintCapMsnow provide a freshConfigProvider.fromEnv()per read to keep observing the currentprocess.envToolchain
effectcatalog floor from beta.66 to beta.97 and refreshbun.lock— the repo previously resolvedeffect@4.0.0-beta.66, which is why CI failed on the new Schedule APIsminimumReleaseAgeExcludeswithfast-check(new effect dependency) and the@effect/platform-*packagesnoCheckfrom the gcp and azure tsconfigs; aws and cloudflare were verified to type-check clean against beta.97 but keepnoCheckintentionally — full checking is too heavy for those generated codebases as a routine build step🤖 Generated with Claude Code