Skip to content

Commit

Permalink
fix(platform-node): change MAX_SAFE_INTEGER to a valid number (#1905)
Browse files Browse the repository at this point in the history
  • Loading branch information
datner authored Jan 11, 2024
1 parent 0c397e7 commit 71ed54c
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/nice-olives-travel.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@effect/platform-node": patch
---

change to an actually allowed number
2 changes: 1 addition & 1 deletion packages/platform-node/src/internal/runtime.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ export const runMain: RunMain = <E, A>(
effect: Effect.Effect<never, E, A>,
teardown = defaultTeardown
) => {
const keepAlive = setInterval(() => {}, Number.MAX_SAFE_INTEGER)
const keepAlive = setInterval(() => {}, 2 ** 31 - 1)

const fiber = Effect.runFork(
Effect.tapErrorCause(effect, (cause) => {
Expand Down

0 comments on commit 71ed54c

Please sign in to comment.