Join GitHub today
GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
MAINT: TkAgg default backend depends on tkinter #7530
+27
−7
Conversation
| + """ | ||
| + pkg_name = 'tkinter' if PY3min else 'Tkinter' | ||
| + try: | ||
| + __import__(pkg_name) |
matthew-brett
Nov 29, 2016
Contributor
I think you're right - but maybe worth noting that I'm not using importlib, only the __import__ builtin.
| - if default_backend is None: | ||
| - default_backend = package.name | ||
| + if (isinstance(package, setupext.OptionalBackendPackage) | ||
| + and package.runtime_check() |
tacaswell
Nov 29, 2016
Owner
tacaswell
changed the title from
MAINT: TkAgg default backend depends on tkinter to [MRG+1] MAINT: TkAgg default backend depends on tkinter
Nov 29, 2016
tacaswell
added this to the
2.0.1 (next bug fix release)
milestone
Nov 29, 2016
NelleV
changed the title from
[MRG+1] MAINT: TkAgg default backend depends on tkinter to [MRG+2] MAINT: TkAgg default backend depends on tkinter
Nov 29, 2016
QuLogic
added the
GUI/tk
label
Nov 29, 2016
|
I don't think the indentation change you've made are pep8 compliant (I am not entirely sure on that, so let's wait for the tests). |
|
The indentation looks correct to me, but the binary operator should be before the break. |
tacaswell
merged commit 45e4a46
into matplotlib:master
Dec 1, 2016
tacaswell
added a commit
that referenced
this pull request
Dec 1, 2016
|
|
tacaswell |
7322046
|
|
backported to v2.x as 7322046 Thanks for taking on all of this Tk work! |
QuLogic
changed the title from
[MRG+2] MAINT: TkAgg default backend depends on tkinter to MAINT: TkAgg default backend depends on tkinter
Dec 1, 2016
tacaswell
referenced
this pull request
Dec 1, 2016
Merged
Don't work out packages to install if user requests information from setup.p #7538
QuLogic
modified the milestone: 2.0.1 (next bug fix release), 2.0 (style change major release)
Dec 7, 2016
matthew-brett
referenced
this pull request
Jan 20, 2017
Closed
wheels not picking correct default backend #7874
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
matthew-brett commentedNov 29, 2016
We now always build the TkAgg backend, because it does not depend on the
Tk libraries being on the building system.
This had the unwanted effect of making the TkAgg backend be the default
even if Python tkinter libraries were not installed.
Make a
runtime_checkfunction for the optional packages, that givesTrue if the package can be used at run time, and use that to reject
TkAgg as default backend when tkinter not available.