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

Not skipping node_modules directory #3775

Open
aditya-2010 opened this issue May 12, 2024 · 0 comments
Open

Not skipping node_modules directory #3775

aditya-2010 opened this issue May 12, 2024 · 0 comments
Labels

Comments

@aditya-2010
Copy link

Description

While scanning my node.js codebase, I could see it scan the node_modules directory as well, which is not necessary and time consuming.

How To Reproduce

image

Snapshot 1: Codebase where node_modules was scanned

image

Snapshot 2: Codebase where npm install was not done (node_modules directory doesn't exist)

Thoughts

This seems to be not working:

for child in resource.children(codebase):
    if depth == 0 and child.name == 'node_modules':
        continue
    yield child

For bug reports, it really helps us to know:

  • What OS are you running on? (Windows/MacOS/Linux) - Windows 11
  • What version of scancode-toolkit was used to generate the scan file? - v32.1.0-7-g4f49985c26
  • What installation method was used to install/run scancode? (pip/source download/other) - source download
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