-
-
Notifications
You must be signed in to change notification settings - Fork 2
build(pip): add dependency on java-api #291
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
Conversation
igniton-api 8.3.1.post2 now depends on java-api
Reviewer's guide (collapsed on small PRs)Reviewer's GuideUpdates stubs and tooling to align with ignition-api-stubs 8.3.1.post2’s new dependency on java-api and adjusts type hints and tox configs accordingly. Class diagram for updated TransactionManager type hintsclassDiagram
class TransactionManager {
+str transaction_id
+__init__(database: Union[str, unicode], isolation_level: Optional[int], timeout: Optional[int]) None
}
Flow diagram for updated tox typecheck and stubgen environmentsflowchart LR
dev["Developer runs tox"] --> tox["tox"]
tox --> typecheck_env["testenv:typecheck (python3.12)"]
tox --> stubgen_env["testenv:stubgen (python3.12)"]
tox --> stubs_typecheck_env["incendium-stubs testenv:typecheck"]
typecheck_env --> deps_typecheck["deps: ignition-api-stubs>=8.3, mypy[python2]==0.971"]
deps_typecheck --> mypy_src["mypy src"]
stubgen_env --> deps_stubgen["deps: mypy[python2]==0.971"]
deps_stubgen --> stubgen_cmd["stubgen src -> incendium-stubs/stubs"]
stubs_typecheck_env --> deps_stubs_typecheck["deps: requirements.txt, mypy[python2]==0.971"]
deps_stubs_typecheck --> mypy_stubs["mypy stubs"]
File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hey there - I've reviewed your changes - here's some feedback:
- Dropping
generate-hashesand all the--hashpins fromincendium-stubs/requirements.txtweakens reproducibility/supply-chain guarantees; if this isn’t intentional, consider keeping hashes or explaining why they’re no longer needed. - The
mypy[python2]==0.971andbase_python = python3.12settings are now duplicated across multiple tox envs; consider reintroducing a shared section or factor to avoid drift if these need to change later.
Prompt for AI Agents
Please address the comments from this code review:
## Overall Comments
- Dropping `generate-hashes` and all the `--hash` pins from `incendium-stubs/requirements.txt` weakens reproducibility/supply-chain guarantees; if this isn’t intentional, consider keeping hashes or explaining why they’re no longer needed.
- The `mypy[python2]==0.971` and `base_python = python3.12` settings are now duplicated across multiple tox envs; consider reintroducing a shared section or factor to avoid drift if these need to change later.
## Individual Comments
### Comment 1
<location> `incendium/tox.ini:48` </location>
<code_context>
black
docformatter
- flake8==5.0.4
+ flake8@ git+https://github.com/coatl-dev/flake8.git@5.0.4
isort
pydoclint
</code_context>
<issue_to_address>
**suggestion:** Pinning flake8 to a commit hash instead of a tag would improve reproducibility.
Tags like `@5.0.4` can be retagged, which may change the resolved code over time. For fully reproducible linting, prefer pinning to a specific commit SHA (e.g. `@<commit-hash>`) and, if helpful, noting which release that SHA corresponds to.
Suggested implementation:
```
flake8@ git+https://github.com/coatl-dev/flake8.git@<flake8-5.0.4-commit-sha> # flake8 5.0.4
```
You’ll need to:
1. Look up the exact commit SHA that corresponds to the `5.0.4` tag in `https://github.com/coatl-dev/flake8.git`.
2. Replace `<flake8-5.0.4-commit-sha>` with that full SHA (e.g. `a1b2c3d4e5f6...`).
</issue_to_address>Help me be more useful! Please click 👍 or 👎 on each comment and I'll use the feedback to improve your reviews.
| black | ||
| docformatter | ||
| flake8==5.0.4 | ||
| flake8@ git+https://github.com/coatl-dev/flake8.git@5.0.4 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
suggestion: Pinning flake8 to a commit hash instead of a tag would improve reproducibility.
Tags like @5.0.4 can be retagged, which may change the resolved code over time. For fully reproducible linting, prefer pinning to a specific commit SHA (e.g. @<commit-hash>) and, if helpful, noting which release that SHA corresponds to.
Suggested implementation:
flake8@ git+https://github.com/coatl-dev/flake8.git@<flake8-5.0.4-commit-sha> # flake8 5.0.4
You’ll need to:
- Look up the exact commit SHA that corresponds to the
5.0.4tag inhttps://github.com/coatl-dev/flake8.git. - Replace
<flake8-5.0.4-commit-sha>with that full SHA (e.g.a1b2c3d4e5f6...).
igniton-api 8.3.1.post2 now depends on java-api
Summary by Sourcery
Update ignition-related stubs and tooling to support the new java-api dependency and adjust type-checking configuration for Python 3.12 while preserving Python 2 type checking where needed.
Bug Fixes:
Enhancements:
Build:
Tests: