Reputation: 21
I'm currently working on deploying a project using Serverless Stack (SST) and encountered an error during the build process. The error seems to be related to copying directories, and I'm not sure how to resolve it. Here's the error message I received:
Error: Invalid src or dest: cp returned EINVAL (cannot copy \?\C:\Users\nessm\OneDrive\Bureau\data_processing to a subdirectory of self \?\C:\Users\nessm\OneDrive\Bureau\data_processing.sst\artifacts\c8619373ee18901e2841669aa473ccf558a9204943) \?\C:\Users\nessm\OneDrive\Bureau\data_processing.sst\artifacts\c8619373ee18901e2841669aa473ccf558a9204943
Trace: SystemError: Invalid src or dest: cp returned EINVAL (cannot copy \?\C:\Users\nessm\OneDrive\Bureau\data_processing to a subdirectory of self \?\C:\Users\nessm\OneDrive\Bureau\data_processing.sst\artifacts\c8619373ee18901e2841669aa473ccf558a9204943) \?\C:\Users\nessm\OneDrive\Bureau\data_processing.sst\artifacts\c8619373ee18901e2841669aa473ccf558a9204943 at __node_internal_captureLargerStackTrace (node:internal/errors:497:5) at new SystemError (node:internal/errors:257:5) at new NodeError (node:internal/errors:368:7) at checkPaths (node:internal/fs/cp/cp:110:11) at async cpFn (node:internal/fs/cp/cp:65:17) at async Object.build (file:///C:/Users/nessm/OneDrive/Bureau/data_processing/node_modules/sst/runtime/handlers/python.js:102:13) at async task (file:///C:/Users/nessm/OneDrive/Bureau/data_processing/node_modules/sst/runtime/handlers.js:56:31) at async Object.build (file:///C:/Users/nessm/OneDrive/Bureau/data_processing/node_modules/sst/runtime/handlers.js:109:24) at async file:///C:/Users/nessm/OneDrive/Bureau/data_processing/node_modules/sst/constructs/Function.js:241:32 at process. (file:///C:/Users/nessm/OneDrive/Bureau/data_processing/node_modules/sst/cli/sst.js:58:21) at process.emit (node:events:526:35) at process.emit (node:domain:488:12) at process._fatalException (node:internal/process/execution:159:25) at processPromiseRejections (node:internal/process/promises:289:13) at process.processTicksAndRejections (node:internal/process/task_queues:96:32)
It seems like there's an issue with the cp
command trying to copy a directory into a subdirectory of itself, which is not allowed. I've checked the paths and they seem correct, but the error persists.
Has anyone encountered a similar issue while deploying an SST project or has any insights on how to fix this? Any help or suggestions would be greatly appreciated!
Upvotes: 0
Views: 150
Reputation: 21
Solved : for python projects , the requirments file should be in the functions/src
Upvotes: 0