-
Notifications
You must be signed in to change notification settings - Fork 2k
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
ipython: remove dependency tree on matplotlib #33584
Conversation
eli-schwartz
commented
Oct 30, 2023
Pull Request assignmentSubmitter: @eli-schwartz dev-python/ipython: @gentoo/python Linked bugsNo bugs to link found. If your pull request references any of the Gentoo bug reports, please add appropriate GLEP 66 tags to the commit message and request reassignment. If you do not receive any reply to this pull request, please open or link a bug to attract the attention of maintainers. In order to force reassignment and/or bug reference scan, please append Docs: Code of Conduct ● Copyright policy (expl.) ● Devmanual ● GitHub PRs ● Proxy-maint guide |
SLOT="0" | ||
KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~ia64 ~loong ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~arm64-macos ~x64-macos" | ||
|
||
RDEPEND=" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I suspect it's worth a comment here above RDEPEND for the lack of mpl dep.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is that still necessary considering the optfeatures suggestion?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Answering my own question: that was a dumb, sleep-deprived question because we are not talking about the same package.
Pull request CI reportReport generated at: 2023-10-30 03:46 UTC There are existing issues already. Please look into the report to make sure none of them affect the packages in question: |
optfeature "code formatting" dev-python/black | ||
optfeature "sympyprinting" dev-python/sympy | ||
optfeature "cythonmagic" dev-python/cython | ||
optfeature "%lprun magic command" dev-python/line-profiler |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If we drop the rdep, then we should probably add mpl to the optfeature list here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Indeed, that makes a lot of sense especially considering how integrated other magic commands already are here. :)
Pull request CI reportReport generated at: 2023-10-30 12:26 UTC There are existing issues already. Please look into the report to make sure none of them affect the packages in question: |
This python module is an ipython extension that exists solely to implement the `%matplotlib` magic inside of the ipython shell and directly interacts with the ipython extension API to do it. Despite this, it does NOT have an ebuild dependency on ipython itself, even though you cannot `import matplotlib_inline.backend_inline` without ipython installed. It does have a dependency on matplotlib, which is another import-time import. However, the setup.cfg intentionally avoids depending on either one. This is because both are actually internal implementation details of *ipython*. In turn, ipython does not wish to have a mandatory runtime dependency on matplotlib, all it wishes to do is have code prepared and ready to import matplotlib, should a user execute `%matplotlib` in the interactive console. In this case, it is assumed that the user has also installed matplotlib. Respect the upstream dependency. Signed-off-by: Eli Schwartz <eschwartz93@gmail.com>
unstable, superseded by a .1 point release Signed-off-by: Eli Schwartz <eschwartz93@gmail.com>
ipython does not use or rely on matplotlib at runtime in any way. It does contain imports for it, but these imports are only triggered by the act of typing `%matplotlib` into the interactive shell, which is an ipython "magic" that runs matplotlib with some enhanced context. People who do not use matplotlib don't need to have its installation forced, and people who do use matplotlib will have it installed before interactively using it, much as they do when interactively using it with `import matplotlib`. It is intentionally not listed as an install requirement in setup.cfg, although the matplotlib-inline module *is* listed as an install requirement. (matplotlib-inline contains the actual implementation of the magic, and is very lightweight, so it is not particularly advantageous to add a USE flag for it. Users of matplotlib won't automatically have the -inline module installed.) Per the way other magic commands work, the correct place to notify users about the availability of these is using optfeature. Signed-off-by: Eli Schwartz <eschwartz93@gmail.com>
It was removed from setup.cfg in ipython 8.5 "because it is not even used". This historical error should be corrected in gentoo packaging as well. Signed-off-by: Eli Schwartz <eschwartz93@gmail.com>
Updated with the comment plus revbumping and fixing up the new ipython version that was committed today. |
Pull request CI reportReport generated at: 2023-10-30 19:46 UTC There are existing issues already. Please look into the report to make sure none of them affect the packages in question: |