Open answerquest opened 7 months ago
sharing for those who're looking for a workaround:
With the generated extract.0sv:
grep -av "^2024" extract.0sv > clean_extract.0sv
Please change the 2024 to later years if you're reading this in the future. Since all the log lines are starting with a datestamp, grepping for lines that don't (-v is inversion) start with it the year. Increase it yyyy-mm or yyyy-mm-dd if you're paranoid. And it's a binary file (even though it has the data in lines), so have to use -a else grep won't play.
sharing for those who're looking for a workaround:
With the generated extract.0sv:
grep -av "^2024" extract.0sv > clean_extract.0sv
Please change the 2024 to later years if you're reading this in the future. Since all the log lines are starting with a datestamp, grepping for lines that don't (-v is inversion) start with it the year. Increase it yyyy-mm or yyyy-mm-dd if you're paranoid. And it's a binary file (even though it has the data in lines), so have to use -a else grep won't play.
I actually run from the country root folder:
grep -av "^YYYY/MM/DD" ./data/openstreetmap/extract.0sv > ./data/polylines/extract.0sv
then it imports it like a charm.
Many thanks for opening this very detailed and informative issue and subsequent comments, you've saved me quite a lot of time!
Thank you for this repo.
Describe the bug First lines of generated
extract.0sv
are having process logs. After 7 lines of logs the expected content starts.After this, throughout the file there are lines interspersed with the data for communicating %age completion. We can spot them because they start with the timestamp.
And then finally ending with "Done":
My initial guess is (note: haven't inspected the code yet): the script is sending all stdout to the extracted file, and now these progress messages are getting mixed in.
Steps to Reproduce
docker build -t pelias/valhalla_baseimage .
wget https://download.geofabrik.de/europe/netherlands-latest.osm.pbf
extract.0sv
is created in the working folder, size: 39.0 MiBExpected behavior We should get an
extract.0sv
file without any process log entries mixed in.Environment (please complete the following information):
Pastebin/Screenshots
Additional context No change from the code snippets given on the readme.
References
I'm here because when running
pelias prepare all
command, I get this:(this is for another country Italy, I was trying with multiple countries) So from the logs it looks like I should be generating polylines
extract.0sv
file independently instead of making the pelias executable do it. Also, it would be great if some could tell me exactly what happens if I place the createdextract.0sv
file in thedata/polylines
folder as per the pelias.json entry:Will it spot the file and use it instead of trying to create one?