Skip to content
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

OGC API - Tiles should not return 404 for tiles which are within the limits of the TMS #1958

Open
doublebyte1 opened this issue Mar 10, 2025 · 0 comments
Assignees
Labels
bug Something isn't working OGC API - Tiles OGC API - Tiles

Comments

@doublebyte1
Copy link
Contributor

doublebyte1 commented Mar 10, 2025

Description
According to Requirement 6 of the OGC API - Tiles Standard:

  • If the path parameter values tileMatrix, tileRow, tileCol for a tile request are out-of-range (outside the tile matrix set or tile matrix set limits of the resource), validate that the HTTP response is a status code 404 or a 400.
  • If the tile has no content due to lack of data in the area, but is within the data resource’s tile matrix sets and tile matrix sets limits, validate that the HTTP response is a status code either 204 (indicating an empty tile with no content) or a 200 with the content of a blank response compatible with the requested media type (which may or may not be zero bytes long, depending on the output format; e.g., a 0 byte file if valid for the requested format, or a PNG with internal headers and no “pixels”).

pygeoapi is always returning a 404 when it does not find the tile, regardless of whether it is within the tilematrix set limits.

Steps to Reproduce
Request a tile that is within the tile matrix set limits, but has no data. Example:

curl -I https://demo.pygeoapi.io/master/collections/lakes/tiles/WebMercatorQuad/4/7/7?f=pbf
HTTP/2 404 
access-control-allow-origin: *
content-language: en-US
content-type: pbf
date: Mon, 10 Mar 2025 21:09:16 GMT
server: gunicorn
x-powered-by: pygeoapi 0.20.dev0
content-length: 97

Expected behavior
The answer should be 200 or 204. Instead it is 404.

Environment

  • OS: Ubuntu 24.04.2 LTS
  • Python version: 3.11.6
  • pygeoapi version: 0.20.dev0
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working OGC API - Tiles OGC API - Tiles
Projects
None yet
Development

No branches or pull requests

1 participant