Skip to content

Commit e7f7faf

Browse files
Pyre Bot Jr.facebook-github-bot
authored andcommitted
upgrade pyre version in fbcode/torchx - batch 1
Differential Revision: D64977740
1 parent b6b9450 commit e7f7faf

File tree

4 files changed

+11
-5
lines changed

4 files changed

+11
-5
lines changed

.pyre_configuration

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,14 +9,14 @@
99
"ignore_all_errors": [
1010
"./stubs/"
1111
],
12+
"search_path": [
13+
"stubs"
14+
],
1215
"site_package_search_strategy": "all",
1316
"source_directories": [
1417
"scripts",
1518
"."
1619
],
17-
"search_path": [
18-
"stubs"
19-
],
2020
"strict": true,
21-
"version": "0.0.101709640814"
21+
"version": "0.0.101729681899"
2222
}

torchx/examples/apps/tracker/main.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,8 @@ def test(
9999
for data, target in test_loader:
100100
data, target = data.to(device), target.to(device)
101101
output = model(data)
102+
# pyre-fixme[58]: `+` is not supported for operand types `int` and
103+
# `Union[bool, float, int]`.
102104
test_loss += F.nll_loss(
103105
output, target, reduction="sum"
104106
).item() # sum up batch loss

torchx/pipelines/kfp/adapter.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,9 @@ def component_spec_from_app(app: api.AppDef) -> Tuple[str, api.Role]:
5050

5151
role = app.roles[0]
5252
assert (
53-
role.num_replicas == 1
53+
role.num_replicas
54+
== 1
55+
# pyre-fixme[16]: `AppDef` has no attribute `num_replicas`.
5456
), f"KFP adapter only supports one replica, got {app.num_replicas}"
5557

5658
command = [role.entrypoint, *role.args]

torchx/schedulers/aws_batch_scheduler.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -809,6 +809,8 @@ def _stream_events(
809809
startFromHead=True,
810810
**args,
811811
)
812+
# pyre-fixme[66]: Exception handler type annotation `unknown` must
813+
# extend BaseException.
812814
except self._log_client.exceptions.ResourceNotFoundException:
813815
return [] # noqa: B901
814816
if response["nextForwardToken"] == next_token:

0 commit comments

Comments
 (0)