sailfork / t3code-github / .repos/ effect/ migration/ annotations/ effect__Random.yaml

effect/Random#fixed:
  replacement: "Effect.provideService(Random.Random, customRandom)"
  note: "No exact built-in equivalent remains. For deterministic tests, provide a cycling service implementing nextIntUnsafe and nextDoubleUnsafe; map non-number sequences explicitly."
effect/Random#make:
  replacement: "Random.withSeed"
  note: "Replace service construction and withRandom with Random.withSeed(seed)(program). V4 accepts string or number, returns an Effect transformation, and uses a different PRNG, so sequences are not v3-compatible."
effect/Random#nextRange:
  replacement: "Random.nextBetween"
  note: "Direct rename; both produce a floating-point value in the half-open range [min, max)."
effect/Random#Random:
  replacement: "Random.Random"
  note: "The context key is now a Context.Reference whose low-level service only has nextIntUnsafe and nextDoubleUnsafe. Prefer module operations; custom providers implement those two primitives."
effect/Random#RandomTypeId:
  replacement: "none"
  note: "The service is structural and no longer carries a public RandomTypeId brand."
effect/Random#randomWith:
  replacement: "Random.Random.use"
  note: "Use Random.Random.use for raw service access. Prefer replacing callbacks that selected an old method with the corresponding module-level Random operation."