Init() has been called in install() already and should only be called ONCE per run, or else it just deletes all the previously copied files, like the package.json file, which lead me to believe there was an error with copying, but there is not.
The issue is due to these recurrent init() calls.
Solution: Remove this.init(); from line 87 in Dependencies.js
https://github.com/agutoli/serverless-layers/blob/842eb7ce374af7a400e6cec2176bcc6f1882919c/src/package/Dependencies.js#L87
Init() has been called in install() already and should only be called ONCE per run, or else it just deletes all the previously copied files, like the package.json file, which lead me to believe there was an error with copying, but there is not. The issue is due to these recurrent init() calls.
Solution: Remove
this.init();
from line 87 in Dependencies.js