PathRewrite
Configuration for rewriting paths during input loading.
Attributes
| Attribute | Type | Description |
|---|---|---|
| old_prefix | str | If set, rewrites any path starting with this prefix to the new prefix. |
| new_prefix | str | If set, rewrites any path starting with this prefix to the new prefix. |
Methods
from_str()
@classmethod
def from_str(
pattern: str
) - > [PathRewrite](pathrewrite.md?sid=flyte_models_pathrewrite)
Create a PathRewrite from a string pattern of the form old_prefix- >new_prefix.
Parameters
| Name | Type | Description |
|---|---|---|
| pattern | str | The string pattern representing the path rewrite, expected in the format 'old_prefix- >new_prefix'. |
Returns
| Type | Description |
|---|---|
[PathRewrite](pathrewrite.md?sid=flyte_models_pathrewrite) | A new PathRewrite instance configured with the parsed old and new prefixes. |