Skip to content

adds tests reproducing the error described in issue665 - #703

Closed
easbar wants to merge 1 commit into
graphhopper:masterfrom
easbar:tests_issue665
Closed

easbar wants to merge 1 commit into
graphhopper:masterfrom
easbar:tests_issue665

Conversation

@easbar

@easbar easbar commented Apr 17, 2016

Copy link
Copy Markdown
Member

Adds three tests:

  1. creates the error described in #665 using OSM data and the GraphHopper API

  2. shows that the Graph resulting from the OSM data is invalid in this scenario

  3. reproduces the invalid Graph and shows how the error is produced using the bidirectional Dijkstra algorithm between the two nodes of the Graph directly

@easbar

easbar commented Apr 17, 2016

Copy link
Copy Markdown
Member Author

I simply put all three tests inside OSMReaderTest for now.

@karussell

karussell commented Apr 18, 2016 •

Copy link
Copy Markdown
Member

Thanks again!

The flags are calculated properly but without setting the reverse speed.

The bug is now that when we do not set the reverse speed the speed==0 leads to access==false due to the fix for #367 when calling reverseFlags. This method is called for 'opposite' base nodes ie. when the flags are stored relatively to the adjacent node and all speeds and access properties need to be swapped.

This happens only infrequently as we properly fill speed and reverseSpeed in the case of if !ferry.

So the real reason is that adding 'reverse speed' is overly complicated and too many things can go wrong when adding this to an encoder. Furthermore we should not swap the information explicitely but instead pick the correct speed bits depending on the swapped state, this would also slightly improve perf.

But probably also the magic happening in the fix for #367 is not good and this fix might be not fully correct: f95a09f

@karussell

karussell commented Apr 29, 2016 •

Copy link
Copy Markdown
Member

Thanks a bunch again to @ammagamma for making it very easy for me to reproducing this!

Closing due to the fix in #711

@karussell karussell closed this Apr 29, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants