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
pgr_trsp on windows returns no route #336
Comments
Create a test database and install pgrouting.
I get the following response on Linux:
|
woodbri - confirmed I get the same thing on my windows box. Which pgrouting are you using woodbri. Wonder if its difference between released and development. Output for
and this is on version
I'll install the development version of pgrouting to see if I see the issue there, unless you are testing with the released version and don't see it. |
Put in another ticket. Having issues compiling the development branch noted here: |
@robe2 I'm using:
|
Managed to get a CentOS VM going, installed fresh PostgreSQL 9.4.1 and
pgr_trsp works correctly. |
Yeah, I'm not sure what is going on with this, it is working on Ubuntu 14.04 also, so I suspect that it is a windows specific problem which is a pain to sort out because I don't have my windows development environment setup up anymore. I'll try to work with @robe2 to get it sorted out but it might take a while. |
woodbri, Tho: Well the good news is that the build generated from Vicky's ksp improve branch
get output:
You can download the build here: http://winnie.postgis.net/download/windows/pg94/buildbot/ (the one called pgrouting-pg94-binaries-ksp_improve_boostw64gcc48.zip ) I still have to check the 9.3 because that one is throwing some errors which I think according to Vicky are related to trsp. |
Thanks for the suggestion @robe2 , I installed ksp-improve-boost on 9.4.1, getting the same pgr_version() as you.
|
Ah bah I was testing the wrong thing. Okay still a problem. That was too easy I guess.. |
Okay this is one of those weird ones where it works fine in my mingw64 install, but doesn't on the VC++ build I install it on. I was meaning to also have pgrouting test against the VC++ builds. Anyway that's probably why it passes the tests fine but fails in the general environment. woodbri -- do you support DEBUG level notices so I can switch my postgres to DEBUG level to track what is up here? |
DEBUG you can uncomment this line: |
@robe2 look here: |
@robe2, I made a change to trsp.c in develop branch to try fix this issue and pushed it. Ineed to build on winnie and the the user to test it out and see if it fixes the problem. I can make a change to master if it does and bump the version. |
@robe2 We just merged all of @cvvergara changes for ksp and dijkstra into develop. So we should only look at development for now. |
@Tho77 if you can pull a build of develop from postgis.net and see if the changes I added to develop resolve your problem, that would help. Thanks. |
Installed the one stamped today at 2:46pm.
is still empty. |
OK, thank you for checking. I'll have to leave this to @robe2 to figure out as it is some kind of windows compatibility or build issue. |
Okay will take a look later this weekend. |
This looks like a character encoding issue. I put the debug line in, and when I ran on my default VC++ instance (which happens to default to WIN1252 ) it gave the below error, however if I create a new database using template0 with UTF-8 and run in pgAdmin it gives the right anwer. However since my psql is set to win1252 encoding, it gives the same error below even on my utf8 database unless I do
NOTICE: Calling compute_trsp ERROR: character with byte sequence 0x8d in encoding "WIN1252" has no equivalent in encoding "UTF8" ERROR: character with byte sequence 0x8d in encoding "WIN1252" has no equivalent in encoding "UTF8"
|
oops sorry launched the wrong instance. Stay tuned. :( |
Well it seems to work when I compile on my machine and install. I'll repull winnie's binaries to see whats up. This time I triple checked I was running on the right instance with:
and I get above. @woodbri @dkastl would really help at this point if one of you could update the hash on develop so I can tell if I'm testing the same thing and winnie is not getting a stale binary from somewhere. |
Just bumped the VERSION hash |
Thanks hash changed when I pulled winnies's build but gives broken answer. So going to compare systems next. |
Okay I may be crazy, but it seems setting the debug on was what fixed it on my system. If I take it out, it doesn't work anymore. Perhaps a timing issue and the debug notice is slowing it down enough so it can finish. |
More likely turning on DEBUG is enabling more code to compile which is changing the order of things in memory, and somebody is overwriting memory somewhere. Could this be an issue like you can not pass relative pointers to a DLL? At some point I'll run valgrind on trsp and see if that shows any memory read/write access errors. But I have my plate full at the moment. |
Then again I thought this used to work just fine on windows, but maybe not. |
@robe2 |
@cvvergara, @robe2 git revert 3edbc88 |
Why? is it causing a problem? |
Yes, missing GraphDefinition initialization caused this problem and I fixed it properly. |
ok, its fixed with those initializations, but then the @robe2 temp fix, can be removed? |
Yes, I think that it can be removed. |
Fixed #336 by initializing GraphDefinition class member variables
Sorry, again. git revert 3edbc88 |
@sanak I thought you just said your fixes to trsp made my hack not necessary anymore? But let me check -- I broke something on winnie, so she's having trouble testing. |
@sanak I talked with Vicky. She doesn't want to make any more changes to 2.1 and doesn't want to risk taking the hack out. So she wants to do it on 2.2. I'm fine with that. We can do it immediately after we release 2.1. |
Yes.
Okay, no problem. |
TRSP might get a total rewrite on V2.3, so I repoened so we dont forget that this issue is not forgotten for testing |
What about opening a new issue instead with a reference to this one? |
Yah I think that would be easier and people running 2.1 won't think the issue is not fixed. |
Looks like it was fixed on V2.1, but the milestone for 2.1 is closed, So I will tag as fixed in develop and close it. |
I've been using pgr_dijkstra successfully for several months and am now trying to switch to pgr_trsp.
I've been unable to get any sort of route back from pgr_trsp, so I started fresh and with the sample data, and am still unable to get any route back.
Installed a fresh Windows PostgreSQL v9.4.1 x64 on my local dev box, and used the Application Stack Builder to install PostGIS v2.1.7 which includes pgRouting 2.0.
Created the sample data from http://docs.pgrouting.org/2.0/en/doc/src/developer/sampledata.html
Running the basic sample queries from http://docs.pgrouting.org/2.0/en/src/dijkstra/doc/index.html return valid routes.
Running the basic sample queries from http://docs.pgrouting.org/2.0/en/src/trsp/doc/index.html just returns an empty route.
I initially tried it on some of our other Windows servers with PostgreSQL v9.3/9.4 where pgr_dijkstra works, but got back the same empty route for pgr_trsp.
I don't easily have a way to test a linux installation, but if you think that may be the issue, I will try and put one together to test.
The text was updated successfully, but these errors were encountered: