I would like to chime in on the memory error issue, as it is something I had to deal with in my apps. I was able to fix the issue myself by rewriting some code to use memory more efficiently, but it was a frustrating experience to troubleshoot. The only way to properly test whether the app will run into this issue, is to publish the app and run some tests on the published version of the app. As my app depends on a lot of different parameters including multiple uploadfields, you can imagine how cumbersome this debugging process is.
The suggested CLI-command to limit max-memory does not accurately reflect the published version.
A way to properly debug this issue before publishing would be incredibly helpful!