ci: add Makefile for dev setup with prek hooks#1417
Merged
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #1417 +/- ##
=======================================
Coverage 99.89% 99.89%
=======================================
Files 6 6
Lines 986 986
Branches 139 139
=======================================
Hits 985 985
Partials 1 1 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Contributor
There was a problem hiding this comment.
Pull request overview
This PR adds a developer Makefile, but it also changes the library’s heating-circuit support and parameter mappings (not reflected in the PR title/description).
Changes:
- Add a
Makefilewithsetup,lint,test, andcoveragetargets usinguv+prek. - Reduce supported heating circuits from 3 to 2 (remove HC3 sections/params and related tests).
- Update heating circuit 2 parameter IDs (and adjust fixtures/tests accordingly).
Reviewed changes
Copilot reviewed 9 out of 9 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| Makefile | Adds common dev commands (setup/lint/test/coverage). |
| src/bsblan/constants.py | Drops HC3 support; updates HC2 parameter IDs and related mappings. |
| src/bsblan/bsblan.py | Updates section typing and docs to align with 2-circuit support. |
| tests/test_circuit.py | Removes HC3 tests and updates invalid-circuit assertions. |
| tests/test_constants.py | Updates required API config sections to exclude HC3. |
| tests/test_initialization.py | Updates API section mocks to exclude HC3. |
| tests/test_api_validation.py | Updates API validation cache test data to exclude HC3. |
| tests/test_hotwater_state.py | Updates API v3 test structure to exclude HC3. |
| tests/fixtures/state_circuit2.json | Updates fixture parameter IDs for circuit 2. |
|
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.



Add a Makefile with common development commands:
make setup— Install dev dependencies and prek git hooksmake lint— Run all pre-commit hooks via prekmake test— Run testsmake coverage— Run tests with coverage reportThis ensures prek hooks are automatically installed when setting up the dev environment, preventing lint errors from being pushed without local checks.