You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@iggy.apache.org by "raushanprabhakar1 (via GitHub)" <gi...@apache.org> on 2026/05/14 12:06:44 UTC

[PR] harden uv resolution, add audit + Pyrefly in CI/pre-commit [iggy]

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

   ## Which issue does this PR close?
   
   Closes #3246
   
   ## Rationale
   
   Supply-chain incidents increasingly rely on very new PyPI uploads. Adding uv’s `exclude-newer` cooldown limits how fresh a release can be when resolving dependencies. We also run `uv audit` locally via pre-commit and add Pyrefly 1.x for type checking alongside mypy, with CI and hooks aligned.
   
   ## What changed?
   
   Dependency resolution for `foreign/python` now applies a **7-day** `exclude-newer`


-- 
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: commits-unsubscribe@iggy.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] feat(python): uv cooldown, CI uv audit, and Pyrefly for the SDK [iggy]

Posted by "hubcio (via GitHub)" <gi...@apache.org>.
hubcio commented on PR #3257:
URL: https://github.com/apache/iggy/pull/3257#issuecomment-4498924945

   closing due to inactivity; open new PR once all comments are addressed.


-- 
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: commits-unsubscribe@iggy.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] harden uv resolution, add audit + Pyrefly in CI/pre-commit [iggy]

Posted by "hubcio (via GitHub)" <gi...@apache.org>.
hubcio commented on PR #3257:
URL: https://github.com/apache/iggy/pull/3257#issuecomment-4451721023

   /author


-- 
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: commits-unsubscribe@iggy.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] feat(python): uv cooldown, CI uv audit, and Pyrefly for the SDK [iggy]

Posted by "hubcio (via GitHub)" <gi...@apache.org>.
hubcio closed pull request #3257: feat(python): uv cooldown, CI uv audit, and Pyrefly for the SDK
URL: https://github.com/apache/iggy/pull/3257


-- 
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: commits-unsubscribe@iggy.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] harden uv resolution, add audit + Pyrefly in CI/pre-commit [iggy]

