Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Locally-runnable DAG breaks down for complex examples #1172

Open
2 of 6 tasks
elliotgunton opened this issue Aug 22, 2024 · 1 comment
Open
2 of 6 tasks

Locally-runnable DAG breaks down for complex examples #1172

elliotgunton opened this issue Aug 22, 2024 · 1 comment
Labels
type:bug A general bug

Comments

@elliotgunton
Copy link
Collaborator

elliotgunton commented Aug 22, 2024

Pre-bug-report checklist

1. This bug can be reproduced using pure Argo YAML

If yes, it is more likely to be an Argo bug unrelated to Hera. Please double check before submitting an issue to Hera.

2. This bug occurs in Hera when...

  • exporting to YAML
  • submitting to Argo
  • running on Argo with the Hera runner
  • other: running new dag decorator function locally

Bug report

Describe the bug
A clear and concise description of what the bug is:

When running locally, parameters/artifacts won't be loaded via Pydantic deserialization, meaning I cannot run locally for non-POD parameter types.

Error log if applicable:

pydantic_core._pydantic_core.ValidationError: 2 validation errors for FeatureScalingInput
X_train
  Input should be a valid dictionary [type=dict_type, input_value='{...}', input_type=str]

To Reproduce
Full Hera code to reproduce the bug:
Previous task output:

class DatasetsOutput(Output):
    X_train: Annotated[str, Artifact(name="X_train", archive=NoneArchiveStrategy())]
    X_test: Annotated[str, Artifact(name="X_test", archive=NoneArchiveStrategy())]
    y_train: Annotated[str, Artifact(name="y_train", archive=NoneArchiveStrategy())]
    y_test: Annotated[str, Artifact(name="y_test", archive=NoneArchiveStrategy())]

Task input:

class FeatureScalingInput(Input):
    X_train: Annotated[dict, Artifact(name="X_train", loader=ArtifactLoader.json)]
    X_test: Annotated[dict, Artifact(name="X_test", loader=ArtifactLoader.json)]

Dag:

@w.dag()
def run_training(_: Input):
    datasets = load_and_split_dataset(LoadDatasetInput())
    scaling = feature_scaling(
        FeatureScalingInput(X_train=datasets.X_train, X_test=datasets.X_test)
    )

Expected behavior
A clear and concise description of what you expected to happen:

To be able to run locally. Example works on-cluster

Environment

  • Hera Version: 5.16.2
  • Python Version: 3.12.4
  • Argo Version: 3.5.10

Additional context
Add any other context about the problem here.

@elliotgunton elliotgunton added the type:bug A general bug label Aug 22, 2024
@elliotgunton elliotgunton added this to the HEP0001 - new decorators milestone Sep 2, 2024
@elliotgunton
Copy link
Collaborator Author

elliotgunton commented Oct 1, 2024

Related/higher priority - #1223

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type:bug A general bug
Projects
None yet
Development

No branches or pull requests

1 participant