plato-sdk-v2 2.8.4__py3-none-any.whl → 2.8.5__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.
plato/v2/sync/sandbox.py CHANGED
@@ -595,12 +595,18 @@ class SandboxClient:
595
595
  if not dataset_config.compute:
596
596
  raise ValueError(f"Compute configuration is required for dataset '{dataset}'")
597
597
  self.console.print(f"simulator_name: {simulator_name}")
598
+ # Save compute values for state (will be used later when saving state.json)
599
+ config_cpus = dataset_config.compute.cpus
600
+ config_memory = dataset_config.compute.memory
601
+ config_disk = dataset_config.compute.disk
602
+ config_app_port = dataset_config.compute.app_port
603
+ config_messaging_port = dataset_config.compute.plato_messaging_port
598
604
  sim_config = SimConfigCompute(
599
- cpus=dataset_config.compute.cpus,
600
- memory=dataset_config.compute.memory,
601
- disk=dataset_config.compute.disk,
602
- app_port=dataset_config.compute.app_port,
603
- plato_messaging_port=dataset_config.compute.plato_messaging_port,
605
+ cpus=config_cpus,
606
+ memory=config_memory,
607
+ disk=config_disk,
608
+ app_port=config_app_port,
609
+ plato_messaging_port=config_messaging_port,
604
610
  )
605
611
  env_config = Env.resource(simulator_name, sim_config)
606
612
  self.console.print(f"env_config: {env_config}")
@@ -723,6 +729,12 @@ class SandboxClient:
723
729
  sandbox_state.disk = disk
724
730
  sandbox_state.app_port = app_port
725
731
  sandbox_state.messaging_port = messaging_port
732
+ elif mode == "config":
733
+ sandbox_state.cpus = config_cpus
734
+ sandbox_state.memory = config_memory
735
+ sandbox_state.disk = config_disk
736
+ sandbox_state.app_port = config_app_port
737
+ sandbox_state.messaging_port = config_messaging_port
726
738
 
727
739
  # Save state to working_dir/.plato/state.json
728
740
  with open(self.working_dir / self.PLATO_DIR / "state.json", "w") as f:
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: plato-sdk-v2
3
- Version: 2.8.4
3
+ Version: 2.8.5
4
4
  Summary: Python SDK for the Plato API
5
5
  Author-email: Plato <support@plato.so>
6
6
  License-Expression: MIT
@@ -513,7 +513,7 @@ plato/v2/sync/chronos.py,sha256=ChXpasjRzAZjoYTimpPqYydnwEk-IgdxR0SDXDOZbUM,1207
513
513
  plato/v2/sync/client.py,sha256=rsrU7_RhE-syf3FMNw5LaxmF7rYw2GBzC_TPpd-6thk,4986
514
514
  plato/v2/sync/environment.py,sha256=WnDzbyEHpwCSEP8XnfNSjIYS7rt7lYR4HGJjzprZmTQ,5066
515
515
  plato/v2/sync/flow_executor.py,sha256=N41-WCWIJVcCR2UmPUEiK7roNacYoeONkRXpR7lUgT8,13941
516
- plato/v2/sync/sandbox.py,sha256=OJpXtdSNDeYBb8JOPHfW5_8Lzaw7BHZ1oT-Ub2noP8s,55001
516
+ plato/v2/sync/sandbox.py,sha256=fq5xUkqUwsSEoWUp243qsw9JboiGM-duHzycsWZmeX0,55599
517
517
  plato/v2/sync/session.py,sha256=FYVxgGZ3eL_YpoJiUgJamrt-jVaBqJITzFzepOKMRjA,35065
518
518
  plato/v2/utils/__init__.py,sha256=XLeFFsjXkm9g2raMmo7Wt4QN4hhCrNZDJKnpffJ4LtM,38
519
519
  plato/v2/utils/db_cleanup.py,sha256=JMzAAJz0ZnoUXtd8F4jpQmBpJpos2__RkgN_cuEearg,8692
@@ -526,7 +526,7 @@ plato/worlds/base.py,sha256=-RR71bSxEFI5yydtrtq-AAbuw98CIjvmrbztqzB9oIc,31041
526
526
  plato/worlds/build_hook.py,sha256=KSoW0kqa5b7NyZ7MYOw2qsZ_2FkWuz0M3Ru7AKOP7Qw,3486
527
527
  plato/worlds/config.py,sha256=O1lUXzxp-Z_M7izslT8naXgE6XujjzwYFFrDDzUOueI,12736
528
528
  plato/worlds/runner.py,sha256=r9B2BxBae8_dM7y5cJf9xhThp_I1Qvf_tlPq2rs8qC8,4013
529
- plato_sdk_v2-2.8.4.dist-info/METADATA,sha256=sLLcAPK7s-jHZqdMIG2lwIvO1m6CFtqW7bVY_VfLmrc,8652
530
- plato_sdk_v2-2.8.4.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
531
- plato_sdk_v2-2.8.4.dist-info/entry_points.txt,sha256=iynJvTkU7E4MZNtSozVF0Wh083yPm6cuKV362Ol_ez8,133
532
- plato_sdk_v2-2.8.4.dist-info/RECORD,,
529
+ plato_sdk_v2-2.8.5.dist-info/METADATA,sha256=doSSnfribPsl_hHLfU-vDtjyPn3KUE4vGCckSijOkf4,8652
530
+ plato_sdk_v2-2.8.5.dist-info/WHEEL,sha256=WLgqFyCfm_KASv4WHyYy0P3pM_m7J5L9k2skdKLirC8,87
531
+ plato_sdk_v2-2.8.5.dist-info/entry_points.txt,sha256=iynJvTkU7E4MZNtSozVF0Wh083yPm6cuKV362Ol_ez8,133
532
+ plato_sdk_v2-2.8.5.dist-info/RECORD,,