chore: sync from fn-registry agent
This commit is contained in:
@@ -0,0 +1,33 @@
|
||||
#pragma once
|
||||
|
||||
#include <cstdint>
|
||||
#include <string>
|
||||
|
||||
namespace navegator {
|
||||
|
||||
struct LaunchOpts {
|
||||
std::string chrome_path; // por defecto auto-detect
|
||||
int port = 19222; // remote-debugging-port
|
||||
std::string user_data_dir; // ruta Windows (C:\...) — obligatorio para aislar
|
||||
bool headless = false;
|
||||
std::string start_url; // URL inicial; vacio = about:blank
|
||||
};
|
||||
|
||||
struct LaunchResult {
|
||||
bool ok = false;
|
||||
uint32_t pid = 0;
|
||||
std::string error; // descripcion humana si ok=false
|
||||
};
|
||||
|
||||
// Lanza chrome.exe con los flags de remote debugging que YA descubrimos
|
||||
// que funcionan en Chrome 147 (ver projects/navegator/notes/2026-05-09-...):
|
||||
// --remote-debugging-port=<port>
|
||||
// --remote-allow-origins=* [obligatorio Chrome 111+]
|
||||
// --user-data-dir=<dir>
|
||||
// --no-first-run --no-default-browser-check
|
||||
// + flags si headless.
|
||||
//
|
||||
// NO usa --remote-debugging-address=0.0.0.0 (rompe bind en Chrome 147).
|
||||
LaunchResult launch_chrome(const LaunchOpts& opts);
|
||||
|
||||
} // namespace navegator
|
||||
Reference in New Issue
Block a user