-
Notifications
You must be signed in to change notification settings - Fork 7
Open
Description
To reproduce:
- create a new ComponentRun and publish it to a WebRegistry
- Then creating a new ComponentRun from the run_id of the first run and try re-publishing it to the same WebRegistry, it should succeed since the ComponentRun should be identical, but instead it fails with the following:
AssertionError Traceback (most recent call last)
Input In [36], in <cell line: 5>()
3 comp_run = ComponentRun.from_existing_run_id("70a319cc3c0e452a94e4b20e8ea2429c")
4 wr = WebRegistry("http://localhost:8000/api/v1")
----> 5 comp_run.to_registry(wr)
File ~/Development/agentos/pcs/component_run.py:122, in ComponentRun.to_registry(self, registry, recurse, force, include_artifacts)
120 spec = registry.get_run_spec(self.identifier, error_if_not_found=False)
121 if spec and not force:
--> 122 assert spec == self.to_spec(), (
123 f"A component run spec with identifier '{self.identifier}' "
124 f"already exists in registry '{registry}' and differs from "
125 "the one being added. Use force=True to overwrite the "
126 "existing one.:\n\n"
127 f"{spec}\n\n"
128 f"{self.to_spec()}"
129 )
130 if recurse:
131 self.run_command.to_registry(
132 registry, recurse=recurse, force=force
133 )
AssertionError: A component run spec with identifier '70a319cc3c0e452a94e4b20e8ea2429c' already exists in registry '<pcs.registry.WebRegistry object at 0x149f56190>' and differs from the one being added. Use force=True to overwrite the existing one.:
{'70a319cc3c0e452a94e4b20e8ea2429c': {'info': {'run_id': '70a319cc3c0e452a94e4b20e8ea2429c', 'status': 'FINISHED', 'user_id': 'unknown', 'end_time': 1649651852830, 'run_uuid': '70a319cc3c0e452a94e4b20e8ea2429c', 'start_time': 1649651822592, 'artifact_uri': './mlruns/0/70a319cc3c0e452a94e4b20e8ea2429c/artifacts', 'experiment_id': '0', 'lifecycle_stage': 'active'}, 'data': {'tags': {'pcs.is_run': 'True', 'mlflow.user': 'andyk', 'mlflow.runName': "PCS Component 'sb3_agent==4cceb65a4331500c6f51c0c995a9bd29cce191bf' at Entry Point 'evaluate'", 'mlflow.source.name': 'documentation/demos/demo_script_sb3_example_agent.py', 'mlflow.source.type': 'LOCAL', 'pcs.run_command_id': '1863351892176986276', 'pcs.is_component_run': 'True', 'mlflow.source.git.commit': '4cceb65a4331500c6f51c0c995a9bd29cce191bf'}, 'params': {}, 'metrics': {}}}}
{'70a319cc3c0e452a94e4b20e8ea2429c': {'info': {'artifact_uri': './mlruns/0/70a319cc3c0e452a94e4b20e8ea2429c/artifacts', 'end_time': 1649651852830, 'experiment_id': '0', 'lifecycle_stage': 'active', 'run_id': '70a319cc3c0e452a94e4b20e8ea2429c', 'run_uuid': '70a319cc3c0e452a94e4b20e8ea2429c', 'start_time': 1649651822592, 'status': 'FINISHED', 'user_id': 'unknown'}, 'data': {'metrics': {}, 'params': {}, 'tags': {'pcs.is_component_run': 'True', 'mlflow.user': 'andyk', 'mlflow.source.git.commit': '4cceb65a4331500c6f51c0c995a9bd29cce191bf', 'pcs.run_command_id': '1863351892176986276', 'mlflow.runName': "PCS Component 'sb3_agent==4cceb65a4331500c6f51c0c995a9bd29cce191bf' at Entry Point 'evaluate'", 'mlflow.source.name': 'documentation/demos/demo_script_sb3_example_agent.py', 'pcs.is_run': 'True', 'mlflow.source.type': 'LOCAL'}}, 'run_command': '1863351892176986276'}}
Metadata
Metadata
Assignees
Labels
No labels