ethanlin01x opened a new pull request, #3980:
URL: https://github.com/apache/iggy/pull/3980

   ## Which issue does this PR address?
   
   Closes #3977
   
   ## Rationale
   
   Each task in `components.yml` becomes its own job, so `sdk-python` compiled 
the same crate twice per push. Folding `build` into `test` also gives 
`apache_iggy.pyi` somewhere cheap to be checked, which it has never had.
   
   ## What changed?
   
   `sdk-python` ran `lint`, `test` and `build` as three jobs, and `build` 
compiled the wheel only to throw it away: `dist/` never reached `Upload test 
artifacts`, which only runs under `test`.
   
   `build` is now folded into `test`. `maturin build -o dist` runs there, ahead 
of the coverage build so the venv still ends up with the instrumented module 
before pytest. `lint` stays its own job, so the checks list still shows which 
stage failed.
   
   `test` then regenerates the stub and diffs it. The ruff steps in that check 
are not cosmetic: the tracked `.pyi` is stub_gen output *after* ruff, since 
`.pre-commit-config.yaml` runs `ruff-check --fix` and `ruff-format` over 
`foreign/python/**/*.pyi`. Format has to run before check, because the raw 
output leaves whitespace on blank lines, which `check` reports but only 
`format` fixes.
   
   The stub had already drifted: `describe_options` sat in a different position 
with its return type written as `builtins.list[OptionSpec]`, and two docstrings 
had been hand-edited to strip a rustdoc intra-doc link. That link only renders 
as noise in Python, so `topic.rs` now uses plain backticks and the generated 
output reads the same, removing the reason to edit the stub by hand.
   
   
   ## AI Usage
   
   If AI tools were used, please answer:
   1. Which tools? Claude
   2. Scope of usage? help implement and review this PR
   3. How did you verify the generated code works correctly? Unit tests pin 
each rejected value and each still-legal zero
   4. Can you explain every line of the code if asked? Yes, all the changes are 
checked by the human.
   
   
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to