Commit a95e97a4 authored by Lozac'h Loic's avatar Lozac'h Loic
Browse files

add key "tif"

parent 4df0c169
No related merge requests found
Showing with 8 additions and 1 deletion
+8 -1
...@@ -108,7 +108,14 @@ if __name__ == "__main__": ...@@ -108,7 +108,14 @@ if __name__ == "__main__":
datafeatures = data["features"] datafeatures = data["features"]
for feat in datafeatures: for feat in datafeatures:
durl = feat["properties"]["services"]["download"]["url"] pdown = feat["properties"]["services"]["download"]
for key in pdown :
if key == "tif":
durl = pdown["tif"]["url"]
elif key == "zip":
durl = pdown["zip"]["url"]
else:
raise Exception("Property url not find in "+str(pdown))
spurl = durl.split("/") spurl = durl.split("/")
if len(spurl) < 3 : if len(spurl) < 3 :
spurl = durl.split("%2F") spurl = durl.split("%2F")
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment