Add file_extension, enable_legacy_filename fields to BlobType#3406
Draft
ddl-rliu wants to merge 1 commit intoflyteorg:masterfrom
Draft
Add file_extension, enable_legacy_filename fields to BlobType#3406ddl-rliu wants to merge 1 commit intoflyteorg:masterfrom
ddl-rliu wants to merge 1 commit intoflyteorg:masterfrom
Conversation
3 tasks
ddl-rliu
commented
Mar 12, 2026
| "docker>=4.0.0", | ||
| "docstring-parser>=0.9.0", | ||
| "flyteidl>=1.16.1,<2.0.0a0", | ||
| "flyteidl @ git+https://github.com/dominodatalab/flyteidl.git@af517f6", |
Contributor
Author
There was a problem hiding this comment.
Bump this after flyteorg/flyte#7009 merges
ddl-rliu
commented
Mar 12, 2026
| return None | ||
|
|
||
|
|
||
| class FileDownloadConfig: |
Contributor
Author
There was a problem hiding this comment.
Follows same pattern as BatchSize:
flytekit/flytekit/core/type_engine.py
Line 75 in 71194a4
2 tasks
Port new BlobType fields file_extension and enable_legacy_filename to flytekit.
FlyteFile inputs can be annotated with the FileDownloadConfig annotation to
configure the file extension to use during the copilot download phase.
e.g.
```python
def t1(file: Annotated[FlyteFile, FileDownloadConfig(file_extension="csv")]):
... # copilot downloads the file to e.g. /inputs/file.csv
versus...
def t1(file: FlyteFile["csv"]):
... # copilot downloads the file to e.g. /inputs/file
```
caaa6f8 to
8ec4ae4
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
See flyteorg/flyte#7009
This is a draft PR, since it depends on the flyte PR, and the approach proposed in the flyte PR is not finalized.
Tracking issue
Closes flyteorg/flyte#7024
Why are the changes needed?
What changes were proposed in this pull request?
Add file_extension, enable_legacy_filename fields to BlobType. Add annotation "FileDownloadConfig".
The annotation "FileDownloadConfig" is used to annotate a FlyteFile when we want to download the file with a specific extension. For example,
Under the hood, this sets
file_extension, enable_legacy_filenamein BlobType, and depends on flyteorg/flyte#7009How was this patch tested?
Setup process
Screenshots
Check all the applicable boxes
Related PRs
Docs link