Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

traffic_signal.lua:12: attempt to index global 'traffic_lights' (a nil value) #6663

Closed
rohitgirme opened this issue Jul 28, 2023 · 2 comments

Comments

@rohitgirme
Copy link

rohitgirme commented Jul 28, 2023

Issue

I am using the below data / code

  1. Latest OSM data from https://ftpmirror.your.org/pub/openstreetmap/pbf/planet-latest.osm.pbf.
  2. Profiles from below
    image

While preprocessing the latest OSM data with car profile car.lua from above zip, I get the below error
traffic_signal.lua:12: attempt to index global 'traffic_lights' (a nil value)

It seems to be coming from https://github.com/Project-OSRM/osrm-backend/blob/master/profiles/lib/traffic_signal.lua#L12
I preprocess(i.e. osrm-extract, osrm-contract) the data first, upload to S3 and then download it from S3 in 5.27.1 docker image start. This is so I don't have to run those expensive commands every time docker restarts.

Most relevant issues I could find were
#2288
Not related to OSRM but Lua
mkottman/AndroLua#20

None of these were helpful. Any suggestions?
Is it because the osrm-extract is from the v5.24.0?

Steps to reproduce

wget -q https://ftpmirror.your.org/pub/openstreetmap/pbf/planet-latest.osm.pbf
osrm-extract -p car_5_27_1.lua planet-latest.osm.pbf

Specifications

I am doing this currently in the osrm docker running v5.24.0. But I have copied the profiles for car.lua and dependent profiles/lib from above mentioned link so it works correctly with 5.27.1 osrm docker image.

@mjjbell
Copy link
Member

mjjbell commented Jul 29, 2023

Is there a reason why you are mixing and matching versions? In general, OSRM datasets are not compatible across minor releases.

@rohitgirme
Copy link
Author

The error seems to be because I was using osrm v5.24 profiles. Closing as this is not a bug

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants