Safari developer tools with simulator always shows "null" as HTTP method in place of GET, POST, PUT, etc

27 Views Asked by At

I've been experiencing an issue with Safari's developer tools for a few months. When I inspect network requests for any web page, the tool displays "null /path/website" where it should normally show e.g. "POST /path/website".

The requests themselves are being dispatched correctly, so this seems to be an issue isolated to the developer tools. However, the impact is significant as I cannot view the payload of POST requests. This limitation is hindering my development work.

Below are some screenshots illustrating the issue, featuring both a company internal application and a public website:

safari_screen_1

safari_screen_2

When I right click and select "copy as curl" it copies the following:

curl 'https://api.viafoura.co/v2/www.repubblica.it/bootstrap/v2'
-X 'null'
-H 'Content-Type: text/plain;charset=UTF-8'
-H 'Accept: /'
-H 'Sec-Fetch-Site: cross-site'
-H 'Accept-Language: it-IT,it;q=0.9'
-H 'Accept-Encoding: gzip, deflate, br'
-H 'Sec-Fetch-Mode: cors'
-H 'Host: api.viafoura.co'
-H 'Origin: https://www.repubblica.it'
-H 'User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/16.4 Safari/605.1.15'
-H 'Referer: https://www.repubblica.it/'
-H 'Content-Length: 32'
-H 'Connection: keep-alive'
-H 'Sec-Fetch-Dest: empty'

Additionally, I've taken several steps to resolve this issue, including clearing the cache, browsing history, resetting all Safari settings, rebooting my system, and deleting the ~/Library/Safari folder. I've also followed various other recommendations found online, but none have led to any improvement. The problem only occurs when XHR requests are made in the simulator, whether in Safari on the simulator or within an app running on the simulator. This is becoming a significant impediment to my work, and since there are no alternative solutions available, I am eager to find a fix.

I am using Safari 16.1 (18614.2.9.1.12) on MacOS 13.0 (22A8380)

Thank you

0

There are 0 best solutions below