await connection() expected when using OpenTelemetry instrumentation
Unanswered
Rampur Greyhound posted this in #help-forum
Rampur GreyhoundOP
How can I fix this error? As soon as I register my OpenTelemetry instrumentation hook, I keep getting this error on every page.
[ Server ] Error: Route "/test" used
[ Server ] Error: Route "/test" used
Math.random()
outside of "use cache"
and without explicitly calling await connection()
beforehand. See more info here: https://nextjs.org/docs/messages/next-prerender-random3 Replies
Rampur GreyhoundOP
Rampur GreyhoundOP
Anyone who could help?
@Rampur Greyhound How can I fix this error? As soon as I register my OpenTelemetry instrumentation hook, I keep getting this error on every page.
[ Server ] Error: Route "/test" used `Math.random()` outside of `"use cache"` and without explicitly calling `await connection()` beforehand. See more info here: https://nextjs.org/docs/messages/next-prerender-random
doesnt look like opentelemetry and dynamicIO are compatible yet. disable dynamicIO