Red Hat Bugzilla – Bug 1371550
Switch to new weather forecasting service
Last modified: 2016-11-03 21:52:09 EDT
In RHEL 7.3, gnome-weather's weather forecasting currently does not work. This is caused by weather.noaa.gov service shutting down unexpectedly. We would need to backport a simple patch to libgweather to make this work again: https://git.gnome.org/browse/libgweather/commit/?id=283afc2d23355def1c1bab70a641f40cea52ba7f
The same problem with weather-metar.c in libgweather-2.28.0-5.el6.src.rpm - but RH6 is using the broken http://weather.noaa.gov/cgi-bin/mgetmetar.pl - not the broken http://weather.noaa.gov/mgetmetar.php from RH7. We need a modified patch. RH6: msg = soup_form_request_new ( "GET", "http://weather.noaa.gov/cgi-bin/mgetmetar.pl", "cccc", loc->code, NULL); From RH7 patch: msg = soup_form_request_new ( - "GET", "http://weather.noaa.gov/mgetmetar.php", - "cccc", loc->code, Bug 1370961 - "noaa.gov change broke gnome-weather entirely - fix committed upstream" shoud be a duplicate? NOAA says on http://www.nws.noaa.gov/om/notification/scn16-16wngccb.htm : "The NWS will eliminate the web service found at the following address effective August 3, 2016".
* Feature: The METAR weather service that is used by the gnome-weather application was switched from the one provided by NOAA to www.aviationweather.gov. * Reason: NOAA stopped providing the METAR service. * Result: gnome-weather can show weather information again.
EL6: --- libgweather-2.28.0/libgweather/weather-metar.c 2009-06-04 17:41:13.000000000 +0300 +++ libgweather-2.28.0./libgweather/weather-metar.c 2016-10-16 22:08:03.476670678 +0300 @@ -522,7 +522,7 @@ metar = g_strdup (p); success = metar_parse (metar, info); g_free (metar); - } else if (!strstr (msg->response_body->data, "National Weather Service")) { + } else if (!strstr (msg->response_body->data, "AVIATION WEATHER CENTER")) { /* The response doesn't even seem to have come from NWS... * most likely it is a wifi hotspot login page. Call that a * network error. @@ -550,8 +550,8 @@ } msg = soup_form_request_new ( - "GET", "http://weather.noaa.gov/cgi-bin/mgetmetar.pl", - "cccc", loc->code, + "GET", "http://aviationweather.gov/metar/data", + "ids", loc->code, NULL); soup_session_queue_message (info->session, msg, metar_finish, info);
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://rhn.redhat.com/errata/RHEA-2016-2263.html