Esri / solutions-erg-widget

The Emergency Response Guide (ERG) widget allows users to determine potential hazards based on the type of chemical spill and user-selected location on the map.
Apache License 2.0
6 stars 4 forks source link

Translate Weather Station GP Service into JavaScript Functionality #19

Open Dbarnes1 opened 7 years ago

Dbarnes1 commented 7 years ago

Currently, you have to add a weather station GP service while configuring the widget in order to query the weather from a nearby station.

We could translate this functionality to JavaScript, where in the configuration page we allow for a user to select a list of weather stations (feature service) with associated data that they can pull into the widget. The JS would then pick the closest weather station to the input point as a parameter that would help create the output spill scenario.

I think that we should let the user pick a feature service instead of hard coding a nationwide or list of weather stations for Monterey area, but we could provide a sample weather station feature service over our model geography or for the US.

I think that this isn't as high of a priority as converting the Chemical and Placard GP services into JS

Dbarnes1 commented 7 years ago

This functionality has been added: image

Now, we're pulling in current weather data from the Dark Sky service. My question is do we still want to allow users to add their own weather service in lieu of Dark Sky in the configuration page? I'm assuming this Dark Sky service won't link up in any kind of disconnected environment.

Dbarnes1 commented 7 years ago

I've accounted for documentation regarding weather information

Dbarnes1 commented 7 years ago

to conclude from our discussion at scrum, we need to make sure that there is an ability for users to overwrite the default weather service by manually entering their own data. While we already allow this, we also want users to be able to provide their own weather service. I'm going to move this back to in progress, but if it doesn't get completed for this release, users can at least manually enter wind direction in the text box.

adgiles commented 7 years ago

I'm not sure what classes as a weather service and how we will integrate this into a solution. Can somebody provide more detail on what the 'weather' service is

Dbarnes1 commented 7 years ago

I guess people could always bring in static weather data in a feature service, with fields for wind direction and speed. But I'm not sure how we could enable users to provide their own current weather functionality without making them dive into the widget in GitHub and customize it themselves.

@elinz @nfeuerstein any thoughts?

Dbarnes1 commented 7 years ago

According to @karlterrey we have to take out the Dark Sky service, apparently it will also be taken out of IA widget in next release

joebayles commented 7 years ago

We should investigate what other national services do, and mimic that. Seems like Dark Sky is getting their stuff from them as well... https://darksky.net/dev/docs/sources

While the entire weather forecast is useful, the necessary parameters for the calculations are wind direction and speed, so provide the ability to ingest the entire service, but include a point for user input for those two values (which we've done).

adgiles commented 7 years ago

tagged as impeded until it is figured out how we want to handle this

Dbarnes1 commented 7 years ago

could this be a possibility: https://marketplace.arcgis.com/listing.html?id=384d457d8ff2484ca27133e7d9a0e9b9

Trying to search for services that are included in the ArcGIS Marketplace.

Also looks like NOAA has services: http://www.nws.noaa.gov/gis/services.html

Dbarnes1 commented 7 years ago

Based on discussions at scrum, I'm also ok to move this to version after next

adgiles commented 7 years ago

removed the weather info from the UI, moving issue back to backlog

adgiles commented 6 years ago

Anybody see any issues with using yahoos public api to get current weather info?

Sample calls:

Redlands

https://query.yahooapis.com/v1/public/yql?q=select%20*%20from%20weather.forecast%20where%20woeid%20in%20(select%20woeid%20from%20geo.places(1)%20where%20text=%22(34.055198,-117.181818)%22)%20and%20u=%22f%22&format=json

Cape Town, South Africa

https://query.yahooapis.com/v1/public/yql?q=select%20*%20from%20weather.forecast%20where%20woeid%20in%20(select%20woeid%20from%20geo.places(1)%20where%20text=%22(-33.919440,18.425423)%22)%20and%20u=%22f%22&format=json

@lfunkhouser @topowright @ACueva @dfoll @kgonzago

BobBooth commented 6 years ago

"... Terms of Use The above feeds are provided free of charge for use by individuals and non-profit organizations for personal, non-commercial uses. We reserve all rights in and to the Yahoo logo, and your right to use the Yahoo logo is limited to providing attribution in connection with these RSS feeds. Yahoo also reserves the right to require you to cease distributing these feeds at any time for any reason. Usage of these feeds is subject to YDN terms of use. Your use of weather feeds is subject to the Yahoo APIs Terms of Use. ..." (https://developer.yahoo.com/weather/)

BobBooth commented 6 years ago

Terms of use requires signature authority for the organization. "... If you are entering this TOU on behalf of a company or other legal entity, you represent that you have the legal authority to bind the legal entity to this TOU, in which case "you" or "your" shall mean such entity. If you do not have such authority or if you disagree with any of the terms in the TOU or API Documents, Yahoo does not grant you a license to use the Yahoo APIs. ..." (https://policies.yahoo.com/us/en/yahoo/terms/product-atos/apiforydn/index.htm) That is a high level of authority... not us.

kgonzago commented 6 years ago

@karlterrey Can we confirm if we can use Yahoo Weather in this widget?

karlterrey commented 6 years ago

Esri Inc. would be excluded from the umbrella reserved for non-profits and individuals. We can't use it. We are a commercial use.