• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

MapColonies / shigola / d6dbcb1d5
57%
master: 44%

Build:
Build:
LAST BUILD BRANCH: chore/drop-vendor
DEFAULT BRANCH: master
Ran 08 Sep 2026 03:42PM UTC
Jobs 1
Files 179
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

08 Sep 2026 03:38PM UTC coverage: 44.409% (+0.07%) from 44.344%
d6dbcb1d5

push

github

web-flow
fix(provider): space a tile by its scheme's CRS, not the layer's (MAPCO-11614) (#19)

* fix(provider): space a tile by its scheme's CRS, not the layer's (MAPCO-11614)

ST_AsMVTGeom maps a geometry onto the tile grid affinely, across whatever
envelope it is handed, so the envelope decides which CRS's axis the tile is
spaced by. replaceTokens built !BBOX! by converting the tile's extent into the
layer's SRID, and an mvt_postgis layer hands that straight to ST_AsMVTGeom --
so every tile came out spaced by the layer's CRS, whichever scheme the request
had named.

That is right only while the two coincide, which they did for as long as a
3857 layer in WebMercatorQuad was the only combination served. For a 3857
layer in WorldCRS84Quad it produces a mercator-spaced tile inside a
plate-carree frame: at zoom 1, everything between the equator and 85N lands in
the bottom 8.4% of the tile. Tiles touching 90N are spaced across 238,107,693
metres rather than 20,037,508, because floating-point tan at the pole stops
just short of infinity; tiles touching 90S reached PostgreSQL as
ST_MakeEnvelope(...,-Inf,...) and failed outright with `column "inf" does not
exist`.

!BBOX! keeps its job -- the envelope in the layer's SRID, which is the one the
spatial index is built in and the one to select rows with. !TILE_BBOX! and
!TILE_SRID! are the tile in the scheme's own CRS, which is what ST_AsMVTGeom
clips against, with the geometry transformed to match. Writing both is what
lets one SQL string be exact in every scheme -- the thing .github/cite's
comment said was impossible because nothing in the SQL said which grid the
request came from. Something does now.

Two token fixes ride along, both the same mistake in a different place.
!PIXEL_WIDTH!, !PIXEL_HEIGHT! and !SCALE_DENOMINATOR! divided the tile's span
by 256 in the scheme's own units -- degrees for a geographic scheme -- and
then called the result metres; they now come off the scheme's matrix, which
states resolution in ... (continued)

52 of 65 new or added lines in 2 files covered. (80.0%)

7625 of 17170 relevant lines covered (44.41%)

75.83 hits per line

Uncovered Changes

Lines Coverage ∆ File
12
79.89
-1.06% provider/postgis/util.go
1
64.29
-0.51% provider/provider.go
Jobs
ID Job ID Ran Files Coverage
1 d6dbcb1d5.1 08 Sep 2026 03:42PM UTC 179
44.41
GitHub Action Run
Source Files on build d6dbcb1d5
  • Tree
  • List 179
  • Changed 4
  • Source Changed 0
  • Coverage Changed 4
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • d6dbcb1d on github
  • Prev Build on development (#3FE151A91)
  • Next Build on development (#E49BD3DBC)
  • Delete
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc