Skip to content

Use node js git security advisories instead of using npm registry - #228

Merged
pombredanne merged 3 commits into
aboutcode-org:developfrom
sbs2001:use_nodejs_git_repo_for_npm_importer
Jul 23, 2020
Merged

Use node js git security advisories instead of using npm registry#228
pombredanne merged 3 commits into
aboutcode-org:developfrom
sbs2001:use_nodejs_git_repo_for_npm_importer

Conversation

@sbs2001

@sbs2001 sbs2001 commented Jul 17, 2020

Copy link
Copy Markdown
Collaborator

This PR switches the NPM importer to use https://github.com/nodejs/security-wg instead of https://registry.npmjs.org/-/npm/v1/security/advisories

Reasons :
https://registry.npmjs.org/-/npm/v1/security/advisories has given trouble to us in past, recently it was down for some time. The git data source is way more robust.

We also get to use GitDataSource which has alot of goodies.

https://github.com/nodejs/security-wg is the upstream

Signed-off-by: Shivam Sandbhor shivam.sandbhor@gmail.com

@sbs2001
sbs2001 requested a review from haikoschol July 17, 2020 09:16

@pombredanne pombredanne left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! ... I may wonder if using a direct download instead of a git checkout may have been simpler... but that's a small thing

@pombredanne

Copy link
Copy Markdown
Member

Please rebase and I will mereg

@sbs2001

sbs2001 commented Jul 23, 2020

Copy link
Copy Markdown
Collaborator Author

I may wonder if using a direct download instead of a git checkout may have been simpler... but that's a small thing

Good question. Thing is GitDataSource uses checkout to detect changes inside a git repository. So if you run an Importer again after some duration it will only fetch the data which is new/changed.

sbs2001 added 3 commits July 23, 2020 17:34
Signed-off-by: Shivam Sandbhor <shivam.sandbhor@gmail.com>
Signed-off-by: Shivam Sandbhor <shivam.sandbhor@gmail.com>
Signed-off-by: Shivam Sandbhor <shivam.sandbhor@gmail.com>
@sbs2001
sbs2001 force-pushed the use_nodejs_git_repo_for_npm_importer branch from 827f52e to 66f55f8 Compare July 23, 2020 12:18

@pombredanne pombredanne left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All good!
Merging

@pombredanne
pombredanne merged commit a15c726 into aboutcode-org:develop Jul 23, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants