﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	resolution	keywords	cc
11572	Arcgis REST projection and bbox issues	A_Pirard	wiktorn	"==== What steps will reproduce the problem?

This layer definition
wms[21]:http://geoservices.wallonie.be/arcgis/rest/services/TOPOGRAPHIE/PICC/MapServer/export?&f=image&format=png8&dpi=90&transparent=True&SRS={proj}&bboxSR=3857&imageSR=3857&bbox={bbox}&size={width},{height}&layers=hide:11,22

produces pictures like this  (https://www.osm.org/#map=16/50.54496/5.60156):
http://geoservices.wallonie.be/arcgis/rest/services/TOPOGRAPHIE/PICC/MapServer/export?&f=image&format=png8&dpi=90&transparent=True&SRS=EPSG:3857&bboxSR=3857&imageSR=3857&bbox=622922.4272812,6541196.9170170,623945.2884098,6542219.7781455&size=500,500&layers=hide:11,22

Note: &SRS= is only a dummy to show which SRS JOSM chose for the request, EPSG:3857, *SR= are set accordingly.

With the following similar definition, however (other server)
wms[21]:http://geoservices.wallonie.be/arcgis/rest/services/IGN/LIMITES_ADMINISTRATIVES/MapServer/export?&f=image&format=png8&dpi=90&transparent=True&SRS={proj}&bboxSR=4326&imageSR=4326&bbox={bbox}&size={width},{height}&layers=show:0,2,3

JOSM chooses proj=EPSG:4326
and produces the attached bad image: middle line boundary shrinked and repeated.
Furthermore, if I force the request to use EPSG:3857 as folows:
wms[21]:http://geoservices.wallonie.be/arcgis/rest/services/IGN/LIMITES_ADMINISTRATIVES/MapServer/export?&f=image&format=png8&dpi=90&transparent=True&SRS=EPSG:3857&bboxSR=3857&imageSR=3857&bbox={bbox}&size={width},{height}&layers=show:0,2,3
JOSM insists on using a 4326 bbox:
INFO: Grabbing WMS http://geoservices.wallonie.be/arcgis/rest/services/IGN/LIMITES_ADMINISTRATIVES/MapServer/export?&f=image&format=png8&dpi=90&transparent=True&SRS=EPSG:3857&bboxSR=3857&imageSR=3857&bbox=5.6035138,50.5428163,5.6092084,50.5464351&size=500,500&layers=show:0,2,3
(and there is no image)

The server seems to work correctly.

This is is a correct picture:
http://geoservices.wallonie.be/arcgis/rest/services/IGN/LIMITES_ADMINISTRATIVES/MapServer/export?dpi=96&transparent=true&format=png32&bbox=623143.0003956892%2C6540870.250346748%2C624204.7584916232%2C6541465.0259730425&bboxSR=102100&imageSR=102100&size=889%2C498&f=image

And  I get a correct display when using WMS served by a Mapproxy configuration:
wms:http://localhost:8080/service?&TRANSPARENT=TRUE&FORMAT=image/png8&VERSION=1.1.1&SERVICE=WMS&REQUEST=GetMap&LAYERS=SPW_boundary&STYLES=&SRS={proj}&WIDTH={width}&HEIGHT={height}&BBOX={bbox}

I attached the contents of the cache + details for both tests.

What's going on behind that?
It looks like the vertical ratio is incorrect, but what about choosing the wrong {proj}?
Am I goofing somehow?
Any workaround or fix?

Thanks

{{{
Repository Root: http://josm.openstreetmap.de/svn
Build-Date: 2015-05-08 01:31:23
Last Changed Author: stoecker
Revision: 8339
Repository UUID: 0c6e7542-c601-0410-84e7-c038aed88b3b
Relative URL: ^/trunk
URL: http://josm.openstreetmap.de/svn/trunk
Last Changed Date: 2015-05-07 17:30:43 +0200 (Thu, 07 May 2015)
Last Changed Rev: 8339

Identification: JOSM/1.5 (8339 en) Linux Mint 13 Maya
Memory Usage: 254 MB / 1267 MB (138 MB allocated, but free)
Java version: 1.7.0_65, Oracle Corporation, OpenJDK 64-Bit Server VM
Java package: openjdk-7-jre:amd64-7u71-2.5.3-0ubuntu0.12.04.1
VM arguments: [-Djosm.restart=true, -Djava.net.useSystemProxies=true]

Plugins:
- AddrInterpolation (31241)
- FixAddresses (31241)
- OpeningHoursEditor (31241)
- PicLayer (31241)
- RoadSigns (31241)
- areaselector
- download_along (31241)
- editgpx (31241)
- geotools (31126)
- importvec (31241)
- jts (31126)
- log4j (31231)
- mirrored_download (31241)
- opendata (31241)
- osmarender (31241)
- reltoolbox (31241)
- reverter (31241)
- scripting (30710)
- tagging-preset-tester (31241)
- turnrestrictions (31241)
- utilsplugin2 (31241)
- waydownloader (31241)

Last errors/warnings:
- E: java.io.FileNotFoundException: no/home/p/.josm/Traffic rules BE.xml (No such file or directory)
- E: no/home/p/.josm/Traffic rules BE.xml
- W: Detected deprecated 'canvas{background-color}' in '/home/p/.josm/Papou.css' which will be removed shortly. Use 'fill-color' instead.
- W: Detected deprecated 'canvas{background-color}' in '/home/p/.josm/cadastre.css' which will be removed shortly. Use 'fill-color' instead.
- E: org.openstreetmap.josm.plugins.PluginException: An error occurred in plugin areaselector. Cause: java.lang.reflect.InvocationTargetException. Cause: java.lang.NoClassDefFoundError: org/apache/log4j/ConsoleAppender. Cause: java.lang.ClassNotFoundException: org.apache.log4j.ConsoleAppender
}}}
"	defect	closed	normal	15.08	Core imagery		fixed	WMS	
