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

Linter: detect unused dependencies #221

Closed
bajtos opened this issue Jan 27, 2025 · 3 comments · Fixed by CheckerNetwork/spark-evaluate#467
Closed

Linter: detect unused dependencies #221

bajtos opened this issue Jan 27, 2025 · 3 comments · Fixed by CheckerNetwork/spark-evaluate#467

Comments

@bajtos
Copy link
Member

bajtos commented Jan 27, 2025

We should have a linting step to report unused dependencies, so that we don't have to discuss this in pull requests.

See e.g. https://github.com/filecoin-station/deal-observer/pull/12/files#r1924916463 and CheckerNetwork/spark-deal-observer#12 (comment)

@bajtos
Copy link
Member Author

bajtos commented Jan 27, 2025

A tool we can use: https://www.npmjs.com/package/depcheck

@sumanjeet0012
Copy link

@bajtos I want to work on this issue. Can you specify exactly on which repository you want to implement this.

@bajtos
Copy link
Member Author

bajtos commented Feb 3, 2025

@bajtos I want to work on this issue. Can you specify exactly on which repository you want to implement this.

Awesome!

We will want to eventually implement this in all https://github.com/CheckerNetwork/ repositories that have a package.json file.

Let's start with https://github.com/CheckerNetwork/spark-evaluate/ so that we can align on the proposed solution (please wait for an approval from @juliangruber @pyropy @NikolasHaimerl @bajtos).

Some repositories like spark-api use npm workspaces, so there is more than one package.json file that we need to check for unused dependencies.

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 a pull request may close this issue.

2 participants