Repository navigation
Adopt Ruff, add Snyk scan and remove Codacy - #243
Merged
Merged
Conversation
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
✅ Snyk checks have passed. No issues have been found so far.
💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse. |
Formatting the legacy codebase should be done in a separate PR. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
jguz-pubnub
commented
Nov 18, 2026
| flake8 --exclude=scripts/,src/,.cache,.git,.idea,.tox,._trial_temp/,venv/ --ignore F811,E402 | ||
| - name: Install Ruff | ||
| run: pip3 install --user "ruff>=0.8" | ||
| - name: Ruff lint |
Contributor
Author
There was a problem hiding this comment.
Ruff replaces flake8 (and Codacy) for linting; the rules mirror the previous flake8 setup. Also, ruff format is intentionally not enforced because the legacy codebase is not ruff-formatted. The estimated scope is ~280 of ~360 files, ~17k changed lines. Therefore, formatting it here would bury functional changes and break git blame. This should be done in a separate, formatting-only PR.
…d Snyk scan Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Enable bugbear, Pylint, simplify and McCabe rule sets with a baseline ignore list for existing violations and noisy Pylint design metrics. Stop excluding tests to match the previous flake8 setup, limiting them to E, F and W, and remove a redundant urllib import. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
jguz-pubnub
commented
Nov 19, 2026
| ] | ||
|
|
||
| [lint.mccabe] | ||
| max-complexity = 25 |
Contributor
Author
There was a problem hiding this comment.
Currently, the highest value is 25. This should be lowered over time as an SDK is refactored or improved.
techwritermat
added a commit
that referenced
this pull request
Nov 24, 2026
Take master's Ruff setup (#243) for the validations workflow and the lint command, and restore the cross-workflow cancel step in the Tests workflow, so the only differences from master outside tests/live are the live tier's own files. The test command keeps --ignore=tests/live/ because the live tier needs keys and runs in its own workflow. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
ci: replaces flake8 and Codacy with Ruff, and adds a dependency vulnerability scan