Skip to content

Conversation

brichet
Copy link
Contributor

@brichet brichet commented May 9, 2025

Fixes #1966
Should fix https://github.com/jupyter/nbgrader/security/dependabot/60

This PR replaces the use of deprecated bower by NPM.
It also updates underscore dependency to >=1.13.1, which should fix a security error.

Copy link
Contributor

github-actions bot commented May 9, 2025

Binder 👈 Launch a Binder on branch brichet/nbgrader/remove_bower_dependency

@brichet brichet marked this pull request as ready for review May 9, 2025 12:22
Comment on lines +100 to +112
nbgrader/server_extensions/formgrader/static/node_modules/autosize/example
nbgrader/server_extensions/formgrader/static/node_modules/autosize/src
nbgrader/server_extensions/formgrader/static/node_modules/bootstrap/less
nbgrader/server_extensions/formgrader/static/node_modules/bootstrap/js
nbgrader/server_extensions/formgrader/static/node_modules/bootstrap/grunt
nbgrader/server_extensions/formgrader/static/node_modules/jquery/external
nbgrader/server_extensions/formgrader/static/node_modules/jquery/src
nbgrader/server_extensions/formgrader/static/node_modules/underscore/amd
nbgrader/server_extensions/formgrader/static/node_modules/underscore/cjs
nbgrader/server_extensions/formgrader/static/node_modules/underscore/modules
nbgrader/server_extensions/formgrader/static/node_modules/underscore/underscore-esm*
nbgrader/server_extensions/formgrader/static/node_modules/underscore/underscore-node*
nbgrader/server_extensions/formgrader/static/node_modules/underscore/underscore-umd*
Copy link
Contributor

@shreve shreve May 9, 2025

Choose a reason for hiding this comment

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

Because we're using the exceptions below, we can replace all of these specific rules with a more general one:

nbgrader/server_extensions/formgrader/static/node_modules/**/*

I think this would make maintenance a tiny bit easier moving forward.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I think it would be quite similar, we would have to specify which files we want to keep instead of specifying which files we want to remove.
We probably want to keep package.json files, readme and some other files to know the version fetched.

The exceptions below are to prevent the following to remove these directories:

dist/

Copy link
Contributor

Choose a reason for hiding this comment

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

Ah, I see what you mean. I think the change I want to see goes well beyond the scope of this PR. Thanks for clarifying.

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

Successfully merging this pull request may close these issues.

Do not depend on bower for frontend packages
2 participants