Hi, community, just opened an RFC about `JSON IDL`...
# contribute
d
Hi, community, just opened an RFC about
JSON IDL
to solve dict, dataclass and pydantic issue in flytekit. We will have 100% type correct after this implementation is done and closed 10+ issues. Please take a look, thank you all. https://github.com/flyteorg/flyte/pull/5607 @glamorous-carpet-83516 @high-accountant-32689 @freezing-airport-6809 @thankful-minister-83577 @cool-lifeguard-49380 @flaky-parrot-42438 @gorgeous-waitress-5026 @clean-glass-36808 @agreeable-kitchen-44189
👀 1
c
Does it also solve the problem when you put an enum into a dict and on the other side it’s not an enum anymore but the respective enum value type like int or str?
❤️ 1
f
good call out
it should
c
Read the RFC and it makes me really happy that messagepack seems to just “save the day” 👏 My most important feedback on the RFC is this comment. Hope we can find a solution that provides a better UX.
🔥 2
This related issue is important to me as well 🙈
❤️ 1
d
I will reply all of your questions today
thank you so much @cool-lifeguard-49380 for always be there answer community's questions and become an amazing contributor
I've replied about the potential problem will happen about not using
Annotated[dict, Json]
. https://github.com/flyteorg/flyte/pull/5607#pullrequestreview-2208145993 Please take a look, thank you all. (I won't attend next contributor's meetup since that's too late for me.) @cool-lifeguard-49380 @thankful-minister-83577
Hi, @cool-lifeguard-49380 Just discussed the Union Type Issue for your case. Here's the conclusion. https://github.com/flyteorg/flyte/issues/5489#issuecomment-2263378189 Thank you!
c
I think I don’t fully understand the proposed solution. Do you propose to compare the python import paths of the input value to the union variants of the task in flytepropeller’s compiler logic? If so, how would that account for inheritance?
d
Let me take a look and reply you later today
🙏 1
c
@damp-lion-88352 we can discuss this issue outside of the messagepack rfc
They both touch e.g. the dataclass transformer but it’s not the same issue.
d
Yes no prob