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

chore: refine IClassicCom types #3722

Merged
merged 3 commits into from Mar 21, 2023

Conversation

manzt
Copy link
Contributor

@manzt manzt commented Mar 19, 2023

There is heavy use of any in IClassicCom types but then the wrapper in Widget adds unecessary strictness. These types are forwarded by anywidget and raise type errors downstream for seemingly valid arguments: https://twitter.com/domoritz/status/1637504802543345666

This PR adds more precise types and relaxes the strictness of Widget.send to make callbacks optional.

cc: @domoritz

@github-actions
Copy link

Binder 👈 Launch a binder notebook on branch manzt/ipywidgets/manzt/optional

@manzt manzt changed the title chore: refine comm types chore: refine IClassicCom types Mar 19, 2023
@domoritz
Copy link

Sweet, thank you!

Copy link
Member

@martinRenou martinRenou left a comment

Choose a reason for hiding this comment

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

LGTM!

@maartenbreddels
Copy link
Member

Thanks @manzt and thanks for the review @martinRenou

@maartenbreddels maartenbreddels merged commit c1829d3 into jupyter-widgets:main Mar 21, 2023
@martinRenou
Copy link
Member

meeseeksdev please backport to 0.12.x

@lumberbot-app
Copy link

lumberbot-app bot commented Mar 21, 2023

Something went wrong ... Please have a look at my logs.

It seems that the branch you are trying to backport to does not exist.

@martinRenou
Copy link
Member

indeed, wrong repo

@maartenbreddels
Copy link
Member

close :-D

@manzt manzt deleted the manzt/optional branch March 21, 2023 11:17
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.

None yet

4 participants