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

npm: add check-dependency-version-consistency #8135

Merged
merged 2 commits into from
Jan 20, 2025

Conversation

haraldschilly
Copy link
Contributor

@haraldschilly haraldschilly commented Jan 20, 2025

I saw this react inconsistency and looked around if there is something that checks for consistencies. We have that npm version check script, but that's only for the package.json files. As far as I understand, this also checks dependencies. We're whitelisting two packages, which are added to the command as well. 3 inconsistencies pop up:

~/p/cocalc/src/packages$ pnpm check-deps 

> @ check-deps /home/hsy/p/cocalc/src/packages
> check-dependency-version-consistency --ignore-dep async --ignore-dep entities .

Found 3 dependencies with mismatching versions across the workspace. Fix with `--fix`.
╔════════════╤════════╤══════════════════╗
║ codemirror │ Usages │ Packages         ║
╟────────────┼────────┼──────────────────╢
║ ^5.65.16   │ 1      │ @cocalc/frontend ║
╟────────────┼────────┼──────────────────╢
║ ^5.65.3    │ 1      │ @cocalc/cdn      ║
╚════════════╧════════╧══════════════════╝
╔════════╤════════╤══════════════════════════════════════════════════════════════════╗
║ debug  │ Usages │ Packages                                                         ║
╟────────┼────────┼──────────────────────────────────────────────────────────────────╢
║ ^4.3.4 │ 2      │ @cocalc/frontend, @cocalc/sync                                   ║
╟────────┼────────┼──────────────────────────────────────────────────────────────────╢
║ ^4.3.2 │ 9      │ @cocalc/backend, @cocalc/backend, @cocalc/database, and 6 others ║
╚════════╧════════╧══════════════════════════════════════════════════════════════════╝
╔══════════╤════════╤══════════════════╗
║ katex    │ Usages │ Packages         ║
╟──────────┼────────┼──────────────────╢
║ ^0.16.11 │ 1      │ @cocalc/frontend ║
╟──────────┼────────┼──────────────────╢
║ ^0.16.10 │ 1      │ @cocalc/cdn      ║
╚══════════╧════════╧══════════════════╝

based on that, this PR updates those packages and makes them consistent. I checked release notes a bit, everything looks harmless. After that fix, it is ok to call it from the workspaces version check.


bonus: this also takes care of #8129

@haraldschilly haraldschilly marked this pull request as ready for review January 20, 2025 10:11
@williamstein williamstein merged commit d397d47 into master Jan 20, 2025
3 checks passed
@williamstein
Copy link
Contributor

Thanks!!

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.

2 participants