Do Netlify (scheduled) Functions respect the package.json packageManager key?

Netlify site name: wheresbaldo-dev.netlify.app

Issue: I’m getting an “Uncaught Exception” error when my Netlify scheduled function runs, saying a package isn’t being found:

{“errorType”:“Error”,“errorMessage”:“Cannot find package ‘prettier’ imported from /var/task/netlify/functions/sitemap-rss-regen.mjs”

It appears to be getting deployed without issue, as it’s showing scheduled correctly.
I suspected this might be due to me using Yarn Berry (with no node_modules folder) and so I asked “Ask Netlify” if using Yarn Berry is supported, and it doesn’t seem like that’s the case. Quoting it’s reply:

If you’re using Yarn Berry (Yarn 2.0.0 or later) with Netlify, you must add nodeLinker: node-modules to a .yarnrc.yml file, which is generally stored in your repository root. This is because Netlify depends on the node_modules folder tree that’s generated with this setting. The Plug’n’Play feature of Yarn is not currently supported on Netlify.

Specifics about the package manager aren’t listed in any of the official docs that I could see, although perhaps I missed it.

So, I just want to confirm, are the functions being built/deployed using the package manager, or only Node.JS directly?

If the latter, are there any plans to change it to use the package manager for deployment?
And if not, it should be noted in the official docs that the node_modules folder must be present, and therefore Yarn Berry (or zero-installs) can’t be used.

Functions along with the required files from node_modules are bundled together in a zip and pushed to AWS Lambda. In that environment, there’s no npm or yarn. Just plain simple Node.js. If your code can run fine with Node.js without any interferece of Yarn, it should work there. If it specifically needs Yarn to work fine, it won’t work there.

Yeah, that’s what I was suspecting.

Hopefully that can be added to the official docs then, as functions can’t work for everyone since it depends on the setup. It would have saved me some time if it was noted in the docs, because I thought they would run like the rest of the code in my app.