Skip to content

Commit cfb1bda

Browse files
Thomas Polasekfacebook-github-bot
authored andcommitted
Convert directory fbcode/kernel to use the Ruff Formatter
Summary: Converts the directory specified to use the Ruff formatter in pyfmt ruff_dog If this diff causes merge conflicts when rebasing, please run `hg status -n -0 --change . -I '**/*.{py,pyi}' | xargs -0 arc pyfmt` on your diff, and amend any changes before rebasing onto latest. That should help reduce or eliminate any merge conflicts. allow-large-files Reviewed By: amyreese Differential Revision: D66248116 fbshipit-source-id: 7c3d73bd42cd040f0d86db02901694b8707494fa
1 parent 675bf47 commit cfb1bda

File tree

3 files changed

+4
-14
lines changed

3 files changed

+4
-14
lines changed

kernel_patches_daemon/branch_worker.py

Lines changed: 4 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -87,9 +87,7 @@
8787
UPSTREAM_REMOTE_NAME = "upstream"
8888

8989

90-
EMAIL_TEMPLATE_BASE: Final[
91-
str
92-
] = """\
90+
EMAIL_TEMPLATE_BASE: Final[str] = """\
9391
Dear patch submitter,
9492
9593
CI has tested the following submission:
@@ -103,26 +101,20 @@
103101
104102
"""
105103

106-
EMAIL_TEMPLATE_MERGE_CONFLICT_BODY: Final[
107-
str
108-
] = """\
104+
EMAIL_TEMPLATE_MERGE_CONFLICT_BODY: Final[str] = """\
109105
PR: {github_pr_url}
110106
111107
Please rebase your submission onto the most recent upstream change and resubmit
112108
the patch to get it tested again.
113109
"""
114110

115-
EMAIL_TEMPLATE_SUCCESS_BODY: Final[
116-
str
117-
] = """\
111+
EMAIL_TEMPLATE_SUCCESS_BODY: Final[str] = """\
118112
Matrix: {github_actions_url}
119113
120114
No further action is necessary on your part.
121115
"""
122116

123-
EMAIL_TEMPLATE_FAILURE_BODY: Final[
124-
str
125-
] = """\
117+
EMAIL_TEMPLATE_FAILURE_BODY: Final[str] = """\
126118
Matrix: {github_actions_url}
127119
128120
{inline_logs}\

kernel_patches_daemon/github_connector.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,6 @@ def __init__(
6565
app_auth: Optional[Auth.AppInstallationAuth] = None,
6666
http_retries: Optional[int] = None,
6767
) -> None:
68-
6968
assert bool(github_oauth_token) ^ bool(
7069
app_auth
7170
), "Only one of github_oauth_token or app_auth can be set"

kernel_patches_daemon/patchwork.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -453,7 +453,6 @@ async def is_expired(self) -> bool:
453453

454454
@cached(cache=TTLCache(maxsize=1, ttl=120))
455455
async def get_patch_binary_content(self) -> bytes:
456-
457456
content = await self.pw_client.get_blob(self.mbox)
458457
logger.debug(
459458
f"Received patch mbox for series {self.id}, size: {len(content)} bytes"

0 commit comments

Comments
 (0)