-
Notifications
You must be signed in to change notification settings - Fork 669
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
[Flyte][2][Literal Type For Scalar] Binary IDL With MessagePack #5761
Conversation
Signed-off-by: Future-Outlier <[email protected]>
Signed-off-by: Future-Outlier <[email protected]>
Signed-off-by: Future-Outlier <[email protected]>
…ith-message-pack-bytes-2
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #5761 +/- ##
=======================================
Coverage 36.29% 36.30%
=======================================
Files 1305 1305
Lines 109997 110000 +3
=======================================
+ Hits 39927 39932 +5
+ Misses 65914 65912 -2
Partials 4156 4156
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
Signed-off-by: Future-Outlier <[email protected]>
Signed-off-by: Future-Outlier <[email protected]>
Signed-off-by: Future-Outlier <[email protected]>
Signed-off-by: Future-Outlier <[email protected]>
if len(v.Binary.Tag) > 0 { | ||
literalType = &core.LiteralType{Type: &core.LiteralType_Simple{Simple: core.SimpleType_STRUCT}} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- update it to
msgpack
Tracking issue
#5318
Why are the changes needed?
When using
Scalar_Binary
with a non-empty Tag (i.e., Tag length > 0), we need to returncore.SimpleType_STRUCT
as the literal type.This allows for the correct handling of structured types in Flyte tasks, such as the following example:
flytekit branch: flyteorg/flytekit#2757
This change ensures that tasks like the one above can properly return structured data, such as dictionaries.
The following image illustrates the call stack showing where the
literalTypeForScalar
method is invoked:What changes were proposed in this pull request?
Scalar_Binary
when the Tag is non-empty, returningcore.SimpleType_STRUCT
as the literal type.How was this patch tested?
Unit tests and remote execution.
Setup process
single binary.
flytekit branch: flyteorg/flytekit#2757
Screenshots
Check all the applicable boxes
Related PRs
Docs link