8000 dates: add warning for usec precision with high years · matplotlib/matplotlib@a5cddc0 · GitHub
[go: up one dir, main page]

Skip to content

Commit a5cddc0

Browse files
committed
dates: add warning for usec precision with high years
1 parent 8f0e7b8 commit a5cddc0

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

lib/matplotlib/dates.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1304,6 +1304,10 @@ def get_locator(self, dmin, dmax):
13041304
locator = RRuleLocator(rrule, self.tz)
13051305
else:
13061306
locator = MicrosecondLocator(interval, tz=self.tz)
1307+
if dmin.year > 20:
1308+
warnings.warn('The MicrosecondLocator needs very early years'
1309+
'to work really well. Please see the '
1310+
'documentation for details.')
13071311

13081312
locator.set_axis(self.axis)
13091313

0 commit comments

Comments
 (0)
0