gis-ops / docker-valhalla

This is our flexible Docker repository for the Valhalla routing engine
MIT License
248 stars 70 forks source link

Crash with missing valhalla.json #105

Closed RomanJuranek closed 1 year ago

RomanJuranek commented 1 year ago

The instructions in README do not include creating valhalla.json. When the file is missing, starting docker image fails on runtime error.

============================
= Build the initial graph. =
============================
terminate called after throwing an instance of 'std::runtime_error'
  what():  Could not parse json, error at offset: 0
/valhalla/scripts/configure_valhalla.sh: line 210:    56 Aborted                 (core dumped) valhalla_build_tiles -c ${CONFIG_FILE} -e build ${files}

It seems that empty json is created along the way but it cannot be parsed. Adding empty object in the json solves the problem. valhalla.json:

{}
chrstnbwnkl commented 1 year ago

This should be fixed with #104 .

nilsnolde commented 1 year ago

You sure? This sounds like a very different problem no?

nilsnolde commented 1 year ago

Ah right, you're saying that valhalla_build_config errored out because of #103 (and OP isn't showing those logs) and now it's throwing because the config file is empty? Makes sense :smile:

chrstnbwnkl commented 1 year ago

Yeah, the fact that valhalla_build_config just created an empty valhalla.json threw me off as well at first :D