Fix lint errors and add PR check workflow for validation - #15
Merged
Conversation
🤖 Generated with Codebuff Co-Authored-By: Codebuff <noreply@codebuff.com>
Runs on every pull request to catch issues before merge: - Ruff lint + format check - Pytest (build + test) - Pyright + mypy type stub validation - Zensical docs build validation 🤖 Generated with Codebuff Co-Authored-By: Codebuff <noreply@codebuff.com>
Pre-commit only checks staged files, CI checks all files. Format the entire project to prevent CI failures on PRs. 🤖 Generated with Codebuff Co-Authored-By: Codebuff <noreply@codebuff.com>
Swatinem/rust-cache caches Cargo build artifacts between runs. First build still ~10min, subsequent builds ~2-3min. 🤖 Generated with Codebuff Co-Authored-By: Codebuff <noreply@codebuff.com>
🤖 Generated with Codebuff Co-Authored-By: Codebuff <noreply@codebuff.com>
🤖 Generated with Codebuff Co-Authored-By: Codebuff <noreply@codebuff.com>
…extension is built The Rust native AudioPlayer has a different API (buffer_frames, file paths) than the Python prototype (queue_size, async iterators), causing test_audio_player_emits_frames_and_finishes_once to fail when the native extension is loaded. 🤖 Generated with Codebuff Co-Authored-By: Codebuff <noreply@codebuff.com>
The previous rust-cache only cached libs/whatsapp-rust/target, leaving the root ./target (where maturin builds the PyO3 extension) uncached. This caused full recompilation of the tryx crate on every CI run. 🤖 Generated with Codebuff Co-Authored-By: Codebuff <noreply@codebuff.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.
This pull request introduces a new GitHub Actions workflow for automated quality checks, testing, type stub validation, and documentation builds, ensuring improved CI coverage. It also refactors the example bot scripts for better readability and maintainability by simplifying variable assignments and message formatting.
Continuous Integration and Quality Checks:
.github/workflows/pr-check.ymlto run linting (Ruff), formatting, Python tests, type stub validation (Pyright, Mypy), and documentation builds on pull requests targeting key branches.Code Readability and Consistency Improvements in Example Bots:
sender,chat) inexamples/basic_bot.py,examples/group_bot.py, andexamples/media_bot.pyfor clearer debug output and improved readability. [1] [2] [3]examples/group_bot.py, assigned user-facing messages to variables before sending, enhancing clarity and consistency.examples/media_bot.py, assigned error messages to variables before sending and improved formatting for document sending, increasing maintainability. [1] [2] [3]## SummaryType of Change
Checklist
type(scope): summary)ruff, formatting, stub parity)Linked Issues
Notes for Reviewer