Sorry to hear you encountered an obstacle. Could you share your site and function log where you found this so that I can loop in the appropriate team? Thanks.
Not sure when this was rolled about, but recently NextJs api endpoints started to be sharded into separate cloud functions for each endpoint. Previously they were all handled by one cloud function.
The code in the linked issue only fails when deployed via the sharded apis, but when it’s deployed as a bundled set of apis to __netlify-handler it works. Still unclear as to why some deploys use one method over the other (sharded vs bundled functions).