Skip to content

Conversation

@jscheffl
Copy link
Contributor

While implementing #57294 I realized that a couple of more ruff PLW rules might be interesting, this PR enables PLW1508 - and adds fixes as needed.

Alongside saw that the following needed no fixes and enabled them as well:

  • PLW0604: global at module level is redundant
  • PLW0642: Reassigned {} variable in {method_type} method
  • PLW0711: Exception to catch is the result of a binary and operation
  • PLW1501: {mode} is not a valid mode for open
  • PLW1507: Shallow copy of os.environ via copy.copy(os.environ)

See also https://docs.astral.sh/ruff/rules/#warning-plw

@boring-cyborg boring-cyborg bot added area:API Airflow's REST/HTTP API area:dev-tools area:docker-tests area:production-image Production image improvements and fixes area:providers backport-to-v3-1-test Mark PR with this label to backport to v3-1-test branch provider:amazon AWS/Amazon - related issues provider:databricks provider:edge Edge Executor / Worker (AIP-69) / edge3 provider:google Google (including GCP) related issues provider:microsoft-azure Azure-related issues labels Oct 31, 2025
Copy link
Member

@jason810496 jason810496 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice!

@jscheffl jscheffl merged commit c846f6f into apache:main Nov 1, 2025
405 of 407 checks passed
@github-actions
Copy link

github-actions bot commented Nov 1, 2025

Backport failed to create: v3-1-test. View the failure log Run details

Status Branch Result
v3-1-test Commit Link

You can attempt to backport this manually by running:

cherry_picker c846f6f v3-1-test

This should apply the commit to the v3-1-test branch and leave the commit in conflict state marking
the files that need manual conflict resolution.

After you have resolved the conflicts, you can continue the backport process by running:

cherry_picker --continue

jscheffl added a commit to jscheffl/airflow that referenced this pull request Nov 1, 2025
(cherry picked from commit c846f6f)

Co-authored-by: Jens Scheffler <95105677+jscheffl@users.noreply.github.com>
jscheffl added a commit that referenced this pull request Nov 1, 2025
ephraimbuddy pushed a commit that referenced this pull request Nov 3, 2025
ephraimbuddy pushed a commit that referenced this pull request Nov 4, 2025
Copilot AI pushed a commit to jason810496/airflow that referenced this pull request Dec 5, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:API Airflow's REST/HTTP API area:dev-tools area:docker-tests area:production-image Production image improvements and fixes area:providers backport-to-v3-1-test Mark PR with this label to backport to v3-1-test branch provider:amazon AWS/Amazon - related issues provider:databricks provider:edge Edge Executor / Worker (AIP-69) / edge3 provider:google Google (including GCP) related issues provider:microsoft-azure Azure-related issues

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants