Skip to content
TypeScript

chore(lint): disable returnEffectInGen (#25050)

Julius Marminged1f701849b32
diff --git a/apps/server/src/observability/EventLoopMonitor.ts b/apps/server/src/observability/EventLoopMonitor.ts
index 377f0148ca6..32ee54c8b64 100644
--- a/apps/server/src/observability/EventLoopMonitor.ts
+++ b/apps/server/src/observability/EventLoopMonitor.ts
@@ -75,7 +75,6 @@ const makeNodeSampler = Effect.gen(function* () {
let usage = process.resourceUsage();
let sampledAt = NodePerfHooks.performance.now();
- // @effect-diagnostics-next-line returnEffectInGen:off - the read effect is the result.
return Effect.sync(() => {
const nextElu = NodePerfHooks.performance.eventLoopUtilization();
const nextUsage = process.resourceUsage();
diff --git a/apps/server/src/orchestration-v2/LiveStreamBudget.ts b/apps/server/src/orchestration-v2/LiveStreamBudget.ts
index 39ddf5509a8..f8bdd5de2bf 100644
--- a/apps/server/src/orchestration-v2/LiveStreamBudget.ts
+++ b/apps/server/src/orchestration-v2/LiveStreamBudget.ts
@@ -172,7 +172,6 @@ export const makeLiveStreamBudget = Effect.fn("makeLiveStreamBudget")(function*
}),
Effect.forkScoped,
);
- // @effect-diagnostics-next-line returnEffectInGen:off - Stream.fromPull needs the pull effect as its result.
return Effect.gen(function* () {
// RpcServer requests the next batch after ACK; dequeueing does not end delivery.
release(inFlight);
diff --git a/apps/server/src/orchestration-v2/ShellStream.ts b/apps/server/src/orchestration-v2/ShellStream.ts
index 99ac2b2d89d..c537465f9c2 100644
--- a/apps/server/src/orchestration-v2/ShellStream.ts
+++ b/apps/server/src/orchestration-v2/ShellStream.ts
@@ -384,7 +384,6 @@ export function composeShellStreamWithEnrichment<A, E, R, A2, E2, R2, A3, E3, R3
let previous: Deferred.Deferred<void> | undefined;
// Stream.merge pulls ahead after handing off each batch. Wait for the next
// downstream pull so shell delivery keeps that batch charged until its RPC ACK.
- // @effect-diagnostics-next-line returnEffectInGen:off - Stream.fromPull needs the pull effect as its result.
return Effect.gen(function* () {
if (previous) yield* Deferred.succeed(previous, undefined);
const next = yield* Queue.take(output);
diff --git a/apps/server/src/ws.ts b/apps/server/src/ws.ts
index 80752722471..e5696e6f5cd 100644
--- a/apps/server/src/ws.ts
+++ b/apps/server/src/ws.ts
@@ -3366,7 +3366,6 @@ export const layer = Layer.unwrap(
),
Effect.forkScoped,
);
- // @effect-diagnostics-next-line returnEffectInGen:off
return httpEffect;
}).pipe(
Effect.provide(
diff --git a/infra/relay/src/hooks/HookInboxObject.ts b/infra/relay/src/hooks/HookInboxObject.ts
index c83e74b36e9..110e119a01e 100644
--- a/infra/relay/src/hooks/HookInboxObject.ts
+++ b/infra/relay/src/hooks/HookInboxObject.ts
@@ -75,7 +75,6 @@ export const layer = HookInboxObject.make(
Effect.gen(function* () {
const state = yield* Cloudflare.DurableObjectState;
// Only the per-object inner Effect may access storage.
- // @effect-diagnostics-next-line returnEffectInGen:off
return Effect.gen(function* () {
const layerSql = SqliteClient.layer({ storage: state.raw.storage });
const inboxId = state.raw.id.name ?? state.raw.id.toString();
diff --git a/tsconfig.base.json b/tsconfig.base.json
index 8baa38bc3ba..47fd6ac6e80 100644
--- a/tsconfig.base.json
+++ b/tsconfig.base.json
@@ -42,6 +42,7 @@
"flatMapIgnoredParamToAndThen": "error",
"mapSomeToAsSome": "error",
"unnecessaryPipeChain": "error",
+ "returnEffectInGen": "off",
"effectFnOpportunity": "suggestion",
"anyUnknownInErrorContext": "error",
"unsafeEffectTypeAssertion": "error",