Esri / arcgis-osm-editor

ArcGIS Editor for OpenStreetMap is a toolset for GIS users to access and contribute to OpenStreetMap through their Desktop or Server environment.
Apache License 2.0
400 stars 131 forks source link

Problem with DownLoad OSM Data (XAPI) #80

Open tonyemery opened 9 years ago

tonyemery commented 9 years ago

Hello, As I already noted for version 10.2 of the toolbox, this tool still doesn't works. So I tested the script by modifying, replacing the variables by constants and testing every step of the program. It seems that the problem comes from the interpretation of variables that the different functions are unable to recover the form of strings. So I forced this conversion by adding the str () function each time for : in_xapi_url = str(arcpy.GetParameterAsText(0)) request_extent = str(arcpy.GetParameterAsText(1)) request_type = str(arcpy.GetParameterAsText(2)) request_predicate = str(arcpy.GetParameterAsText(3))

It seems that it works. I made a pdf document to explain my approach (in French but I think that's understandable with screenshots). How can I send it?

mhogeweg commented 9 years ago

hi, please feel free to fork the code, apply the fix you describe and submit a pull request!

tonyemery commented 9 years ago

I've just submit a pull request.

tonyemery commented 9 years ago

Hello, I have a problem with the script XAPI. When I want to import the roads relations ("type = associatedStreet"), the relations table is filled well but the associated objects aren't downloaded. Is there a way to proceed to recover the relations and related objects in the same time ?

eggwhites commented 9 years ago

Good question Tony - when you say "associated objects", do you mean other objects that are outside the extent of the download area but have a relationship to the streets within the download area? If that's correct, then the answer is 'no'; the existing tools do not have a mechanism for getting the related associated objects, only the data that is in the extent requested from the XAPI endpoint.

Also on a different note - thanks for submitting the pull request! Will you change the request to pull to our 'dev' branch instead of master? Then we can test before pushing to master. The dev version of the 'download_using_xapi.py' file is the same as master, so you shouldn't have to reconcile any differences in the code.

tonyemery commented 9 years ago

No, I mean data belonging to the relation within the extent of the download. In fact, only the table "relation" fills. The data set of associated features remains empty.

How can I change the request to pull to our 'dev' branch instead of master?