Describe the bug If you use useSession() in a client component and then attempt to npm run build, it appears to try and execute a rogue fetch() request and errors out, since it obviously can't ...
Solution
For those playing along at home - this is expected behaviour due to NextJS's page data collection stage and cannot be opted out, even if forcing the impacted routes to be dynamic, evaluation still takes place, but the output is ignored by the bundler.