-
-
Notifications
You must be signed in to change notification settings - Fork 7.5k
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
Webagg backend: get rid of tornado #20591
Conversation
This seems like a major API change? We either need replacements/backcompat shims or a very clear API change note for the classes that no longer exist. Does this put a floor on our tornado support to versions that know howto play nice with asyncio? |
I guess we could keep the timertornado class around? And do a lazy import of tornado if one uses it. This way the PR would just be about adding a new timer class that doesn't need tornado, and that ipympl could use. |
I don't know enough about the ecosystem (whether the jupyter side or the async side :-)) to have an answer here, but do you think anyone is actually relying on the tornado timer? Could it be reasonably deprecated? Or perhaps more mildly, moved to backend_webagg, and make backend_webagg_core a "you need to provide your own timer" abstract backend? |
Given the comments and concerns about backward compatibility, I've put back the Having the |
is there still hope on this for 3.5.0 ? |
@stonebig It looks like there are still a few back-compatibility changes that need to be addressed. We have not "feature frozen" for 3.5 yet, can you give me a sense of how important / impactful getting this in would be? |
For a windows user, Tornado is non-performant. So my interest to push this, as I believe it will have positive effects for python on web and python on windows. Nothing more. |
a3a3d59
to
25d01a3
Compare
This PR is affected by a re-writing of our history to remove a large number of accidentally committed files see discourse for details. To recover this PR it will need be rebased onto the new default branch (main). There are several ways to accomplish this, but we recommend (assuming that you call the matplotlib/matplotlib remote git remote update
git checkout main
git merge --ff-only upstream/main
git checkout YOUR_BRANCH
git rebase --onto=main upstream/old_master
# git rebase -i main # if you prefer
git push --force-with-lease # assuming you are tracking your branch If you do not feel comfortable doing this or need any help please reach out to any of the Matplotlib developers. We can either help you with the process or do it for you. Thank you for your contributions to Matplotlib and sorry for the inconvenience. |
This allows using the webagg backend in JupyterLite, by replacing tornado with asyncio
Co-authored-by: David Brochart <david.brochart@gmail.com>
25d01a3
to
8fd2c59
Compare
tornado 5 is from ~2018 hence is consistent with our support window policy.
…591-on-v3.5.x Backport PR #20591 on branch v3.5.x (Webagg backend: get rid of tornado)
I’m packaging matplotlib for ArchLinux and I have some questions regarding this changes:
|
It is still needed, because the webagg backend provides a But in the long term the dependency might be removed? Please someone correct me if I am wrong. |
The important change here is that However matplotlib/lib/matplotlib/backends/backend_webagg.py Lines 54 to 57 in 49609c3
We may want to rename this as |
PR Summary
This allows using the webagg backend in JupyterLite, by replacing tornado with asyncio. See matplotlib/ipympl#334 and https://github.com/jtpio/jupyterlite/pull/219
cc. @davidbrochart
PR Checklist
pytest
passes).flake8
on changed files to check).flake8-docstrings
and runflake8 --docstring-convention=all
).doc/users/next_whats_new/
(follow instructions in README.rst there).doc/api/next_api_changes/
(follow instructions in README.rst there).