Permalink
Browse files

Fix missing max interval in xAxisConfigs

Missing max was causing graphs over 1yr with few very points (say,
monthly data) to default to a 12hrly xAxisConfig. Fixes #155
  • Loading branch information...
1 parent 4147c84 commit 66e88b3d8dd2c333411ef438f0e80642a5390690 @mleinart mleinart committed Mar 15, 2013
Showing with 1 addition and 1 deletion.
  1. +1 −1 webapp/graphite/render/glyph.py
View
2 webapp/graphite/render/glyph.py
@@ -95,7 +95,7 @@
dict(seconds=30, minorGridUnit=MIN, minorGridStep=10, majorGridUnit=HOUR, majorGridStep=1, labelUnit=HOUR, labelStep=1, format="%H:%M", maxInterval=2*DAY),
dict(seconds=60, minorGridUnit=MIN, minorGridStep=30, majorGridUnit=HOUR, majorGridStep=2, labelUnit=HOUR, labelStep=2, format="%H:%M", maxInterval=2*DAY),
dict(seconds=100, minorGridUnit=HOUR, minorGridStep=2, majorGridUnit=HOUR, majorGridStep=4, labelUnit=HOUR, labelStep=4, format=percent_l_supported and "%a %l%p" or "%a %I%p", maxInterval=6*DAY),
- dict(seconds=255, minorGridUnit=HOUR, minorGridStep=6, majorGridUnit=HOUR, majorGridStep=12, labelUnit=HOUR, labelStep=12, format=percent_l_supported and "%m/%d %l%p" or "%m/%d %I%p"),
+ dict(seconds=255, minorGridUnit=HOUR, minorGridStep=6, majorGridUnit=HOUR, majorGridStep=12, labelUnit=HOUR, labelStep=12, format=percent_l_supported and "%m/%d %l%p" or "%m/%d %I%p", maxInterval=10*DAY),
dict(seconds=600, minorGridUnit=HOUR, minorGridStep=6, majorGridUnit=DAY, majorGridStep=1, labelUnit=DAY, labelStep=1, format="%m/%d", maxInterval=14*DAY),
dict(seconds=600, minorGridUnit=HOUR, minorGridStep=12, majorGridUnit=DAY, majorGridStep=1, labelUnit=DAY, labelStep=1, format="%m/%d", maxInterval=365*DAY),
dict(seconds=2000, minorGridUnit=DAY, minorGridStep=1, majorGridUnit=DAY, majorGridStep=2, labelUnit=DAY, labelStep=2, format="%m/%d", maxInterval=365*DAY),

0 comments on commit 66e88b3

Please sign in to comment.