Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Lambda: The "path" argument must be of type string. Received undefined #1739

Open
adamfisher opened this issue Dec 15, 2022 · 3 comments
Open

Comments

@adamfisher
Copy link

This is a slight continuation of #1649 where I specified this command:

artillery run --platform aws:lambda --platform-opt memory-size=2048 --platform-opt "region=us-east-1" --platform-opt "memory-size=128" --environment env1 artillery-test.yml

But I now get this error trying to run lambda as shown below. What is the path referring to in this output? Nothing in the output of artillery run --help mentioned anything about a path.

λ Creating AWS Lambda function...
- Bundling test data
C:\Users\17077\AppData\Roaming\npm\node_modules\artillery\node_modules\async\dist\async.js:222
    throw error;
    ^

TypeError [ERR_INVALID_ARG_TYPE]: The "path" argument must be of type string. Received undefined
    at new NodeError (node:internal/errors:393:5)
    at validateString (node:internal/validators:163:11)
    at Object.resolve (node:path:171:9)
    at C:\Users\17077\AppData\Roaming\npm\node_modules\artillery\lib\create-bom\create-bom.js:196:18
    at Array.forEach (<anonymous>)
    at resolvePayloadPaths (C:\Users\17077\AppData\Roaming\npm\node_modules\artillery\lib\create-bom\create-bom.js:194:21)
    at getVariableDataFiles (C:\Users\17077\AppData\Roaming\npm\node_modules\artillery\lib\create-bom\create-bom.js:217:5)
    at nextTask (C:\Users\17077\AppData\Roaming\npm\node_modules\artillery\node_modules\async\dist\async.js:5327:14)
    at next (C:\Users\17077\AppData\Roaming\npm\node_modules\artillery\node_modules\async\dist\async.js:5334:9)
    at C:\Users\17077\AppData\Roaming\npm\node_modules\artillery\node_modules\async\dist\async.js:972:16 {
  code: 'ERR_INVALID_ARG_TYPE'
}

Node.js v19.0.0
@adamfisher
Copy link
Author

I saw a similar issue #733 but I verified the artillery-test.yml file is in the same directory as where I am running the command from.

@juanig1
Copy link
Contributor

juanig1 commented Dec 26, 2022

Hey, happy holidays!
Sorry I missed this issue.

Can't replicate this now but seems the error comes from artillery failling to get the correct path to the test files.

Will try tomorrow with my windows setup and let you know how it goes.
Edit: wont't be home until around Jan 15 to try this

@isaacamehgreg
Copy link

any solution to this issue

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants