Rendering parking spaces with osm-carto

osm-carto already renders parking spaces. See here, for instance.

But then we have a case like this one that is not being rendered, even if they share 66% of the 3 tags the last one has. The project’s query for this layer includes sorting the features by size in decreasing order, with the idea of rendering smaller features last, which should make the parking_spaces be rendered on top of the parking lot. And yet, they aren’t.

I executed the following query in and up-to-date database and I get the features I expect in the order I expect:

europe=# SELECT 
    ST_AsBinary("way") AS geom
        COALESCE(amenity) AS feature
    FROM (
            way, COALESCE(name, '') AS name, 
            ('amenity_' || (CASE WHEN amenity IN ('parking', 'parking_space')
                                    OR amenity IN ('parking') AND (tags->'parking' NOT IN ('underground') OR (tags->'parking') IS NULL) THEN amenity ELSE NULL END)) AS amenity,
            tags->'parking_space' as parking_space,                                                                                                                             
            way_area/NULLIF(0.07464553543479724::real*0.07464553543468355::real,0) AS way_pixels
            amenity IN ('parking', 'parking_space')
        ORDER BY                                   
            layer, way_area DESC
    ) AS landcover
) AS features 
WHERE "way" && ST_Transform(ST_MakeEnvelope(5.416179,43.258399,5.417617,43.259505, 4326), 3857);
        feature        | parking_space¹| way_pixels |                    way
 amenity_parking       |               |  274262.78 | \x0103000000010000000a...
 amenity_parking       |               |  203415.11 | \x0103000000010000000e...
 amenity_parking       |               |   48887.86 | \x0103000000010000000c...
 amenity_parking_space |               |  4932.7563 | \x01030000000100000005...
 amenity_parking_space |               |   4667.051 | \x01030000000100000005...

Is mapnik reordering or somehow ignoring these features?

¹ yes, I just noticed the parking_space column is empty. Either daily updates with osm2pgsql does not include the extra tags (the tags->'parking_space' as parking_space in my query, which I added to the original one from the project; I’m interested in parking space types), or I do have an issue with my update process, but I still thinks these places should be rendered with the original code.

Opinions? Ideas?

Are you referring to the two spaces just above the icon for “La Recharge”? I see them rendered (faintly, but there).

Whether it’s relevant or not, don’t know, but all the parking spaces I map, helped by Gridify in JOSM, have the parking_space=* as supplemental tag e.g. disabled, normal, bus, hgv, delivery. That said, no reason but for some renderers the spaces do not all show up, almost random fall out, but in Carto standard I’m seeing 100% for normal, family, disabled, delivery.

Once again, bitten by the cache. Yes, those, but they don’t render in my local stack :frowning: Back to double check everything…