After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 763175 - api.yr.no is deprecated, patch for using api.met.no instead
api.yr.no is deprecated, patch for using api.met.no instead
Status: RESOLVED FIXED
Product: libgweather
Classification: Core
Component: general
unspecified
Other All
: Normal major
: future
Assigned To: libgweather-maint
libgweather-maint
Depends on:
Blocks:
 
 
Reported: 2016-03-06 14:16 UTC by Daniel Aleksandersen
Modified: 2016-03-15 04:12 UTC
See Also:
GNOME target: ---
GNOME version: Unversioned Enhancement


Attachments
0001-switch-to-https-api-met-no.patch (2.75 KB, patch)
2016-03-06 14:16 UTC, Daniel Aleksandersen
committed Details | Review

Description Daniel Aleksandersen 2016-03-06 14:16:32 UTC
Created attachment 323198 [details] [review]
0001-switch-to-https-api-met-no.patch

http://api.yr.no is deprecated
https://api.yr.no/ is now preferred

See announcements,

http://lists.met.no/pipermail/api-users/2016-March/000017.html
http://lists.met.no/pipermail/api-users/2016-March/000019.html

Same license and restrictions as before. Attribution changed to attribute the Norwegian Meteorological Institute’s own website.
Comment 1 Michael Catanzaro 2016-03-06 15:44:58 UTC
Review of attachment 323198 [details] [review]:

::: libgweather/weather-yrno.c
@@ +422,2 @@
     else
+	return g_strdup_printf("http://www.yr.no/place/%s/%s/%s", country, city_name, append);

Why is this still using yr.no, is it not available from api.met.no? And why not https? In general, we should not ever be using plain http in applications.
Comment 2 Daniel Aleksandersen 2016-03-06 16:17:38 UTC
No, that URL is for their website at yr.no which is still the end-user endpoint and is not available under HTTPS. This change only applies to their API. The patch is correct as-is.

Increasing priority as the old API endpoint will be shut down in just six months.
https://www.slightfuture.com/devel/met-norway-api-endpoints
Comment 3 Giovanni Campagna 2016-03-06 19:00:28 UTC
Review of attachment 323198 [details] [review]:

Patch looks good to me, do you need me to commit it?
Comment 4 Daniel Aleksandersen 2016-03-06 19:16:57 UTC
Giovanni Campagna, yes please. I don’t have commit access.
Comment 5 Giovanni Campagna 2016-03-15 04:11:54 UTC
This problem has been fixed in the unstable development version. The fix will be available in the next major software release. You may need to upgrade your Linux distribution to obtain that newer version.