catchUnfailableEffect β π‘ suggestion
catchUnfailableEffect β π‘ suggestion
Effect.catchAll, Effect.catch, or Effect.mapError are applied to an Effect whose error channel is never. The handler can never be triggered, which signals a logic error or dead code.effectFnIife β β οΈ warning + π§ quick fix
effectFnIife β β οΈ warning + π§ quick fix
Effect.fn and Effect.fnUntraced create reusable named functions. Calling them immediately as an IIFE (immediately invoked function expression) defeats that purpose β use Effect.gen directly instead.Effect.fn(...)() call with Effect.gen.effectGenUsesAdapter β β οΈ warning
effectGenUsesAdapter β β οΈ warning
_) is used inside Effect.gen. The adapter was required in older versions of Effect but is now just an alias for pipe and should be removed.effectInFailure β β οΈ warning
effectInFailure β β οΈ warning
Effect value appears in the error channel (E) of another Effect. The failure channel is intended to hold failure types (plain data), not executable computations. An Effect in the failure channel is never run and suggests a design mistake.effectInVoidSuccess β β οΈ warning
effectInVoidSuccess β β οΈ warning
Effect values in a void success channel. When a function returns void, any Effect returned inside it is silently discarded β it will never be executed, creating a hard-to-spot floating effect.globalErrorInEffectCatch β β οΈ warning
globalErrorInEffectCatch β β οΈ warning
Effect.tryPromise, Effect.try) returns the global Error type. Untagged errors merge together in the failure channel and lose type safety. Use a tagged error class instead.globalErrorInEffectFailure β β οΈ warning
globalErrorInEffectFailure β β οΈ warning
Error type appears in the failure channel of an Effect type annotation. Like globalErrorInEffectCatch, untagged errors are indistinguishable from each other and cannot be handled precisely.layerMergeAllWithDependencies β β οΈ warning + π§ quick fix
layerMergeAllWithDependencies β β οΈ warning + π§ quick fix
Layer.mergeAll call provides a service that another layer in the same call requires. Layer.mergeAll builds layers in parallel, so inter-layer dependencies are not satisfied. Move the dependent layer into a Layer.provideMerge call after the mergeAll.leakingRequirements β π‘ suggestion
leakingRequirements β π‘ suggestion
multipleEffectProvide β β οΈ warning + π§ quick fix
multipleEffectProvide β β οΈ warning + π§ quick fix
Effect.provide is chained multiple times on the same effect. Chaining provide can cause service scope and lifecycle issues because each call creates a separate scope. Compose all layers into one and provide them in a single call.returnEffectInGen β π‘ suggestion + π§ quick fix
returnEffectInGen β π‘ suggestion + π§ quick fix
return statement inside an Effect.gen generator returns an Effect-able value, resulting in a nested Effect<Effect<...>>. This is almost always unintentional β use return yield* to execute and unwrap the inner effect.yield* before the returned expression.runEffectInsideEffect β π‘ suggestion + π§ quick fix (V3 only)
runEffectInsideEffect β π‘ suggestion + π§ quick fix (V3 only)
Runtime methods instead of calling Effect.runSync, Effect.runPromise, or similar functions inside an Effect context. Inside a generator, effects can simply be yielded. When you need to run a child effect using a specific runtime, use Effect.runtime and then the corresponding Runtime.* method.schemaSyncInEffect β π‘ suggestion (V3 only)
schemaSyncInEffect β π‘ suggestion (V3 only)
Schema.decodeUnknown) instead of the synchronous variants (e.g., Schema.decodeUnknownSync) inside Effect generators. The sync methods throw on failure, bypassing Effectβs typed error channel. The Effect-based methods propagate errors through the channel with proper types.scopeInLayerEffect β β οΈ warning + π§ quick fix (V3 only)
scopeInLayerEffect β β οΈ warning + π§ quick fix (V3 only)
Layer.scoped instead of Layer.effect when Scope appears in the layerβs requirements channel. Layer.scoped is the correct constructor for layers that manage scoped resources; using Layer.effect leaves Scope in the requirements, forcing callers to supply it.strictEffectProvide β β off by default
strictEffectProvide β β off by default
Effect.provide with a Layer is used outside of application entry points. Calling Effect.provide inside library code or service implementations can break scope lifetimes. All layers should be composed and provided once at the application entry point.This rule is off by default because there are valid use cases for Effect.provide in non-entry-point code (for example, test helpers). Enable it when you want to enforce strict layer discipline:tryCatchInEffectGen β π‘ suggestion
tryCatchInEffectGen β π‘ suggestion
try/catch inside Effect.gen generators. Exception-based error handling bypasses Effectβs typed error channel, making errors invisible to the type system. Use Effect.try, Effect.tryPromise, Effect.catch, or Effect.catchTag instead.unknownInEffectCatch β β οΈ warning
unknownInEffectCatch β β οΈ warning
Effect.tryPromise, Effect.try) returns unknown. An unknown error type is too wide to handle precisely. Narrow the type or wrap the error in a tagged class to make it useful in the error channel.