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

[BUG] Cannot analyze package file with aws-amplify or aws-amplify-react #265

Open
danielahedges opened this issue Jan 4, 2023 · 0 comments
Labels

Comments

@danielahedges
Copy link

Bug Description

I have a JavaScript project that has packages aws-amplify and aws-amplify-react, and if either of these dependencies are in the package, auditjs fails with:

There was an error auditing with Sonatype OSS Index Error: There was an error making the request: Error: Internal Server Error
    at /Users/dhedges/src/ossi/node_modules/auditjs/bin/Services/OssIndexRequestService.js:71:19
    at processTicksAndRejections (node:internal/process/task_queues:96:5)
    at async Promise.all (index 5)

To Reproduce

Create the following package file in an empty directory:

{
  "name": "ossi",
  "version": "1.0.0",
  "description": "Empty project that runs auditjs.",
  "main": "index.js",
  "scripts": {
    "test": "echo \"Error: no test specified\" && exit 1"
  },
  "author": "me@example.com",
  "license": "UNLICENSED",
  "devDependencies": {
    "auditjs": "^4.0.39"
  },
  "dependencies": {
    "aws-amplify": "^5.0.8",
    "aws-amplify-react": "^5.1.43"
  }
}

Then:

npm install
npx auditjs ossi

I get the following results:

 ________   ___  ___   ________   ___   _________       ___   ________
|\   __  \ |\  \|\  \ |\   ___ \ |\  \ |\___   ___\    |\  \ |\   ____\
\ \  \|\  \\ \  \\\  \\ \  \_|\ \\ \  \\|___ \  \_|    \ \  \\ \  \___|_
 \ \   __  \\ \  \\\  \\ \  \ \\ \\ \  \    \ \  \   __ \ \  \\ \_____  \
  \ \  \ \  \\ \  \\\  \\ \  \_\\ \\ \  \    \ \  \ |\  \\_\  \\|____|\  \
   \ \__\ \__\\ \_______\\ \_______\\ \__\    \ \__\\ \________\ ____\_\  \
    \|__|\|__| \|_______| \|_______| \|__|     \|__| \|________||\_________\
                                                                \|_________|


  _      _                       _   _
 /_)    /_`_  _  _ _/_   _  _   (/  /_`_._  _   _/ _
/_)/_/ ._//_// //_|/ /_//_//_' (_X /  ///_'/ //_/_\
   _/                _//

  AuditJS version: 4.0.39

✔ Starting application
✔ Getting coordinates for Sonatype OSS Index
✔ Auditing your application with Sonatype OSS Index
[2023-01-04T13:53:19.777] [ERROR] auditjs - There was an error auditing with Sonatype OSS Index Error: There was an error making the request: Error: Internal Server Error
    at /Users/dhedges/src/ossi/node_modules/auditjs/bin/Services/OssIndexRequestService.js:71:19
    at processTicksAndRejections (node:internal/process/task_queues:96:5)
    at async Promise.all (index 5)

Expected Behavior

I should be able to see results, whether passing or failing. I should not see a server error.

Desktop

  • OS: Mac OS X
  • NodeJS Version: 16.16
  • Version: 4.0.39

cc @bhamail / @DarthHater / @allenhsieh / @Slim-Shary

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

No branches or pull requests

1 participant