I helped some hotshot developer (who is clearly better Python programmer) debug an app which serves vector tiles. He insisted he wants to use MongoDB, because "he doesn't need to learn SQL". The app worked mostly fine except for low zoom levels in which some country outlines got chopped. The issue was that MongoDB only has spherical geometry as a first-class citizen. If you make a query against a 4-vertex bounding bo…
I remembered the easiest solution to query which lines with some width cross some bounding box (for putting them in quadtree). Just increase BB size by half a line width on each side and you have a very good approximation of a much harder and slower problem. A small percentage of lines will be returned and not drawn, but it's a good trade-off.