Bug 389581 - "Custom" maps not working if "?" character is within URL Path
Summary: "Custom" maps not working if "?" character is within URL Path
Status: RESOLVED WORKSFORME
Alias: None
Product: marble
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: Other Microsoft Windows
: NOR normal
Target Milestone: ---
Assignee: marble-bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-01-29 03:00 UTC by Shane Hill
Modified: 2022-12-15 05:15 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Shane Hill 2018-01-29 03:00:19 UTC
I was trying to create my own map server for marble and could not get it working. I tried the Google maps at https://github.com/freayd/marble-maps/ and had the same issue. The Google Maps has a URL definition of:

<downloadUrl protocol="http" host="mt1.google.com" path="/vt?lyrs=m&amp;x={x}&amp;y={y}&amp;z={zoomLevel}" />

I placed some print statements within ServerLayout.cpp at function CustomServerLayout::downloadUrl() and the above definition returns an example of:

http://mt3.google.com/vt%3Flyrs=m&x=1&y=5&z=3

It seems that the "?" character has been replaced with "%3F" (a correct conversion, but using this link does not work. Replacing the "%3F" with the "?" character seems to fix the problem. I added the code:


urlStr.replace( "%3F", "?");

So... should the substitution of "?" to "%3F"be done at this level in the code? Should another character be used within the <downloadUrl> XML syntax? Any thoughts? Thanks.

Shane
Comment 1 Shane Hill 2018-01-29 03:03:54 UTC
I'm currently using Marble 17.12, but this issue seems to go back to at least 15.04. It may be a change to Qt that has triggered this.
Comment 2 Shane Hill 2018-01-31 05:23:49 UTC
Okay, I think I have this solved. I forgot that "downloadUrl" has an "query" attribute. So changing the download definition to the following fixes the issue:

<downloadUrl protocol="http" host="mt1.google.com" path="/vt" query="lyrs=m&amp;x={x}&amp;y={y}&amp;z={zoomLevel}" />

I'll send an email to the marble google maps github team to get this updated. This
ticket can/should be closed.
Comment 3 Justin Zobel 2022-11-15 22:58:54 UTC
Thank you for reporting this issue in KDE software. As it has been a while since this issue was reported, can we please ask you to see if you can reproduce the issue with a recent software version?

If you can reproduce the issue, please change the status to "REPORTED" when replying. Thank you!
Comment 4 Bug Janitor Service 2022-11-30 05:15:01 UTC
Dear Bug Submitter,

This bug has been in NEEDSINFO status with no change for at least
15 days. Please provide the requested information as soon as
possible and set the bug status as REPORTED. Due to regular bug
tracker maintenance, if the bug is still in NEEDSINFO status with
no change in 30 days the bug will be closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

If you have already provided the requested information, please
mark the bug as REPORTED so that the KDE team knows that the bug is
ready to be confirmed.

Thank you for helping us make KDE software even better for everyone!
Comment 5 Bug Janitor Service 2022-12-15 05:15:07 UTC
This bug has been in NEEDSINFO status with no change for at least
30 days. The bug is now closed as RESOLVED > WORKSFORME
due to lack of needed information.

For more information about our bug triaging procedures please read the
wiki located here:
https://community.kde.org/Guidelines_and_HOWTOs/Bug_triaging

Thank you for helping us make KDE software even better for everyone!