Skip to content

Commit 3c8ee0a

Browse files
authored
Minor fixes (#268)
Fixes #254 Fixes #263
1 parent 832c375 commit 3c8ee0a

File tree

79 files changed

+1285
-1146
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

79 files changed

+1285
-1146
lines changed

README.md

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1230,7 +1230,12 @@ poe test
12301230

12311231
This runs against [Temporalite](https://github.com/temporalio/temporalite). To run against the time-skipping test
12321232
server, pass `--workflow-environment time-skipping`. To run against the `default` namespace of an already-running
1233-
server, pass the `host:port` to `--workflow-environment`.
1233+
server, pass the `host:port` to `--workflow-environment`. Can also use regular pytest arguments. For example, here's how
1234+
to run a single test with debug logs on the console:
1235+
1236+
```bash
1237+
poe test -s --log-cli-level=DEBUG -k test_sync_activity_thread_cancel_caught
1238+
```
12341239

12351240
#### Proto Generation and Testing
12361241

poetry.lock

Lines changed: 860 additions & 871 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

pyproject.toml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -35,11 +35,11 @@ types-protobuf = "~3.20"
3535
typing-extensions = "^4.2.0"
3636

3737
[tool.poetry.dev-dependencies]
38-
black = "^22.3.0"
38+
black = "^23.1.0"
3939
cibuildwheel = "^2.11.0"
4040
grpcio-tools = "^1.48.0"
41-
isort = "^5.11.3"
42-
mypy = "^0.971"
41+
isort = "^5.11.5"
42+
mypy = "^1.0.0"
4343
mypy-protobuf = "^3.3.0"
4444
protoc-wheel-0 = "^21.1"
4545
psutil = "^5.9.3"
@@ -76,7 +76,7 @@ lint = [
7676
# TODO(cretz): Why does pydocstyle complain about @overload missing docs after
7777
# https://github.com/PyCQA/pydocstyle/pull/511?
7878
lint-docs = "pydocstyle --ignore-decorators=overload"
79-
lint-types = "mypy --namespace-packages ."
79+
lint-types = "mypy --namespace-packages --check-untyped-defs ."
8080
run-bench = "python scripts/run_bench.py"
8181
test = "pytest"
8282

scripts/run_bench.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@
1414
from temporalio.worker import UnsandboxedWorkflowRunner, Worker
1515
from temporalio.worker.workflow_sandbox import SandboxedWorkflowRunner
1616

17+
assert sys.version_info >= (3, 9)
18+
1719

1820
@workflow.defn
1921
class BenchWorkflow:

temporalio/api/batch/v1/message_pb2.py

Lines changed: 0 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

temporalio/api/cluster/v1/message_pb2.py

Lines changed: 0 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

temporalio/api/command/v1/message_pb2.py

Lines changed: 0 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

temporalio/api/command/v1/message_pb2.pyi

Lines changed: 22 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1148,24 +1148,27 @@ class Command(google.protobuf.message.Message):
11481148
) -> None: ...
11491149
def WhichOneof(
11501150
self, oneof_group: typing_extensions.Literal["attributes", b"attributes"]
1151-
) -> typing_extensions.Literal[
1152-
"schedule_activity_task_command_attributes",
1153-
"start_timer_command_attributes",
1154-
"complete_workflow_execution_command_attributes",
1155-
"fail_workflow_execution_command_attributes",
1156-
"request_cancel_activity_task_command_attributes",
1157-
"cancel_timer_command_attributes",
1158-
"cancel_workflow_execution_command_attributes",
1159-
"request_cancel_external_workflow_execution_command_attributes",
1160-
"record_marker_command_attributes",
1161-
"continue_as_new_workflow_execution_command_attributes",
1162-
"start_child_workflow_execution_command_attributes",
1163-
"signal_external_workflow_execution_command_attributes",
1164-
"upsert_workflow_search_attributes_command_attributes",
1165-
"accept_workflow_update_command_attributes",
1166-
"complete_workflow_update_command_attributes",
1167-
"modify_workflow_properties_command_attributes",
1168-
"reject_workflow_update_command_attributes",
1169-
] | None: ...
1151+
) -> (
1152+
typing_extensions.Literal[
1153+
"schedule_activity_task_command_attributes",
1154+
"start_timer_command_attributes",
1155+
"complete_workflow_execution_command_attributes",
1156+
"fail_workflow_execution_command_attributes",
1157+
"request_cancel_activity_task_command_attributes",
1158+
"cancel_timer_command_attributes",
1159+
"cancel_workflow_execution_command_attributes",
1160+
"request_cancel_external_workflow_execution_command_attributes",
1161+
"record_marker_command_attributes",
1162+
"continue_as_new_workflow_execution_command_attributes",
1163+
"start_child_workflow_execution_command_attributes",
1164+
"signal_external_workflow_execution_command_attributes",
1165+
"upsert_workflow_search_attributes_command_attributes",
1166+
"accept_workflow_update_command_attributes",
1167+
"complete_workflow_update_command_attributes",
1168+
"modify_workflow_properties_command_attributes",
1169+
"reject_workflow_update_command_attributes",
1170+
]
1171+
| None
1172+
): ...
11701173

11711174
global___Command = Command

temporalio/api/common/v1/grpc_status_pb2.py

Lines changed: 0 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

temporalio/api/common/v1/message_pb2.py

Lines changed: 0 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)