This PR resolves issue #22 , where tilenol returns an empty response when an invalid vector tile specification is used.
For what is considered "valid" we check the specified zoom level against the minimum/maximum zoom level that tilenol has been configured for, and then calculate valid boundaries for x and y as outlined here.
Description
This PR resolves issue #22 , where
tilenol
returns an empty response when an invalid vector tile specification is used.For what is considered "valid" we check the specified zoom level against the minimum/maximum zoom level that
tilenol
has been configured for, and then calculate valid boundaries forx
andy
as outlined here.Testing Done
When running a patched version of
tilenol
I getcurl http://localhost:3000/_all/1000/1000/1000.mvt -v
--> Tile request failed: Invalid zoom level: [1000]. (HTTP error 400)curl http://localhost:3000/_all/2/3/4.mvt -v
-> Tile request failed: Invalid Y value [4] for zoom level [2] (HTTP error 400)curl http://localhost:3000/_all/2/3/3.mvt -v
--> HTTP 200 and data is returned.