You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Jun 11, 2024. It is now read-only.
log.warn("No content type specified in response from {}. Content will be treated as {}", originalRequest.getUri(), BrowserUpHttpUtil.UNKNOWN_CONTENT_TYPE);
This is all fine and dandy - but the log is a warning and is logged even when the response should not have any content, or may not have content and does not (and hence it would not have any content type either).
Various HTTP responses like some of the 3xx or even the 201/202 are not expected to contain content.
Create a Proxy with HAR captruing like the following:
proxy = newBrowserUpProxyServer();
// enable more detailed HAR capture, if desired (see CaptureType for the complete list)proxy.enableHarCaptureTypes(
CaptureType.REQUEST_HEADERS,
CaptureType.REQUEST_CONTENT,
CaptureType.RESPONSE_HEADERS,
CaptureType.RESPONSE_CONTENT
);
proxy.setTrustAllServers(true);
proxy.start();
go to any page that returns no content (like a redirect)
See error
Expected behavior
The error is only logged if the page also has content.
there is no log (info / warning etc) if the response legitimately has no content. (this could be if the response is a set of specific codes)
Screenshots
If applicable, add screenshots to help explain your problem.
The response to the above request is
Please complete the following information:
OS: windows.
Browser firefox from selenium/standalone-firefox-debug:3.141.59
Version
version of browseup 2.1.2
Additional context
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered:
Describe the bug
When a response to a request comes back from a server without any content type header the proxy creates a log entry
browserup-proxy/browserup-proxy-core/src/main/java/com/browserup/bup/filters/HarCaptureFilter.java
Lines 484 to 488 in 26714e2
This is all fine and dandy - but the log is a warning and is logged even when the response should not have any content, or may not have content and does not (and hence it would not have any content type either).
Various HTTP responses like some of the 3xx or even the 201/202 are not expected to contain content.
This can be seen with the Jenkins ATH https://github.com/jenkinsci/acceptance-test-harness.
To Reproduce
Steps to reproduce the behavior:
Expected behavior
The error is only logged if the page also has content.
there is no log (info / warning etc) if the response legitimately has no content. (this could be if the response is a set of specific codes)
Screenshots
If applicable, add screenshots to help explain your problem.
The response to the above request is
Please complete the following information:
Additional context
Add any other context about the problem here.
The text was updated successfully, but these errors were encountered: