-
-
Notifications
You must be signed in to change notification settings - Fork 194
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
fix: filter by zoom level for min/max zoom 0 #871
Conversation
Pull Request Test Coverage Report for Build dcc9261d9-PR-871
💛 - Coveralls |
Now that i think of it, it might not be necessary. It might suffice if you prompt the user that 0 is not a supported min zoom level and/or default to 1. Either way, your input would be much appreciated here @ARolek |
@iwpnd the change you submitted is really simple, so no issues there. I'm trying to figure out why I put the logic check in for zoom == 0. Looking back at the blame history it was something I put in 5 years ago when I originally authored this file and I can't for the life of me remember why.
I like this idea. Just add a log in saying Thanks for the PR and investigation. |
@ARolek I'm afraid that won't work for max_zoom 0 as tegola sets the constant max zoom of 22 if the MaxZoom is left blank in the toml. Modifying ParseInt would potentially negatively impact other variables in the config, so that is not an option either. edit: nevermind my dumb ass, i can just check whether value is 0 after I make sure that |
as per go-spatial#870, setting max_zoom to 0 currently causes the layer to bleed through over the entire zoom range. Either we fix filtering as per go-spatial#871 or make sure max_zoom is never 0 as I do in this PR.
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.
LGTM
Prior to this, setting min_zoom=0 and max_zoom=0 would result in the layer being present across the entire zoom range.
856aaaa
to
a78880d
Compare
as per go-spatial#870, setting max_zoom to 0 currently causes the layer to bleed through over the entire zoom range. Either we fix filtering as per go-spatial#871 or make sure max_zoom is never 0 as I do in this PR.
Prior to this, setting min_zoom=0 and max_zoom=0 would result
in the layer being present across the entire zoom range.
Should fix #870