USGS-WiM / StreamStatsServices

StreamStats REST Services
https://streamstats.usgs.gov/streamstatsservices
Other
1 stars 0 forks source link

Is client getting local values when global is null? #47

Closed kjacobsen16 closed 3 years ago

kjacobsen16 commented 3 years ago

46.654034, -92.333821 on prod lc06forest is getting the local value - 32.6, not the global value. This is likely because xml globalparameter points to forest, not lc06forest. I adjusted the xml to point to lc06forest on test and got 37.6.

We should find out: (a) is the global lc06forest failing on prod? and (b) what is the client doing in this case?

Another issue is John is getting 34.6 - this is probably a gis data difference.

kjacobsen16 commented 3 years ago

This looks like it's actually an issue with how the services are reading the parameters. I think the line here is looping through each entry in the table and setting the value to the value in that row, so first it takes the local polygon values and assigns the values, then it reassigns them with the global values if it exists.

I think what we should do here instead is check if there is a global polygon (GlobalWshd = 1), then just getting the values from that? Then if no global line, just take local... I'm not really sure the best way to handle it.