Using sentry causes api routes to return an empty response
When using Sentry with Nextjs under SST, when instrumentation is enabled on API routes, be it through the autoInstrumentServerFunctions or by wrapping the api handler, the response is empty. I'm not sure if this is directly related to opennextjs or if this is an issue with sst itself but in https://github.com/opennextjs/opennextjs-aws/issues/350 it looks like opennext was causing it previously. I've created a repo to reproduce the problem https://github.com/digitaltoad/sst-opennext-sentry-issue.
@digitaltoad Could you try enabling streaming ? Just create an open-next.config.ts file at the same place as your next config https://opennext.js.org/aws/config/simple_example#streaming-with-lambda
If this doesn't help, i'll try to take a look at it later this week
@conico974 that seemed to fix the issue.
Ok i'll have to take another look at this, my first guess is that sentry is probably doing something wrong here, i'll have to see if we can do something about it or not.