Skip to content

Commit 9cd6607

Browse files
author
GitLab CI
committed
fix: use PUT for /json/new (Chrome 145+ requires it)
1 parent b824698 commit 9cd6607

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

lib/src/bridge/cdp_driver.dart

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,8 @@ class CdpDriver implements AppDriver {
106106
try {
107107
final client = HttpClient()..connectionTimeout = const Duration(seconds: 2);
108108
final encodedUrl = Uri.encodeComponent(_url);
109-
final request = await client.getUrl(Uri.parse('http://127.0.0.1:$_port/json/new?$encodedUrl'));
109+
// Chrome 145+ requires PUT for /json/new
110+
final request = await client.openUrl('PUT', Uri.parse('http://127.0.0.1:$_port/json/new?$encodedUrl'));
110111
final response = await request.close();
111112
final body = await response.transform(utf8.decoder).join();
112113
client.close();

0 commit comments

Comments
 (0)