Skip to main content

SerializationContext

This object holds serialization time contextual information, that can be used when serializing the task and various parameters of a tasktemplate. This is only available when the task is being serialized and can be during a deployment or runtime.

Attributes

  • version: string

    • The version of the task
  • project: string | None

    • The project name
  • domain: string | None

    • The domain name
  • org: string | None

    • The organization name
  • code_bundle: CodeBundle | None

    • The code bundle for the task. This is used to package the code and the inflation path.
  • input_path: string = {{.input}}

    • The path to the inputs for the task. This is used to determine where the inputs will be located
  • output_path: string = {{.outputPrefix}}

    • The path to the outputs for the task. This is used to determine where the outputs will be located
  • interpreter_path: string = /opt/venv/bin/python

    • The path to the interpreter
  • image_cache: ImageCache | None

    • The image cache
  • root_dir: pathlib.Path | None

    • The root directory

Constructors

  • This object holds serialization time contextual information, that can be used when serializing the task and various parameters of a tasktemplate. This is only available when the task is being serialized and can be during a deployment or runtime.

  • Parameters

    • version: string
      • The version of the task
    • code_bundle: Optional[CodeBundle]
      • The code bundle for the task. This is used to package the code and the inflation path.
    • input_path: str
      • The path to the inputs for the task. This is used to determine where the inputs will be located
    • output_path: str
      • The path to the outputs for the task. This is used to determine where the outputs will be located

Methods

def get_entrypoint_path(interpreter_path: Optional[str] = None) - > string
  • Get the entrypoint path for the task. This is used to determine the entrypoint for the task execution.

  • Parameters

    • interpreter_path: Optional[str]
      • The path to the interpreter (python)
  • Return Value: string

    • The entrypoint path for the task.