Skip to content

Commit

Permalink
Add ArtifactLoaders to new_dag_decorator_artifacts
Browse files Browse the repository at this point in the history
Signed-off-by: Elliot Gunton <[email protected]>
  • Loading branch information
elliotgunton committed Sep 30, 2024
1 parent 24d6ff6 commit 7a79a66
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
from typing_extensions import Annotated

from hera.shared import global_config
from hera.workflows import Artifact, Input, Output, Workflow
from hera.workflows import Artifact, ArtifactLoader, Input, Output, Workflow

global_config.experimental_features["decorator_syntax"] = True

Expand All @@ -24,8 +24,8 @@


class ConcatInput(Input):
word_a: Annotated[str, Artifact(name="word_a")]
word_b: Annotated[str, Artifact(name="word_b")]
word_a: Annotated[str, Artifact(name="word_a", loader=ArtifactLoader.json)]
word_b: Annotated[str, Artifact(name="word_b", loader=ArtifactLoader.json)]


@w.script()
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
from typing_extensions import Annotated

from hera.shared import global_config
from hera.workflows import Artifact, Input, Output, Workflow
from hera.workflows import Artifact, ArtifactLoader, Input, Output, Workflow

global_config.experimental_features["decorator_syntax"] = True

Expand All @@ -14,8 +14,8 @@ class ArtifactOutput(Output):


class ConcatInput(Input):
word_a: Annotated[str, Artifact(name="word_a")]
word_b: Annotated[str, Artifact(name="word_b")]
word_a: Annotated[str, Artifact(name="word_a", loader=ArtifactLoader.json)]
word_b: Annotated[str, Artifact(name="word_b", loader=ArtifactLoader.json)]


@w.script()
Expand Down

0 comments on commit 7a79a66

Please sign in to comment.