Skip to content

Ensure Chrome browser usage only for GET requests#197

Merged
otsch merged 5 commits intomainfrom
bugfix/browser-usage-and-non-get-requests
Mar 8, 2025
Merged

Ensure Chrome browser usage only for GET requests#197
otsch merged 5 commits intomainfrom
bugfix/browser-usage-and-non-get-requests

Conversation

@otsch
Copy link
Member

@otsch otsch commented Mar 8, 2025

Since the Chrome browser can only execute GET requests:

  • The loader now automatically switches to the HTTP client for POST, PUT, PATCH, and DELETE requests, logging a warning.
  • A warning is logged when attempting to use 'Post Browser Navigate Hooks' with these request types.
  • Consequently, the useBrowser() method, introduced in v3.4.0, is also limited to GET requests.

otsch added 5 commits March 6, 2025 23:33
Added a screenshot browser action. Therefor extended the
`RespondedRequest` class, so it also transports the paths of the
screenshots on the filesystem.
Also added two new methods to the `Http` steps allowing to modify the
loader, only for one particular step in the chain. They can be used to
skip the configured cache or to switch to use the (headless) Chrome
browser.
Since the Chrome browser can only execute GET requests:
- The loader now automatically switches to the HTTP client for POST,
  PUT, PATCH, and DELETE requests, logging a warning.
- A warning is logged when attempting to use 'Post Browser Navigate
  Hooks' with these request types.
- Consequently, the `useBrowser()` method, introduced in v3.4.0, is also
  limited to GET requests.
@otsch otsch merged commit e08b494 into main Mar 8, 2025
6 checks passed
@otsch otsch deleted the bugfix/browser-usage-and-non-get-requests branch March 8, 2025 11:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant