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
matplotlib.dates.DayLocator cannot handle invalid input #6935
Labels
Difficulty: Easy
https://matplotlib.org/devdocs/devel/contribute.html#good-first-issues
Milestone
Comments
Looks like we're having a premature optimization:
I'd just strip out everything but the last line and call |
tacaswell
added
the
Difficulty: Easy
https://matplotlib.org/devdocs/devel/contribute.html#good-first-issues
label
Aug 13, 2016
LindyBalboa
pushed a commit
to LindyBalboa/matplotlib
that referenced
this issue
Aug 18, 2016
Check that interval parameter is an integer greater than zero. Delete unuseful 'optimization' meant to prevent exceeding the MAXTICKS variable. During testing it seemed ineffective. The following Locator.raise_if_exceeds exception was triggered first anyways. resolves matplotlib#6935
LindyBalboa
pushed a commit
to LindyBalboa/matplotlib
that referenced
this issue
Aug 18, 2016
LindyBalboa
pushed a commit
to LindyBalboa/matplotlib
that referenced
this issue
Aug 21, 2016
Check that interval parameter is an integer greater than zero. Delete unuseful 'optimization' meant to prevent exceeding the MAXTICKS variable. During testing it seemed ineffective. The following Locator.raise_if_exceeds exception was triggered first anyways. resolves matplotlib#6935
LindyBalboa
pushed a commit
to LindyBalboa/matplotlib
that referenced
this issue
Aug 21, 2016
QuLogic
modified the milestones:
2.0 (style change major release),
2.1 (next point release)
Aug 22, 2016
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This is a relatively minor bug in the way DayLocator tries to report an error message when running the tick_values() method. It is unable to report the invalid input because the invalid input causes a type error while formatting the error message. To be clear, the issue is not that the class breaks with invlaid input but how it breaks with invalid input.
The method could check for Nan or Inf numpy.float64 values before trying to use the %d format, switch to the %f format or catch zero-width intervals at initialization time.
Matplotlib 1.5.2, Anaconda Python 2.7 on Mac OSX
The text was updated successfully, but these errors were encountered: