Skip to content

Commit 24fe116

Browse files
committed
introduce WebTask from which SimulationTask and BatchTask subclass
1 parent 7f3c898 commit 24fe116

File tree

5 files changed

+389
-358
lines changed

5 files changed

+389
-358
lines changed

tidy3d/components/tcad/mesher.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,4 +26,7 @@ def _get_simulation_types(self) -> list[TCADAnalysisTypes]:
2626
return [TCADAnalysisTypes.MESH]
2727

2828
def validate_pre_upload(self):
29+
"""Validate the VolumeMesher before uploading to the cloud.
30+
Currently no validation but method is required when calling ``web.upload``.
31+
"""
2932
return

tidy3d/web/api/states.py

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -36,16 +36,13 @@
3636

3737
END_STATES = ERROR_STATES | COMPLETED_STATES
3838

39-
POST_VALIDATE_STATES = {
40-
"validate_success",
41-
"validate_warn",
42-
}
39+
POST_VALIDATE_STATES = {"validate_success", "validate_warn"}
4340

4441
RUNNING_STATES = (
4542
PRE_VALIDATE_STATES | POST_VALIDATE_STATES | {"running"} | POST_RUN_STATES | COMPLETED_STATES
4643
)
4744

48-
ALL_POST_VALIDATE_STATES = POST_VALIDATE_STATES | {"running"} | POST_RUN_STATES | COMPLETED_STATES
45+
ALL_POST_VALIDATE_STATES = POST_VALIDATE_STATES | {"running"} | POST_RUN_STATES | END_STATES
4946

5047
VALID_PROGRESS_STATES = RUNNING_STATES | PRE_ERROR_STATES
5148

@@ -101,4 +98,8 @@
10198
"run_failed": 0,
10299
"aborted": 0,
103100
"deleted": 0,
101+
"validate_error": 0,
102+
"preprocess_error": 0,
103+
"run_error": 0,
104+
"postprocess_error": 0,
104105
}

0 commit comments

Comments
 (0)