Posted by "codecov[bot] (via GitHub)" <gi...@apache.org>.
codecov[bot] commented on PR #3257:
URL: https://github.com/apache/iggy/pull/3257#issuecomment-4450524121

   ## [Codecov](https://app.codecov.io/gh/apache/iggy/pull/3257?dropdown=coverage&src=pr&el=h1&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) Report
   :white_check_mark: All modified and coverable lines are covered by tests.
   :white_check_mark: Project coverage is 72.84%. Comparing base ([`a4b6a8d`](https://app.codecov.io/gh/apache/iggy/commit/a4b6a8db58a9e2c0054c3d88150d34035ab91fed?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)) to head ([`a9d6e0a`](https://app.codecov.io/gh/apache/iggy/commit/a9d6e0a44a16b19e19bb73bf2c016e9cd6cd9d85?dropdown=coverage&el=desc&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)).
   :warning: Report is 9 commits behind head on master.
   
   <details><summary>Additional details and impacted files</summary>
   
   
   
   ```diff
   @@             Coverage Diff              @@
   ##             master    #3257      +/-   ##
   ============================================
   - Coverage     73.82%   72.84%   -0.98%     
     Complexity      943      943              
   ============================================
     Files          1190     1127      -63     
     Lines        107833   103026    -4807     
     Branches      84851    84762      -89     
   ============================================
   - Hits          79606    75048    -4558     
   + Misses        25473    25221     -252     
   - Partials       2754     2757       +3     
   ```
   
   | [Components](https://app.codecov.io/gh/apache/iggy/pull/3257/components?src=pr&el=components&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | Coverage Δ | |
   |---|---|---|
   | [Rust Core](https://app.codecov.io/gh/apache/iggy/pull/3257/components?src=pr&el=component&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `74.87% <ø> (ø)` | |
   | [Java SDK](https://app.codecov.io/gh/apache/iggy/pull/3257/components?src=pr&el=component&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `60.14% <ø> (ø)` | |
   | [C# SDK](https://app.codecov.io/gh/apache/iggy/pull/3257/components?src=pr&el=component&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `69.43% <ø> (ø)` | |
   | [Python SDK](https://app.codecov.io/gh/apache/iggy/pull/3257/components?src=pr&el=component&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `81.43% <ø> (ø)` | |
   | [Node SDK](https://app.codecov.io/gh/apache/iggy/pull/3257/components?src=pr&el=component&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `87.48% <ø> (-4.06%)` | :arrow_down: |
   | [Go SDK](https://app.codecov.io/gh/apache/iggy/pull/3257/components?src=pr&el=component&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache) | `39.80% <ø> (ø)` | |
   [see 81 files with indirect coverage changes](https://app.codecov.io/gh/apache/iggy/pull/3257/indirect-changes?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=apache)
   </details>
   <details><summary> :rocket: New features to boost your workflow: </summary>
   
   - :snowflake: [Test Analytics](https://docs.codecov.com/docs/test-analytics): Detect flaky tests, report on failures, and find test suite problems.
   - :package: [JS Bundle Analysis](https://docs.codecov.com/docs/javascript-bundle-analysis): Save yourself from yourself by tracking and limiting bundle sizes in JS merges.
   </details>


-- 
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: commits-unsubscribe@iggy.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] harden uv resolution, add audit + Pyrefly in CI/pre-commit [iggy]

Posted by "hubcio (via GitHub)" <gi...@apache.org>.
hubcio commented on code in PR #3257:
URL: https://github.com/apache/iggy/pull/3257#discussion_r3241334451


##########
.pre-commit-config.yaml:
##########
@@ -87,6 +87,20 @@ repos:
         files: ^(foreign|bdd|examples)/python/(pyproject\.toml|uv\.lock)$
         pass_filenames: false
 
+      - id: uv-audit

Review Comment:
   `uv-audit` is added as a pre-commit hook only. iggy ci does not run pre-commit - `.github/workflows/_common.yml` mirrors every gating hook as an explicit job. without a matching job in `_common.yml`, `uv audit` never runs on prs. it only fires on a contributor machine that has pre-commit installed and touches a matching `pyproject.toml`/`uv.lock`. that's the opposite of the threat model in #3246 - a malicious or careless dependency bump arriving in a pr stays unguarded. if the audit is meant to gate prs, add it as a job in `_common.yml`.



##########
.github/actions/python-maturin/pre-merge/action.yml:
##########
@@ -83,6 +83,10 @@ runs:
         echo "Running mypy on SDK..."
         uv run mypy --explicit-package-bases "$DIR_SDK"
         echo "mypy version: $(uv run mypy --version)"
+
+        echo "Running pyrefly on SDK..."
+        uv run pyrefly check

Review Comment:
   pyrefly gets wired into ci here, but `uv audit` - the actual ask in #3246 - gets no ci entry anywhere. so the unrequested scope-creep check is enforced on prs while the security check it was paired with is not. either both belong in ci, or split this pr: the cooldown is what the issue asked for, pyrefly + audit tooling is separate scope and separate review.



##########
foreign/python/pyproject.toml:
##########
@@ -78,6 +78,10 @@ include = [
     ] },
 ]
 
+[tool.uv]
+exclude-newer = "7 days"
+exclude-newer-package = { urllib3 = false, pyrefly = false }

Review Comment:
   `exclude-newer-package = { urllib3 = false, pyrefly = false }` opts these two packages out of the 7-day cooldown. pyrefly has a reason - 1.0.0 was uploaded 2026-05-12, two days before this pr, so the cooldown would block the version being added. urllib3 has none - it isn't otherwise touched by this pr, and it's one of the highest-value supply-chain targets in the python ecosystem. exempting it from the freshness window, in a pr whose stated purpose is supply-chain hardening, defeats the protection for exactly the package an attacker would most want to push a fresh malicious release of. drop the urllib3 entry. same exemption is mirrored in `foreign/python/uv.lock` under `[options.exclude-newer-package]`.



-- 
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: commits-unsubscribe@iggy.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [PR] harden uv resolution, add audit + Pyrefly in CI/pre-commit [iggy]

Posted by "hubcio (via GitHub)" <gi...@apache.org>.
hubcio commented on PR #3257:
URL: https://github.com/apache/iggy/pull/3257#issuecomment-4450574721

   please fix PR title
   
   /author


-- 
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: commits-unsubscribe@iggy.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org