-
Notifications
You must be signed in to change notification settings - Fork 83
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
Use ruff for linting #771
base: main
Are you sure you want to change the base?
Use ruff for linting #771
Conversation
import tests.worker.workflow_sandbox.testmodules.invalid_module | ||
pass |
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.
Was this meant to be removed?
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.
Good catch, no this was overzealous ruff check --fix
autofixing.
@@ -194,9 +194,9 @@ | |||
|
|||
# gRPC is optional | |||
try: | |||
import grpc | |||
import grpc # noqa # type: ignore |
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.
Just for my own curiosity, what was failing here that is requiring these two comments?
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.
temporalio/api/cloud/cloudservice/v1/__init__.py:197:12: F401 `grpc` imported but unused; consider using `importlib.util.find_spec` to test for availability
I've added the error code.
The type: ignore
was to silence Pylance in VSCode. However, our pyright lint passes, so I've removed the type: ignore
-- I'll add it back in if and when our lint requires it (and perhaps get my IDE type-checking in sync with our CI type-checking)
# TODO: wat | ||
f(self, other) # type: ignore # noqa: F821 |
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 do not know what I was thinking here, but it's likely a bug. Would definitely welcome a test that covers this and fixes it to do what it is supposed to.
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.
👍 #772
e89f5b2
to
bc54894
Compare
@@ -36,7 +36,6 @@ | |||
import temporalio.api.common.v1 | |||
import temporalio.common | |||
from temporalio.api.common.v1 import Payload, Payloads | |||
from temporalio.api.common.v1 import Payload as AnotherNameForPayload |
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.
This looks like it was deliberate but also appears to have no purpose today.
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.
Agreed.
Addressed comment and done another pass over the diff; this should be ready to merge. |
87eb719
to
3f1a956
Compare
@@ -222,7 +220,7 @@ async def test_workflow_info(client: Client, env: WorkflowEnvironment): | |||
assert info["retry_policy"] == json.loads( | |||
json.dumps(dataclasses.asdict(retry_policy), default=str) | |||
) | |||
assert uuid.UUID(info["run_id"]).version == 4 | |||
assert uuid.UUID(info["run_id"]).version == 7 |
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 server switched to v7 UUIDs for runID at temporalio/temporal#6933
WISOTT
PR targets
maturin
branch #768