Skip to content

[AWS] Scan fails with "Error [TypeError]: AWS[serviceName] is not a constructor" #2176

@pasiorovuo

Description

@pasiorovuo

This seems to be a regression, earlier discussed in here: #2085.

The error is:

/var/scan/node_modules/aws-sdk/lib/request.js:31
            throw err;
            ^

Error [TypeError]: AWS[serviceName] is not a constructor
    at /var/scan/cloudsploit/collectors/aws/collector.js:139:119
    at /var/scan/node_modules/async/dist/async.js:3113:16
    at replenish (/var/scan/node_modules/async/dist/async.js:1014:17)
    at /var/scan/node_modules/async/dist/async.js:1019:9
    at Object.eachLimit$1 (/var/scan/node_modules/async/dist/async.js:3199:24)
    at /var/scan/cloudsploit/collectors/aws/collector.js:109:23
    at replenish (/var/scan/node_modules/async/dist/async.js:1014:17)
    at /var/scan/node_modules/async/dist/async.js:1019:9
    at Object.eachOfLimit (/var/scan/node_modules/async/dist/async.js:1044:24)
    at /var/scan/cloudsploit/collectors/aws/collector.js:88:19 {
  code: 'TypeError',
  time: 2025-12-01T12:28:30.339Z
}

It seems as if the changes related to CodeStar plugins made in https://github.com/aquasecurity/cloudsploit/pull/2130/commits were rolled back in 79b1f00#diff-003665623877ad886ae62d0768d144a09c5f4bcc54ca40cb3bd3c194f4337e51, and scans fail again.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions