nost-tools 2.1.0__py3-none-any.whl → 2.1.1__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of nost-tools might be problematic. Click here for more details.
- nost_tools/__init__.py +1 -1
- nost_tools/schemas.py +19 -3
- {nost_tools-2.1.0.dist-info → nost_tools-2.1.1.dist-info}/METADATA +1 -1
- {nost_tools-2.1.0.dist-info → nost_tools-2.1.1.dist-info}/RECORD +7 -7
- {nost_tools-2.1.0.dist-info → nost_tools-2.1.1.dist-info}/WHEEL +0 -0
- {nost_tools-2.1.0.dist-info → nost_tools-2.1.1.dist-info}/licenses/LICENSE +0 -0
- {nost_tools-2.1.0.dist-info → nost_tools-2.1.1.dist-info}/top_level.txt +0 -0
nost_tools/__init__.py
CHANGED
nost_tools/schemas.py
CHANGED
|
@@ -339,12 +339,18 @@ class ManagerConfig(BaseModel):
|
|
|
339
339
|
shut_down_when_terminated: bool = Field(
|
|
340
340
|
False, description="Shut down when terminated."
|
|
341
341
|
)
|
|
342
|
+
is_scenario_time_status_step: bool = Field(
|
|
343
|
+
True,
|
|
344
|
+
description="If True, time_status_step is in scenario time and won't be scaled. If False, time_status_step is in wallclock time and will be scaled by the time scale factor.",
|
|
345
|
+
)
|
|
342
346
|
|
|
343
347
|
@model_validator(mode="before")
|
|
344
348
|
def scale_time(cls, values):
|
|
345
349
|
time_scale_factor = values.get("time_scale_factor", 1.0)
|
|
346
350
|
|
|
347
|
-
if "time_status_step" in values
|
|
351
|
+
if "time_status_step" in values and not values.get(
|
|
352
|
+
"is_scenario_time_status_step", True
|
|
353
|
+
):
|
|
348
354
|
time_status_step = values["time_status_step"]
|
|
349
355
|
if isinstance(time_status_step, str):
|
|
350
356
|
hours, minutes, seconds = map(int, time_status_step.split(":"))
|
|
@@ -371,12 +377,20 @@ class ManagedApplicationConfig(BaseModel):
|
|
|
371
377
|
False, description="Shut down when terminated."
|
|
372
378
|
)
|
|
373
379
|
manager_app_name: str = Field("manager", description="Manager application name.")
|
|
380
|
+
is_scenario_time_step: bool = Field(
|
|
381
|
+
True,
|
|
382
|
+
description="If True, time_step is in scenario time and won't be scaled. If False, time_step is in wallclock time and will be scaled by the time scale factor.",
|
|
383
|
+
)
|
|
384
|
+
is_scenario_time_status_step: bool = Field(
|
|
385
|
+
True,
|
|
386
|
+
description="If True, time_status_step is in scenario time and won't be scaled. If False, time_status_step is in wallclock time and will be scaled by the time scale factor.",
|
|
387
|
+
)
|
|
374
388
|
|
|
375
389
|
@model_validator(mode="before")
|
|
376
390
|
def scale_time(cls, values):
|
|
377
391
|
time_scale_factor = values.get("time_scale_factor", 1.0)
|
|
378
392
|
|
|
379
|
-
if "time_step" in values:
|
|
393
|
+
if "time_step" in values and not values.get("is_scenario_time_step", True):
|
|
380
394
|
time_step = values["time_step"]
|
|
381
395
|
if isinstance(time_step, str):
|
|
382
396
|
hours, minutes, seconds = map(int, time_step.split(":"))
|
|
@@ -386,7 +400,9 @@ class ManagedApplicationConfig(BaseModel):
|
|
|
386
400
|
seconds=time_step.total_seconds() * time_scale_factor
|
|
387
401
|
)
|
|
388
402
|
|
|
389
|
-
if "time_status_step" in values
|
|
403
|
+
if "time_status_step" in values and not values.get(
|
|
404
|
+
"is_scenario_time_status_step", True
|
|
405
|
+
):
|
|
390
406
|
time_status_step = values["time_status_step"]
|
|
391
407
|
if isinstance(time_status_step, str):
|
|
392
408
|
hours, minutes, seconds = map(int, time_status_step.split(":"))
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: nost_tools
|
|
3
|
-
Version: 2.1.
|
|
3
|
+
Version: 2.1.1
|
|
4
4
|
Summary: Tools for Novel Observing Strategies Testbed (NOS-T) Applications
|
|
5
5
|
Author-email: "Paul T. Grogan" <paul.grogan@asu.edu>, "Emmanuel M. Gonzalez" <emmanuelgonzalez@asu.edu>
|
|
6
6
|
License-Expression: BSD-3-Clause
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
nost_tools/__init__.py,sha256=
|
|
1
|
+
nost_tools/__init__.py,sha256=bNVX1vszl3KMnBrd1x53pAeZgUUwlPQCF0FuLotlc3Y,870
|
|
2
2
|
nost_tools/application.py,sha256=bPuRMBifppJ-qkDKqOqp13rW_LOjbM7JaXIozMyxmlw,60914
|
|
3
3
|
nost_tools/application_utils.py,sha256=_R39D26FYxgaO4uyTON24KXc4UQ4zAEDBZfEkHbEw64,9386
|
|
4
4
|
nost_tools/configuration.py,sha256=ikNpZi8aofhZzJRbJf4x46afbAnp8r5C7Yr50Rnn1Nc,11639
|
|
@@ -9,10 +9,10 @@ nost_tools/managed_application.py,sha256=7393kCF9FeXlf_pSP_C-tAeNSW9_-smQH6pQgyH
|
|
|
9
9
|
nost_tools/manager.py,sha256=QSOcFqA3xpa84AuxvXV6134PZp8iQndNCq1w3P4tHUU,21315
|
|
10
10
|
nost_tools/observer.py,sha256=D64V0KTvHRPEqbB8q3BosJhoAlpBah2vyBlVbxWQR44,8161
|
|
11
11
|
nost_tools/publisher.py,sha256=omU8tb0AXnA6RfhYSh0vnXbJtrRo4ukx1J5ANl4bDLQ,5291
|
|
12
|
-
nost_tools/schemas.py,sha256=
|
|
12
|
+
nost_tools/schemas.py,sha256=nlMG4gZH-hUdmvz5a2294wGVN9Km7yE80x40vRJJRu8,17670
|
|
13
13
|
nost_tools/simulator.py,sha256=ALnGDmnA_ga-1Lq-bVWi2vcrspgjS4vtuDE0jWsI7fE,20191
|
|
14
|
-
nost_tools-2.1.
|
|
15
|
-
nost_tools-2.1.
|
|
16
|
-
nost_tools-2.1.
|
|
17
|
-
nost_tools-2.1.
|
|
18
|
-
nost_tools-2.1.
|
|
14
|
+
nost_tools-2.1.1.dist-info/licenses/LICENSE,sha256=aAMU-mTHTKpWkBsg9QhkhCQpEm3Gri7J_fVuJov8s3s,1539
|
|
15
|
+
nost_tools-2.1.1.dist-info/METADATA,sha256=fNbyKb9l5zQyeYZfYL9bfV5bfGHV1rF4z__FJ2leKfA,4256
|
|
16
|
+
nost_tools-2.1.1.dist-info/WHEEL,sha256=zaaOINJESkSfm_4HQVc5ssNzHCPXhJm0kEUakpsEHaU,91
|
|
17
|
+
nost_tools-2.1.1.dist-info/top_level.txt,sha256=LNChUgrv2-wiym12O0r61kY83COjTpTiJ2Ly1Ca58A8,11
|
|
18
|
+
nost_tools-2.1.1.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
|
File without changes
|