[
https://issues.apache.org/jira/browse/AVRO-4232?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18060251#comment-18060251
]
ASF subversion and git services commented on AVRO-4232:
-------------------------------------------------------
Commit 7ee89c2b7b2305a6b50fcf3cf1992d0d1a88e6c2 in avro's branch
refs/heads/main from Martin Grigorov
[ https://gitbox.apache.org/repos/asf?p=avro.git;h=7ee89c2b7b ]
AVRO-4232: [Python] Modernize the Python tooling (#3658)
* AVRO-4232: [Python] Modernize the Python tooling
Use `uv` for management and `ruff` for linting and formatting
* Ignore uv.lock for ASFv2 licence check
* Add librt as a dev dependency
* Drop librt as dev-dep. It fails at CI with another error
* Do not test Python 3.9 since it is not supported
Test 3.14 instead
* Try with mypy<1.19
https://github.com/python/mypy/issues/20454
* Use uv for the Java interop tests too
* Remove the flake8 settings. Now we use ruff
* Update uv.lock
* Set cwd to lang/py for `uv sync`. Do not use uv for C# scripts
* Update the usage. Wrap variables in quotes
* Move more entries from setup.cfg to pyproject.toml
* Remove typechecks dependency. It seems to be tox specific
* Do not shadow Python built-in `type`
* Use `--frozen` for `uv sync` in CI
* Update setup-uv Github action to v7
* Fix the package name for AvroException
* First declare the local variable and then assign it a value
* Use Python 3.10 for mypy
* Move "scripts" from setup.cfg to pyproject.toml
* Re-add the optional dependencies from setup.cfg to pyproject.toml
* Re-add the package-data from setup.cfg to pyproject.toml
* Use SHA for the external actions
Policy by Infra: https://infra.apache.org/github-actions-policy.html > External
actions
Last allowed version: 7.1.6
(https://github.com/apache/infrastructure-actions/blob/2943971f47fadefa6d86af85c2c24c2cee262ee1/actions.yml#L25-L26)
Co-authored-by: Ryan Skraba <[email protected]>
* No need to call `build.sh` thru `uv run`
---------
Co-authored-by: Ryan Skraba <[email protected]>
> [Python] Modernize the Python tooling
> -------------------------------------
>
> Key: AVRO-4232
> URL: https://issues.apache.org/jira/browse/AVRO-4232
> Project: Apache Avro
> Issue Type: Task
> Components: python
> Reporter: Martin Tzvetanov Grigorov
> Priority: Major
> Labels: pull-request-available
> Time Spent: 2h 40m
> Remaining Estimate: 0h
>
> The Python build often fails without any changes in avro/lang/py/ folder!
> If a new version of Python itself or some tool
> (linter/formatter/typechecker/...) is released then the Python build usually
> needs some work to pass again.
> It would be nice to use something more stable/modern to make the build stable
> and reliable. Maybe uv, ruff, ... ?! Anything that won't break unless we
> change something in our code.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)