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

Issue 1396 bad png path #1556

Merged
merged 4 commits into from Sep 23, 2015
Merged

Issue 1396 bad png path #1556

merged 4 commits into from Sep 23, 2015

Conversation

@doutriaux1
Copy link
Contributor

@doutriaux1 doutriaux1 commented Sep 18, 2015

No description provided.

@@ -4812,6 +4812,9 @@ def png(self, file, width=None, height=None,
a.plot(array)
a.png('example') # Overwrite a png file
"""
base = os.path.dirname(file)
if base!="" and not os.path.exists(base):
raise vcsError("Output path: %s does not exists" % base)
Copy link
Member

@durack1 durack1 Sep 18, 2015

@doutriaux1 "does not exists" -> "does not exist"

doutriaux1
Copy link
Contributor

doutriaux1 commented on abab644 Sep 18, 2015

je ne parle pas anglais desole. Merci monsieur @durack1 d'avoir corriger ceci pour moi.

durack1
Copy link
Member

durack1 commented on abab644 Sep 18, 2015

Mon plaisir @doutriaux1, mon français est plutôt défraîchi si heureux de simplifier les choses où je peux ..

@@ -4812,6 +4812,9 @@ def png(self, file, width=None, height=None,
a.plot(array)
a.png('example') # Overwrite a png file
"""
base = os.path.dirname(file)
Copy link
Contributor

@aashish24 aashish24 Sep 19, 2015

Why not put this block of code in try catch instead of checking of the file exists? In general thats a better practice

Copy link
Contributor Author

@doutriaux1 doutriaux1 Sep 19, 2015

Because it does not fail, that is actually the issue.

Copy link
Contributor Author

@doutriaux1 doutriaux1 Sep 21, 2015

@aashish24 are you suggesting we create the subdirectory?

Copy link
Contributor

@aashish24 aashish24 Sep 23, 2015

No, I was not.

@aashish24
Copy link
Contributor

@aashish24 aashish24 commented Sep 23, 2015

LGTM 👍

aashish24 added a commit that referenced this issue Sep 23, 2015
@aashish24 aashish24 merged commit 2ff0ff5 into master Sep 23, 2015
5 of 7 checks passed
@aashish24 aashish24 deleted the issue_1396_bad_png_path branch Sep 23, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

3 participants