gravitystorm / openstreetmap-carto

A general-purpose OpenStreetMap mapnik style, in CartoCSS
Other
1.55k stars 822 forks source link

Kosmtik preview fails with 'Project not loaded properly' #4360

Closed tajchert closed 3 years ago

tajchert commented 3 years ago

When I run: kosmtik serve ./project.mml

I should see Kosmtik preview of this style, however currently I'm getting:

[httpserver] /openstreetmap-carto/tile/4/4/6.png?t=1617639153488 500
Trace
    at ProjectServer.raise (/usr/local/lib/node_modules/kosmtik/src/back/ProjectServer.js:261:13)
    at ProjectServer.serveTile (/usr/local/lib/node_modules/kosmtik/src/back/ProjectServer.js:67:14)
    at tile (/usr/local/lib/node_modules/kosmtik/src/back/ProjectServer.js:50:108)
    at Project.StateBase.when (/usr/local/lib/node_modules/kosmtik/src/back/StateBase.js:51:33)
    at ProjectServer.serve (/usr/local/lib/node_modules/kosmtik/src/back/ProjectServer.js:50:70)
    at PreviewServer.forwardToProject (/usr/local/lib/node_modules/kosmtik/src/back/PreviewServer.js:74:23)
    at PreviewServer.serve (/usr/local/lib/node_modules/kosmtik/src/back/PreviewServer.js:68:42)
    at Server.emit (events.js:180:13)
    at parserOnIncoming (_http_server.js:642:12)
    at HTTPParser.parserOnHeadersComplete (_http_common.js:117:17)
Project not loaded properly.

And no preview is rendered.

My versions:

I used with no problem same version and Kosmtik with this style (CartoDB positron) and it rendered without any issues, so it seems more like carto style related than Kosmtik itself but there is still open issue of https://github.com/kosmtik/kosmtik/issues/263

tajchert commented 3 years ago

Installing all Noto fonts from and then explicitly Noto Sans Tibetan kind of solved it, now the output is:

[httpserver] /openstreetmap-carto/tile/4/11/6.png?t=1617640387843 500
Trace
    at ProjectServer.raise (/usr/local/lib/node_modules/kosmtik/src/back/ProjectServer.js:261:13)
    at /usr/local/lib/node_modules/kosmtik/src/back/ProjectServer.js:75:30
    at /usr/local/lib/node_modules/kosmtik/node_modules/generic-pool/lib/generic-pool.js:283:11
    at loaded (/usr/local/lib/node_modules/kosmtik/node_modules/mapnik-pool/index.js:23:37)
Postgis Plugin: could not connect to server: No such file or directory
    Is the server running locally and accepting
    connections on Unix domain socket "/tmp/.s.PGSQL.5432"?
Connection string: ' dbname=gis connect_timeout=4'
  encountered during parsing of layer 'landcover-low-zoom' in Layer
[httpserver] /openstreetmap-carto/tile/4/4/9.png?t=1617640387843 500
tajchert commented 3 years ago

Ok, I used Kosmtik in Docker and it works without issue. I'm closing this. If you have similar issues - take a look here and use Docker - https://github.com/gravitystorm/openstreetmap-carto/blob/master/DOCKER.md

2803media commented 3 years ago

hello @tajchert I use the switch2osm tutorial to set up the tile server but I want to use the cartodb positron stylesheet, could you explain how you do it please?

pnorman commented 3 years ago

hello @tajchert I use the switch2osm tutorial to set up the tile server but I want to use the cartodb positron stylesheet, could you explain how you do it please?

This is the OpenStreetMap Carto issue tracker, your question doesn't involve OpenStreetMap Carto.

2803media commented 3 years ago

hello @tajchert I use the switch2osm tutorial to set up the tile server but I want to use the cartodb positron stylesheet, could you explain how you do it please?

This is the OpenStreetMap Carto issue tracker, your question doesn't involve OpenStreetMap Carto.

I just want to use OpenStreetMap Carto with the positron style not the classic mapnik.xml but maybe it not the right way to do this