Repository navigation
[Code scan] Use run_config for CALYPSO model-deviation step options #354
Description
Found by Codex global repository scan of deepmodeling/dpgen2 at commit 2679611a3704f5c2646c8cb353e34177518db758.
The CALYPSO model-deviation step uses the run template and run executor:
dpgen2/dpgen2/superop/prep_run_calypso.py
Lines 269 to 292 in 2679611
| # run model devi | |
| run_caly_model_devi = Step( | |
| "run-caly-model-devi", | |
| template=PythonOPTemplate( | |
| run_caly_model_devi_op, | |
| slices=Slices( | |
| input_parameter=["task_name"], | |
| input_artifact=["traj_dirs"], | |
| output_artifact=["traj", "model_devi"], | |
| ), | |
| python_packages=upload_python_packages, | |
| **run_template_config, | |
| ), | |
| parameters={ | |
| "type_map": prep_run_caly_steps.inputs.parameters["type_map"], | |
| "task_name": prep_caly_model_devi.outputs.parameters["task_name_list"], | |
| }, | |
| artifacts={ | |
| "traj_dirs": prep_caly_model_devi.outputs.artifacts["grouped_traj_list"], | |
| "models": prep_run_caly_steps.inputs.artifacts["models"], | |
| }, | |
| key="%s--run-caly-model-devi-{{item}}" | |
| % (prep_run_caly_steps.inputs.parameters["block_id"],), | |
| executor=run_executor, |
But the Step receives **prep_config instead of **run_config:
dpgen2/dpgen2/superop/prep_run_calypso.py
Lines 290 to 294 in 2679611
| key="%s--run-caly-model-devi-{{item}}" | |
| % (prep_run_caly_steps.inputs.parameters["block_id"],), | |
| executor=run_executor, | |
| **prep_config, | |
| ) |
This means step-level settings intended for the expensive run phase, such as parallelism or continue-on-failure behavior, can be silently ignored or replaced by prep-step settings.
Suggested fix: pass the remaining run_config to the run-caly-model-devi step and add a workflow construction test that verifies run-step configuration is applied to this step.
Metadata
Metadata
Assignees
Labels
Type
Projects
- StatusShow more project fieldsIn Progress
Activity
fix: apply CALYPSO run-step options