Skip to content

Error running the Rust example: credentials not found? #299

Description

@orende

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for issue followers and do not help prioritize the request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment

What did you do?

I checked out the https://github.com/scaleway/serverless-scaleway-functions repo, compiled the rust example, set up a namespace and function in the web UI, setup credentials for the scw cli tool in ~/.config/ and verified that scw could run commands by running scw function function list which listed my function. Then I tried to upload the code for it by running serverless deploy from REPO_ROOT_DIR/examples/rust.

What did you expect to see?

I expected the function code to be successfully uploaded and deployed.

What did you see instead?

The following error message:

sls deploy
Using credentials from /home/orende/.config/scw/config.yaml
Using credentials from /home/orende/.config/scw/config.yaml
Using credentials from /home/orende/.config/scw/config.yaml
Using credentials from /home/orende/.config/scw/config.yaml
Using credentials from /home/orende/.config/scw/config.yaml
Using credentials from /home/orende/.config/scw/config.yaml
Environment: linux, node 18.20.8, framework 3.39.0, plugin 7.2.3, SDK 4.5.1
Docs: docs.serverless.com
Support: forum.serverless.com
Bugs: github.com/serverless/serverless/issues

Error:
TypeError: Cannot read properties of undefined (reading 'length')
at ScalewayDeploy.validateCredentials (/home/orende/workspace/rust/serverless-scaleway-functions/examples/rust/node_modules/serverless-scaleway-functions/shared/validate.js:163:30)
at ScalewayDeploy.tryCatcher (/home/orende/workspace/rust/serverless-scaleway-functions/examples/rust/node_modules/bluebird/js/release/util.js:16:23)
at Promise._settlePromiseFromHandler (/home/orende/workspace/rust/serverless-scaleway-functions/examples/rust/node_modules/bluebird/js/release/promise.js:547:31)
at Promise._settlePromise (/home/orende/workspace/rust/serverless-scaleway-functions/examples/rust/node_modules/bluebird/js/release/promise.js:604:18)
at Promise._settlePromise0 (/home/orende/workspace/rust/serverless-scaleway-functions/examples/rust/node_modules/bluebird/js/release/promise.js:649:10)
at Promise._settlePromises (/home/orende/workspace/rust/serverless-scaleway-functions/examples/rust/node_modules/bluebird/js/release/promise.js:729:18)
at _drainQueueStep (/home/orende/workspace/rust/serverless-scaleway-functions/examples/rust/node_modules/bluebird/js/release/async.js:93:12)
at _drainQueue (/home/orende/workspace/rust/serverless-scaleway-functions/examples/rust/node_modules/bluebird/js/release/async.js:86:9)
at Async._drainQueues (/home/orende/workspace/rust/serverless-scaleway-functions/examples/rust/node_modules/bluebird/js/release/async.js:102:5)
at Async.drainQueues [as _onImmediate] (/home/orende/workspace/rust/serverless-scaleway-functions/examples/rust/node_modules/bluebird/js/release/async.js:15:14)
at process.processImmediate (node:internal/timers:476:21)

What version of Node are you using (node --version)?

v18.20.8

Does this issue reproduce with the latest release?

Don't know, I don't how to find out which release I'm using.

Other info

I run Ubuntu Linux on arm64, if that's relevant.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions