Skip to content

[9/N] Apply ruff UP035 rule#165515

Closed
cyyever wants to merge 1 commit intopytorch:mainfrom
cyyever:up035_2025_10_15
Closed

[9/N] Apply ruff UP035 rule#165515
cyyever wants to merge 1 commit intopytorch:mainfrom
cyyever:up035_2025_10_15

Conversation

@pytorch-bot
Copy link

pytorch-bot bot commented Oct 15, 2025

🔗 Helpful Links

🧪 See artifacts and rendered test results at hud.pytorch.org/pr/165515

Note: Links to docs will display an error until the docs builds have been completed.

✅ You can merge normally! (3 Unrelated Failures)

As of commit 242f86d with merge base b11593c (image):

FLAKY - The following jobs failed but were likely due to flakiness present on trunk:

This comment was automatically generated by Dr. CI and updates every 15 minutes.

@cyyever cyyever marked this pull request as draft October 15, 2025 04:10
@facebook-github-bot facebook-github-bot added the module: rocm AMD GPU support for Pytorch label Oct 15, 2025
Signed-off-by: Yuanyuan Chen <cyyever@outlook.com>
@cyyever cyyever changed the title Apply ruff UP035 rule [9/N] Apply ruff UP035 rule Oct 15, 2025
@cyyever cyyever requested a review from ezyang October 15, 2025 06:44
@cyyever cyyever marked this pull request as ready for review October 15, 2025 06:44
@cyyever cyyever added the ciflow/trunk Trigger trunk jobs on your pull request label Oct 15, 2025
Copy link
Contributor

@Lucaskabela Lucaskabela left a comment

Choose a reason for hiding this comment

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

Trying to get to the source of this CI failure that I personally have never seen before - let's add a snippet of running the mentioned file to check/derisk

import requests


if TYPE_CHECKING:
Copy link
Contributor

Choose a reason for hiding this comment

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

I am a tad concerned the red CI signal related to nightly means there is some function in here that we have broken - do we have a unit test or can you include an example of running a function from this file using the Callable annotation to derisk? Thanks!

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Callable is used for static type checking in upload_stats_lib.py because the change imports it under TYPE_CHECKING so it is not responsible for the red CI.
The red CI is likely a flaky test being triggered. Let's wait for some time for verification.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

The CI failures are now marked as flaky.

@cyyever
Copy link
Collaborator Author

cyyever commented Oct 17, 2025

@pytorchbot merge -i

@pytorchmergebot
Copy link
Collaborator

Merge started

Your change will be merged while ignoring the following 3 checks: Nightly Upload to s3 / upload-stats-to-s3, inductor / inductor-test / test (inductor_torchbench, 2, 2, linux.g5.4xlarge.nvidia.gpu), trunk / macos-py3-arm64 / test (default, 1, 3, macos-m1-stable)

Learn more about merging in the wiki.

Questions? Feedback? Please reach out to the PyTorch DevX Team

Advanced Debugging
Check the merge workflow status
here

@cyyever cyyever deleted the up035_2025_10_15 branch October 17, 2025 00:10
meta-codesync bot pushed a commit to pytorch/benchmark that referenced this pull request Oct 17, 2025
Summary:
This is follow-up of #165214 to continue applying ruff UP035 rule to the code base.

X-link: pytorch/pytorch#165515
Approved by: https://github.com/Lucaskabela

Reviewed By: seemethere

Differential Revision: D84890963

fbshipit-source-id: 49b04017014b510b9903e79d5d98af0da8d74b32
Chao1Han pushed a commit to Chao1Han/pytorch that referenced this pull request Oct 21, 2025
This is follow-up of pytorch#165214 to continue applying ruff UP035 rule to the code base.

Pull Request resolved: pytorch#165515
Approved by: https://github.com/Lucaskabela
zhudada0120 pushed a commit to zhudada0120/pytorch that referenced this pull request Oct 22, 2025
This is follow-up of pytorch#165214 to continue applying ruff UP035 rule to the code base.

Pull Request resolved: pytorch#165515
Approved by: https://github.com/Lucaskabela
pytorchmergebot pushed a commit that referenced this pull request Oct 25, 2025
This is a follow-up of #165515. ruff `UP035` rules are applied to  dynamo code to use Py 3.10+ typing.

Pull Request resolved: #165709
Approved by: https://github.com/ezyang
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ciflow/inductor ciflow/trunk Trigger trunk jobs on your pull request Merged module: compiled autograd compiled_autograd module: dynamo module: inductor module: rocm AMD GPU support for Pytorch oncall: distributed Add this issue/PR to distributed oncall triage queue open source release notes: inductor (aoti) release notes: releng release notes category

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants