The great Viking application for simplified #GPX editing without having to install a whole #GIS suite recently broke due to #OpenStreetMap redirecting http traffic to https.
viking [Warning]): curl_download_uri: http response: 301 for uri http://tile.openstreetmap.org/a/b/c.png
viking [Warning]): Download error: /home/username/.cache/viking/OSM-Mapnik/a/b/c.png
There is an issue for that already.
Since #Viking is pretty old and didn’t get a new release in 5 years it is unlikely that this will be fixed anytime soon.
Fortunately Viking respects /usr/local/ configurations, so users can fix the #OSM data source #XML on their own.
Just place a file in /usr/local/share/viking/maps.xml with the following content:
<objects>
<object class="VikSlippyMapSource">
<property name="name">OSM-Mapnik-Fixed</property>
<property name="label">OpenStreetMap (Mapnik), fixed</property>
<property name="hostname">tile.openstreetmap.org</property>
<property name="url">https://tile.openstreetmap.org/%d/%d/%d.png</property>
<property name="id">13</property>
<property name="zoom-min">0</property>
<property name="zoom-max">19</property>
<property name="copyright"> OpenStreetMap contributors</property>
<property name="license">CC-BY-SA</property>
<property name="license-url">http://www.openstreetmap.org/copyright</property>
<property name="use-etag">TRUE</property>
<property name="follow-location">2</property>
</object>
</objects>
The important things are the properties url and id. The built-in configuration uses /%d/%d/%d.png as URL, which means, the tiles URL is constructed using the hostname and http.
The updated version here uses the full URL and https, which means, this URL is used as it is and not being constructed.
The id value being 13 here, because this is the ID of the built-in OSM configuration. The same ID means, that the built-in is overridden.
name is used for the cache directory and label is purely informational. The rest was copied from the built-in configuration.
With this configuration Viking now loads the OSM tiles again. The other map data source configurations are not affected.