-
Notifications
You must be signed in to change notification settings - Fork 81
CI: Run ruff via uv, dev-dependencies #928
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
Changes from all commits
773e444
953cb41
4ae9694
6f71f60
cc28361
dd522eb
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -11,7 +11,7 @@ license = { text = "MIT" } | |
| authors = [ | ||
| { name = "Andreas Kloeckner", email = "inform@tiker.net" }, | ||
| ] | ||
| requires-python = ">=3.8" | ||
| requires-python = ">=3.10" | ||
| classifiers = [ | ||
| "Development Status :: 4 - Beta", | ||
| "Intended Audience :: Developers", | ||
|
|
@@ -50,14 +50,14 @@ pyopencl = [ | |
| "pyopencl>=2022.3", | ||
| ] | ||
| fortran = [ | ||
| # Note that this is *not* regular 'f2py2e', this is | ||
| # the Fortran parser from the (unfinished) third-edition | ||
| # f2py, as linked below. This package is not on the package index, AFAIK. | ||
| # -AK, 2024-08-02 | ||
| "f2py @ git+https://github.com/pearu/f2py.git", | ||
| "fparser>=0.2.0", | ||
| "ply>=3.6", | ||
| ] | ||
|
|
||
| [dependency-groups] | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. What's the benefit for
Owner
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Defined in https://peps.python.org/pep-0735/. The PEP describes the design decisions. It seems that dependency groups are the "hot new" way to do dev dependencies. A markedly useful aspect here is that, unlike the usual "extras", they permit only the dev dependencies to be installed, without fully installing loopy.
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
I see why that's quite useful here, thanks :D |
||
| dev = [ | ||
| # https://github.com/astral-sh/ruff/issues/16943 | ||
| "ruff!=0.11.1,!=0.11.2", | ||
| "mypy", | ||
| "types-colorama", | ||
| "types-Pygments", | ||
|
|
@@ -116,6 +116,10 @@ extend-ignore = [ | |
| # FIXME | ||
| "UP031", # .format instead of %s | ||
| "UP032", # .format instead of %s | ||
| "B905", # zip without strict | ||
| "UP035", # typing.Tuple | ||
| "UP006", # typing.Tuple | ||
| "UP007", # Union -> X|Y | ||
| ] | ||
|
|
||
| [tool.ruff.lint.per-file-ignores] | ||
|
|
||
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.
Any reason not to use ruff-action? I don't recall why we went with installing it manually when we switched..
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.
The whole point of this PR is to encode ruff version ranges in
pyproject.toml. AFAICT,ruff-actionignores that?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.
I don't know if that was the case in the past, but their documentation says they do read
pyproject.tomlto get the version: https://github.com/astral-sh/ruff-action?tab=readme-ov-file#install-specific-versionsThere 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.
Eh, I find the version with
uveasier to reason about. In addition, the actions thing wouldn't work on Gitlab, so then that would just introduce inconsistency.