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

Isolate try/rescue #140

Merged

Conversation

cristineguadelupe
Copy link
Contributor

No description provided.

# For example: Series.from_list([[1, 2], [2, nil]]) will break on most_frequent and unique
try do
%{"counts" => top_freq, "values" => top} = most_frequent(series)
if most_frequent = most_frequent(series) do
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Instead of wrapping the whole block, could we instead exclude the "top" and "top freq" from summary but still include others?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No, it also breaks on unique.

Copy link
Contributor

@josevalim josevalim left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's use a case instead of if and ship it!

@cristineguadelupe cristineguadelupe merged commit cb2cf09 into livebook-dev:main Jan 20, 2024
1 check passed
@cristineguadelupe cristineguadelupe deleted the cg-isolate-try-rescue branch January 20, 2024 12:03
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