[MapProxy] URL with @ symbol in mapproxy.yaml

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

[MapProxy] URL with @ symbol in mapproxy.yaml

Ben Field
When defining a tile source in mapproxy.yaml that has an @ in the URL parameter, it's effectively hosing everything preceding it.

For example, if the URL is defined like this:

url: <a href="http://localhost/tiles/%(tms_path)s/whatever@2x.png">http://localhost/tiles/%(tms_path)s/whatever@...

MapProxy will generate the following error:

No response from URL "http://2x.png": Name or service not known

I tried escaping it, but that didn't work.  Is this a bug or is there some way to use the @ symbol in the URL?  This issue didn't exist in MapProxy v1.9.0.





_______________________________________________
MapProxy mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/mapproxy
Reply | Threaded
Open this post in threaded view
|

Re: [MapProxy] URL with @ symbol in mapproxy.yaml

Oliver Tonnhofer-3
Hi,

@ is the separator for username and password.

Can you try with <a href="http://@localhost/tiles/%(tms_path)s/whatever@2x.png">http://@localhost/tiles/%(tms_path)s/whatever@... or <a href="http://:@localhost/tiles/%(tms_path)s/whatever@2x.png">http://:@localhost/tiles/%(tms_path)s/whatever@...?

Regards,
Oliver

--
Oliver Tonnhofer  | Omniscale GmbH & Co KG  | https://omniscale.com
OpenStreetMap WMS and tile services         | https://maps.omniscale.com







> On 10. Jan 2018, at 02:12, Ben Field <[hidden email]> wrote:
>
> When defining a tile source in mapproxy.yaml that has an @ in the URL parameter, it's effectively hosing everything preceding it.
>
> For example, if the URL is defined like this:
>
> url: <a href="http://localhost/tiles/%(tms_path)s/whatever@2x.png">http://localhost/tiles/%(tms_path)s/whatever@...
>
> MapProxy will generate the following error:
>
> No response from URL "http://2x.png": Name or service not known
>
> I tried escaping it, but that didn't work.  Is this a bug or is there some way to use the @ symbol in the URL?  This issue didn't exist in MapProxy v1.9.0.
>
>
>
>
> _______________________________________________
> MapProxy mailing list
> [hidden email]
> https://lists.osgeo.org/mailman/listinfo/mapproxy

_______________________________________________
MapProxy mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/mapproxy
Reply | Threaded
Open this post in threaded view
|

Re: [MapProxy] URL with @ symbol in mapproxy.yaml

Ben Field
I still get the same result with both of those.  It's apparently using the second @ symbol for the separator.



On Tue, Jan 9, 2018 at 11:18 PM, Oliver Tonnhofer <[hidden email]> wrote:
Hi,

@ is the separator for username and password.

Can you try with http://@localhost/tiles/%(tms_path)s/[hidden email] or http://:@localhost/tiles/%(tms_path)s/[hidden email]?

Regards,
Oliver

--
Oliver Tonnhofer  | Omniscale GmbH & Co KG  | https://omniscale.com
OpenStreetMap WMS and tile services         | https://maps.omniscale.com







> On 10. Jan 2018, at 02:12, Ben Field <[hidden email]> wrote:
>
> When defining a tile source in mapproxy.yaml that has an @ in the URL parameter, it's effectively hosing everything preceding it.
>
> For example, if the URL is defined like this:
>
> url: <a href="http://localhost/tiles/%(tms_path)s/whatever@2x.png" rel="noreferrer" target="_blank">http://localhost/tiles/%(tms_path)s/whatever@...
>
> MapProxy will generate the following error:
>
> No response from URL "http://2x.png": Name or service not known
>
> I tried escaping it, but that didn't work.  Is this a bug or is there some way to use the @ symbol in the URL?  This issue didn't exist in MapProxy v1.9.0.
>
>
>
>
> _______________________________________________
> MapProxy mailing list
> [hidden email]
> https://lists.osgeo.org/mailman/listinfo/mapproxy



_______________________________________________
MapProxy mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/mapproxy
dr
Reply | Threaded
Open this post in threaded view
|

Re: [MapProxy] URL with @ symbol in mapproxy.yaml

dr
In reply to this post by Ben Field
Hello,

Could you try such URL format:
<a href="http://localhost/tiles/%(tms_path)s/whatever%402x.png">http://localhost/tiles/%(tms_path)s/whatever%402x.png?

On Wed, Jan 10, 2018 at 8:12 AM, Ben Field <[hidden email]> wrote:

> When defining a tile source in mapproxy.yaml that has an @ in the URL
> parameter, it's effectively hosing everything preceding it.
>
> For example, if the URL is defined like this:
>
> url: <a href="http://localhost/tiles/%(tms_path)s/whatever@2x.png">http://localhost/tiles/%(tms_path)s/whatever@...
>
>
> MapProxy will generate the following error:
>
> No response from URL "http://2x.png": Name or service not known
>
>
> I tried escaping it, but that didn't work.  Is this a bug or is there some
> way to use the @ symbol in the URL?  This issue didn't exist in MapProxy
> v1.9.0.
>
>
>
>
>
> _______________________________________________
> MapProxy mailing list
> [hidden email]
> https://lists.osgeo.org/mailman/listinfo/mapproxy
_______________________________________________
MapProxy mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/mapproxy
Reply | Threaded
Open this post in threaded view
|

Re: [MapProxy] URL with @ symbol in mapproxy.yaml

Ben Field
That results in an internal error:  "TypeError: not enough arguments for format string".

But that made me try this:
<a href="http://localhost/tiles/%(tms_path)s/whatever%%402x.png">http://localhost/tiles/%(tms_path)s/whatever%%402x.png

And that works.  Thanks for the assistance.



On Thu, Jan 11, 2018 at 12:17 PM, Denis Rykov <[hidden email]> wrote:
Hello,

Could you try such URL format:
<a href="http://localhost/tiles/%(tms_path)s/whatever%402x.png" rel="noreferrer" target="_blank">http://localhost/tiles/%(tms_path)s/whatever%402x.png?

On Wed, Jan 10, 2018 at 8:12 AM, Ben Field <[hidden email]> wrote:
> When defining a tile source in mapproxy.yaml that has an @ in the URL
> parameter, it's effectively hosing everything preceding it.
>
> For example, if the URL is defined like this:
>
> url: <a href="http://localhost/tiles/%(tms_path)s/whatever@2x.png" rel="noreferrer" target="_blank">http://localhost/tiles/%(tms_path)s/whatever@...
>
>
> MapProxy will generate the following error:
>
> No response from URL "http://2x.png": Name or service not known
>
>
> I tried escaping it, but that didn't work.  Is this a bug or is there some
> way to use the @ symbol in the URL?  This issue didn't exist in MapProxy
> v1.9.0.
>
>
>
>
>
> _______________________________________________
> MapProxy mailing list
> [hidden email]
> https://lists.osgeo.org/mailman/listinfo/mapproxy


_______________________________________________
MapProxy mailing list
[hidden email]
https://lists.osgeo.org/mailman/listinfo/mapproxy