-
-
Notifications
You must be signed in to change notification settings - Fork 7.9k
MNT : add guard to not look up HOME env on windows #3829
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
Conversation
I am curious... I would imagine that it would be set if you use a cygwin On Fri, Nov 21, 2014 at 3:43 PM, Thomas A Caswell notifications@github.com
|
It reports it's self as 'cygwin' |
Ah, I didn't think the docs would list cygwin. Ok, then this looks good to me. Waiting for Travis to finish. |
@@ -142,7 +142,7 @@ | |||
"" | |||
] | |||
|
|||
if not USE_FONTCONFIG: | |||
if not USE_FONTCONFIG and sys.paltform != 'win32': |
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.
Typo in 'platform'
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.
How about using os.path.expanduser('~')
?
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.
fixed and forced....
This variable should not be defined on windows so don't even bother looking at it. addresses matplotlib#3804
dd5513e
to
09e1351
Compare
And that is why we have automated tests to catch reviewer mistakes like those. I am presuming that it would be useless to do an expand_user('~') here because the code is building up search paths for X11 and Mac font locations. IIRC, Windows has a completely different font search mechanism. |
MNT : add guard to not look up HOME env on windows
This variable should not be defined on windows so don't
even bother looking at it.
addresses #3804
Suggested by @jbmohler