@intuned/runtime-dev 1.3.22-dev.5 → 1.3.22-dev.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -7,7 +7,7 @@ export interface Proxy {
|
|
|
7
7
|
}
|
|
8
8
|
/**
|
|
9
9
|
* Get ignore_http_errors setting from CLI option or environment variable.
|
|
10
|
-
* Priority: cliOption > environment variable > false
|
|
10
|
+
* Priority: cliOption(true only) > environment variable > false
|
|
11
11
|
*/
|
|
12
12
|
export declare function getIgnoreHttpErrorsFromConfig(cliOption?: boolean): Promise<boolean>;
|
|
13
13
|
export type LaunchBrowserResult = {
|
|
@@ -50,22 +50,17 @@ async function createUserDirWithPreferences() {
|
|
|
50
50
|
return userDir;
|
|
51
51
|
}
|
|
52
52
|
async function getIgnoreHttpErrorsFromConfig(cliOption) {
|
|
53
|
-
if (cliOption
|
|
54
|
-
|
|
55
|
-
return cliOption;
|
|
53
|
+
if (cliOption === true) {
|
|
54
|
+
return true;
|
|
56
55
|
}
|
|
57
56
|
const envValue = process.env.INTUNED_PLAYWRIGHT_CONTEXT_IGNORE_HTTP_ERRORS;
|
|
58
57
|
if (envValue !== undefined) {
|
|
59
|
-
|
|
60
|
-
console.log(`[ignore_http_errors] using env value: ${parsedValue}`);
|
|
61
|
-
return parsedValue;
|
|
58
|
+
return envValue.toLowerCase() === "true" || envValue === "1" || envValue.toLowerCase() === "yes";
|
|
62
59
|
}
|
|
63
|
-
console.log("[ignore_http_errors] env not set, using default: false");
|
|
64
60
|
return false;
|
|
65
61
|
}
|
|
66
62
|
async function launchChromium(options) {
|
|
67
63
|
if ("cdpAddress" in options) {
|
|
68
|
-
console.log(`[ignore_http_errors] launchChromium (cdp) received value: ${options.ignoreHttpErrors}`);
|
|
69
64
|
if (await (0, _extensionsHelpers.isIntunedExtensionEnabled)()) {
|
|
70
65
|
await (0, _intunedExtensionServer.setupIntunedExtensionServer)();
|
|
71
66
|
}
|
|
@@ -112,7 +107,6 @@ async function launchChromium(options) {
|
|
|
112
107
|
executablePath
|
|
113
108
|
} = options;
|
|
114
109
|
const ignoreHttpErrors = await getIgnoreHttpErrorsFromConfig(ignoreHttpErrorsParam);
|
|
115
|
-
console.log(`[ignore_http_errors] launchChromium resolved value: ${ignoreHttpErrors}`);
|
|
116
110
|
const defaultArgsToIgnore = ["--disable-extensions", "--disable-component-extensions-with-background-pages", "--disable-background-networking", "--disable-backgrounding-occluded-windows", "--disable-background-timer-throttling"];
|
|
117
111
|
const extraArgs = [];
|
|
118
112
|
const macKeychainBypassArgs = getMacKeychainBypassArgs();
|