TransWikia.com

Easy way to see the requests QGIS makes to a remote server?

Geographic Information Systems Asked on June 19, 2021

I’m attempting to debug an issue with a remote ArcGis Server’s WMTS as seen from GeoServer. I can see the requests GeoTools is making (because they throw an error and get logged). However the service works in QGIS (3.0 if that makes a difference) and I would like to know what the difference in the requests is.

I know I can set up wireshark or some such but I hoped there was a way of getting QGIS to log the URLs being requested directly via a flag or setting?.

3 Answers

For QGIS 3.14 Pi and up

Just hit F12 and you will get the network logger panel (the QGIS Network Logger plugin is now integrated into QGIS core).

For QGIS 3.6 up to 3.14 Pi

For QGIS 3.6 and more recent versions, there is a useful plugin called QGIS Network Logger, developed by Richard Duivenvoorde.

It is much easier to check the requests sent out by QGIS (sent via the QgsNetworkAccessManager).

enter image description here

Correct answer by jgrocha on June 19, 2021

It seems there is no easy way to do this in QGis, so I solved it by adding a simple proxy, Python Logging Proxy which "does what it says on the can".

I modified the file LoggingProxyHTTPHandler.py to comment out line 105

print response.content

since I didn't need to see the "contents" of the images being sent back. Then to run the proxy all you do is

python ./proxy.py

And in QGis go to Settigns->Options->Network and turn on the use proxy for web access and fill in localhost and 8000 for the Host and Port.

enter image description here Then every time QGis requests a WMTS (or other web image) you will see the request and the response in the terminal.

Answered by Ian Turton on June 19, 2021

Just want to share two other proxies I used with @Ian's approach on Linux:

  1. squid: text logs, should be sufficient for general use

    https://help.ubuntu.com/lts/serverguide/squid.html.en

    default port: 3128

  2. fiddler: GUI proxy, supports tile previews

    https://www.telerik.com/blogs/fiddler-for-linux-beta-is-here

    default port: 8888

Answered by prusswan on June 19, 2021

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP