Skip to content
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

Restructure output format #2179

Merged
merged 1 commit into from
Aug 23, 2023
Merged

Restructure output format #2179

merged 1 commit into from
Aug 23, 2023

Conversation

jonatanklosko
Copy link
Member

@jonatanklosko jonatanklosko commented Aug 23, 2023

I've been meaning to do this for a while, but with recent text changes it felt like a good moment.

So far we used tuples for outputs, but that is a bit annoying in certain places and makes pattern matching more verbose if we ignore tuple elements. Given that outputs are data structures that we keep, I should've done it from the start :)

I also moved output types specification from kino here. It's a fairly low-level detail, that doesn't matter for kino users in practice, and it is a part of the runtime specification, so here's a better place. Additionally, here we actually work with the outputs, so detailed typespecs can be more helpful.

I added a normalization function (Session.normalize_runtime_output/1) for backward compatibility and it handles all attributes that were added incrementally and may not be present. Going forward we should always normalize outputs there, so that we can assume complete outputs everywhere else.

@github-actions
Copy link

github-actions bot commented Aug 23, 2023

Uffizzi Preview deployment-34257 was deleted.

@jonatanklosko jonatanklosko merged commit da9cc66 into main Aug 23, 2023
@jonatanklosko jonatanklosko deleted the jk-outputs branch August 23, 2023 21:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants