appium 3.2.2 → 3.3.1
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.
- package/build/lib/appium.d.ts +147 -205
- package/build/lib/appium.d.ts.map +1 -1
- package/build/lib/appium.js +169 -282
- package/build/lib/appium.js.map +1 -1
- package/build/lib/bidi-commands.d.ts.map +1 -1
- package/build/lib/bidi-commands.js +11 -11
- package/build/lib/bidi-commands.js.map +1 -1
- package/build/lib/bootstrap/appium-initializer.d.ts +21 -0
- package/build/lib/bootstrap/appium-initializer.d.ts.map +1 -0
- package/build/lib/bootstrap/appium-initializer.js +146 -0
- package/build/lib/bootstrap/appium-initializer.js.map +1 -0
- package/build/lib/bootstrap/appium-main-runner.d.ts +22 -0
- package/build/lib/bootstrap/appium-main-runner.d.ts.map +1 -0
- package/build/lib/bootstrap/appium-main-runner.js +109 -0
- package/build/lib/bootstrap/appium-main-runner.js.map +1 -0
- package/build/lib/bootstrap/config-file.d.ts +37 -0
- package/build/lib/bootstrap/config-file.d.ts.map +1 -0
- package/build/lib/{config-file.js → bootstrap/config-file.js} +62 -138
- package/build/lib/bootstrap/config-file.js.map +1 -0
- package/build/lib/bootstrap/grid-v3-register.d.ts +20 -0
- package/build/lib/bootstrap/grid-v3-register.d.ts.map +1 -0
- package/build/lib/bootstrap/grid-v3-register.js +185 -0
- package/build/lib/bootstrap/grid-v3-register.js.map +1 -0
- package/build/lib/bootstrap/init-types.d.ts +16 -0
- package/build/lib/bootstrap/init-types.d.ts.map +1 -0
- package/build/lib/bootstrap/init-types.js +3 -0
- package/build/lib/bootstrap/init-types.js.map +1 -0
- package/build/lib/bootstrap/main-helpers.d.ts +55 -0
- package/build/lib/bootstrap/main-helpers.d.ts.map +1 -0
- package/build/lib/bootstrap/main-helpers.js +187 -0
- package/build/lib/bootstrap/main-helpers.js.map +1 -0
- package/build/lib/bootstrap/node-helpers.d.ts +32 -0
- package/build/lib/bootstrap/node-helpers.d.ts.map +1 -0
- package/build/lib/bootstrap/node-helpers.js +201 -0
- package/build/lib/bootstrap/node-helpers.js.map +1 -0
- package/build/lib/bootstrap/startup-config.d.ts +22 -0
- package/build/lib/bootstrap/startup-config.d.ts.map +1 -0
- package/build/lib/bootstrap/startup-config.js +111 -0
- package/build/lib/bootstrap/startup-config.js.map +1 -0
- package/build/lib/cli/args.d.ts +16 -12
- package/build/lib/cli/args.d.ts.map +1 -1
- package/build/lib/cli/args.js +20 -40
- package/build/lib/cli/args.js.map +1 -1
- package/build/lib/cli/driver-command.d.ts +51 -93
- package/build/lib/cli/driver-command.d.ts.map +1 -1
- package/build/lib/cli/driver-command.js +11 -66
- package/build/lib/cli/driver-command.js.map +1 -1
- package/build/lib/cli/extension-command.d.ts +173 -377
- package/build/lib/cli/extension-command.d.ts.map +1 -1
- package/build/lib/cli/extension-command.js +387 -656
- package/build/lib/cli/extension-command.js.map +1 -1
- package/build/lib/cli/extension.d.ts +10 -15
- package/build/lib/cli/extension.d.ts.map +1 -1
- package/build/lib/cli/extension.js +15 -33
- package/build/lib/cli/extension.js.map +1 -1
- package/build/lib/cli/parser.d.ts +37 -66
- package/build/lib/cli/parser.d.ts.map +1 -1
- package/build/lib/cli/parser.js +69 -104
- package/build/lib/cli/parser.js.map +1 -1
- package/build/lib/cli/plugin-command.d.ts +50 -90
- package/build/lib/cli/plugin-command.d.ts.map +1 -1
- package/build/lib/cli/plugin-command.js +11 -63
- package/build/lib/cli/plugin-command.js.map +1 -1
- package/build/lib/cli/setup-command.d.ts +21 -26
- package/build/lib/cli/setup-command.d.ts.map +1 -1
- package/build/lib/cli/setup-command.js +19 -61
- package/build/lib/cli/setup-command.js.map +1 -1
- package/build/lib/cli/utils.d.ts +33 -35
- package/build/lib/cli/utils.d.ts.map +1 -1
- package/build/lib/cli/utils.js +48 -50
- package/build/lib/cli/utils.js.map +1 -1
- package/build/lib/constants.d.ts +23 -23
- package/build/lib/constants.d.ts.map +1 -1
- package/build/lib/constants.js +10 -15
- package/build/lib/constants.js.map +1 -1
- package/build/lib/doctor/doctor.d.ts +40 -57
- package/build/lib/doctor/doctor.d.ts.map +1 -1
- package/build/lib/doctor/doctor.js +31 -62
- package/build/lib/doctor/doctor.js.map +1 -1
- package/build/lib/extension/driver-config.d.ts +18 -77
- package/build/lib/extension/driver-config.d.ts.map +1 -1
- package/build/lib/extension/driver-config.js +37 -125
- package/build/lib/extension/driver-config.js.map +1 -1
- package/build/lib/extension/extension-config.d.ts +103 -210
- package/build/lib/extension/extension-config.d.ts.map +1 -1
- package/build/lib/extension/extension-config.js +180 -342
- package/build/lib/extension/extension-config.js.map +1 -1
- package/build/lib/extension/index.d.ts +12 -29
- package/build/lib/extension/index.d.ts.map +1 -1
- package/build/lib/extension/index.js +33 -75
- package/build/lib/extension/index.js.map +1 -1
- package/build/lib/extension/manifest-migrations.d.ts +3 -20
- package/build/lib/extension/manifest-migrations.d.ts.map +1 -1
- package/build/lib/extension/manifest-migrations.js +20 -101
- package/build/lib/extension/manifest-migrations.js.map +1 -1
- package/build/lib/extension/manifest.d.ts +61 -107
- package/build/lib/extension/manifest.d.ts.map +1 -1
- package/build/lib/extension/manifest.js +181 -356
- package/build/lib/extension/manifest.js.map +1 -1
- package/build/lib/extension/package-changed.d.ts +1 -3
- package/build/lib/extension/package-changed.d.ts.map +1 -1
- package/build/lib/extension/package-changed.js +8 -15
- package/build/lib/extension/package-changed.js.map +1 -1
- package/build/lib/extension/plugin-config.d.ts +10 -52
- package/build/lib/extension/plugin-config.d.ts.map +1 -1
- package/build/lib/extension/plugin-config.js +11 -63
- package/build/lib/extension/plugin-config.js.map +1 -1
- package/build/lib/helpers/build.d.ts +22 -0
- package/build/lib/helpers/build.d.ts.map +1 -0
- package/build/lib/helpers/build.js +109 -0
- package/build/lib/helpers/build.js.map +1 -0
- package/build/lib/helpers/capability.d.ts +38 -0
- package/build/lib/helpers/capability.d.ts.map +1 -0
- package/build/lib/helpers/capability.js +128 -0
- package/build/lib/helpers/capability.js.map +1 -0
- package/build/lib/helpers/network.d.ts +14 -0
- package/build/lib/helpers/network.d.ts.map +1 -0
- package/build/lib/helpers/network.js +35 -0
- package/build/lib/helpers/network.js.map +1 -0
- package/build/lib/insecure-features.js +6 -6
- package/build/lib/insecure-features.js.map +1 -1
- package/build/lib/inspector-commands.d.ts +6 -0
- package/build/lib/inspector-commands.d.ts.map +1 -1
- package/build/lib/inspector-commands.js +6 -0
- package/build/lib/inspector-commands.js.map +1 -1
- package/build/lib/logger.d.ts +2 -3
- package/build/lib/logger.d.ts.map +1 -1
- package/build/lib/logger.js +2 -3
- package/build/lib/logger.js.map +1 -1
- package/build/lib/logsink.d.ts +13 -22
- package/build/lib/logsink.d.ts.map +1 -1
- package/build/lib/logsink.js +48 -103
- package/build/lib/logsink.js.map +1 -1
- package/build/lib/main.d.ts +15 -58
- package/build/lib/main.d.ts.map +1 -1
- package/build/lib/main.js +25 -425
- package/build/lib/main.js.map +1 -1
- package/build/lib/schema/arg-spec.d.ts +32 -107
- package/build/lib/schema/arg-spec.d.ts.map +1 -1
- package/build/lib/schema/arg-spec.js +11 -107
- package/build/lib/schema/arg-spec.js.map +1 -1
- package/build/lib/schema/cli-args-guards.d.ts +34 -0
- package/build/lib/schema/cli-args-guards.d.ts.map +1 -0
- package/build/lib/schema/cli-args-guards.js +49 -0
- package/build/lib/schema/cli-args-guards.js.map +1 -0
- package/build/lib/schema/cli-args.d.ts +3 -15
- package/build/lib/schema/cli-args.d.ts.map +1 -1
- package/build/lib/schema/cli-args.js +17 -107
- package/build/lib/schema/cli-args.js.map +1 -1
- package/build/lib/schema/cli-transformers.d.ts +15 -12
- package/build/lib/schema/cli-transformers.d.ts.map +1 -1
- package/build/lib/schema/cli-transformers.js +15 -45
- package/build/lib/schema/cli-transformers.js.map +1 -1
- package/build/lib/schema/format-errors.d.ts +28 -0
- package/build/lib/schema/format-errors.d.ts.map +1 -0
- package/build/lib/schema/format-errors.js +29 -0
- package/build/lib/schema/format-errors.js.map +1 -0
- package/build/lib/schema/index.d.ts +4 -2
- package/build/lib/schema/index.d.ts.map +1 -1
- package/build/lib/schema/index.js +2 -0
- package/build/lib/schema/index.js.map +1 -1
- package/build/lib/schema/keywords.d.ts +12 -20
- package/build/lib/schema/keywords.d.ts.map +1 -1
- package/build/lib/schema/keywords.js +6 -51
- package/build/lib/schema/keywords.js.map +1 -1
- package/build/lib/schema/schema.d.ts +106 -231
- package/build/lib/schema/schema.d.ts.map +1 -1
- package/build/lib/schema/schema.js +88 -358
- package/build/lib/schema/schema.js.map +1 -1
- package/build/lib/utils.d.ts +7 -267
- package/build/lib/utils.d.ts.map +1 -1
- package/build/lib/utils.js +10 -409
- package/build/lib/utils.js.map +1 -1
- package/lib/{appium.js → appium.ts} +297 -341
- package/lib/bidi-commands.ts +10 -14
- package/lib/bootstrap/appium-initializer.ts +212 -0
- package/lib/bootstrap/appium-main-runner.ts +172 -0
- package/lib/bootstrap/config-file.ts +178 -0
- package/lib/bootstrap/grid-v3-register.ts +250 -0
- package/lib/bootstrap/init-types.ts +31 -0
- package/lib/bootstrap/main-helpers.ts +223 -0
- package/lib/bootstrap/node-helpers.ts +180 -0
- package/lib/bootstrap/startup-config.ts +143 -0
- package/lib/cli/{args.js → args.ts} +45 -56
- package/lib/cli/driver-command.ts +122 -0
- package/lib/cli/{extension-command.js → extension-command.ts} +827 -906
- package/lib/cli/extension.ts +65 -0
- package/lib/cli/{parser.js → parser.ts} +93 -116
- package/lib/cli/plugin-command.ts +117 -0
- package/lib/cli/{setup-command.js → setup-command.ts} +59 -74
- package/lib/cli/utils.ts +97 -0
- package/lib/{constants.js → constants.ts} +30 -41
- package/lib/doctor/{doctor.js → doctor.ts} +82 -92
- package/lib/extension/driver-config.ts +165 -0
- package/lib/extension/{extension-config.js → extension-config.ts} +291 -405
- package/lib/extension/index.ts +143 -0
- package/lib/extension/manifest-migrations.ts +57 -0
- package/lib/extension/manifest.ts +369 -0
- package/lib/extension/{package-changed.js → package-changed.ts} +9 -18
- package/lib/extension/plugin-config.ts +62 -0
- package/lib/helpers/build.ts +111 -0
- package/lib/helpers/capability.ts +171 -0
- package/lib/helpers/network.ts +30 -0
- package/lib/insecure-features.ts +1 -1
- package/lib/inspector-commands.ts +6 -1
- package/lib/{logger.js → logger.ts} +1 -2
- package/lib/{logsink.js → logsink.ts} +91 -137
- package/lib/main.ts +60 -0
- package/lib/schema/arg-spec.ts +131 -0
- package/lib/schema/cli-args-guards.ts +67 -0
- package/lib/schema/cli-args.ts +171 -0
- package/lib/schema/cli-transformers.ts +83 -0
- package/lib/schema/format-errors.ts +43 -0
- package/lib/schema/index.ts +4 -0
- package/lib/schema/keywords.ts +96 -0
- package/lib/schema/schema.ts +448 -0
- package/lib/utils.ts +73 -0
- package/package.json +17 -18
- package/scripts/autoinstall-extensions.js +3 -0
- package/build/lib/config-file.d.ts +0 -100
- package/build/lib/config-file.d.ts.map +0 -1
- package/build/lib/config-file.js.map +0 -1
- package/build/lib/config.d.ts +0 -70
- package/build/lib/config.d.ts.map +0 -1
- package/build/lib/config.js +0 -390
- package/build/lib/config.js.map +0 -1
- package/build/lib/grid-register.d.ts +0 -10
- package/build/lib/grid-register.d.ts.map +0 -1
- package/build/lib/grid-register.js +0 -134
- package/build/lib/grid-register.js.map +0 -1
- package/lib/cli/driver-command.js +0 -174
- package/lib/cli/extension.js +0 -74
- package/lib/cli/plugin-command.js +0 -164
- package/lib/cli/utils.js +0 -91
- package/lib/config-file.js +0 -228
- package/lib/config.js +0 -389
- package/lib/extension/driver-config.js +0 -245
- package/lib/extension/index.js +0 -169
- package/lib/extension/manifest-migrations.js +0 -136
- package/lib/extension/manifest.js +0 -550
- package/lib/extension/plugin-config.js +0 -112
- package/lib/grid-register.js +0 -146
- package/lib/main.js +0 -545
- package/lib/schema/arg-spec.js +0 -229
- package/lib/schema/cli-args.js +0 -254
- package/lib/schema/cli-transformers.js +0 -113
- package/lib/schema/index.js +0 -2
- package/lib/schema/keywords.js +0 -136
- package/lib/schema/schema.js +0 -725
- package/lib/utils.js +0 -512
|
@@ -36,111 +36,27 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
36
36
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
37
37
|
};
|
|
38
38
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39
|
-
exports.formatErrors = formatErrors;
|
|
40
39
|
exports.readConfigFile = readConfigFile;
|
|
41
40
|
exports.normalizeConfig = normalizeConfig;
|
|
42
|
-
const better_ajv_errors_1 = __importDefault(require("@sidvind/better-ajv-errors"));
|
|
43
41
|
const lilconfig_1 = require("lilconfig");
|
|
44
42
|
const lodash_1 = __importDefault(require("lodash"));
|
|
45
43
|
const yaml = __importStar(require("yaml"));
|
|
46
|
-
const schema_1 = require("
|
|
47
|
-
|
|
48
|
-
* lilconfig loader to handle `.yaml` files
|
|
49
|
-
* @type {import('lilconfig').LoaderSync}
|
|
50
|
-
*/
|
|
51
|
-
function yamlLoader(filepath, content) {
|
|
52
|
-
try {
|
|
53
|
-
return yaml.parse(content);
|
|
54
|
-
}
|
|
55
|
-
catch (e) {
|
|
56
|
-
throw new Error(`The YAML config at '${filepath}' cannot be loaded. Original error: ${e.message}`);
|
|
57
|
-
}
|
|
58
|
-
}
|
|
44
|
+
const schema_1 = require("../schema/schema");
|
|
45
|
+
const format_errors_1 = require("../schema/format-errors");
|
|
59
46
|
/**
|
|
60
47
|
* A cache of the raw config file (a JSON string) at a filepath.
|
|
61
48
|
* This is used for better error reporting.
|
|
62
49
|
* Note that config files needn't be JSON, but it helps if they are.
|
|
63
|
-
* @type {Map<string,RawJson>}
|
|
64
50
|
*/
|
|
65
51
|
const rawConfig = new Map();
|
|
66
|
-
/**
|
|
67
|
-
* Custom JSON loader that caches the raw config file (for use with `better-ajv-errors`).
|
|
68
|
-
* If it weren't for this cache, this would be unnecessary.
|
|
69
|
-
* @type {import('lilconfig').LoaderSync}
|
|
70
|
-
*/
|
|
71
|
-
function jsonLoader(filepath, content) {
|
|
72
|
-
rawConfig.set(filepath, content);
|
|
73
|
-
try {
|
|
74
|
-
return JSON.parse(content);
|
|
75
|
-
}
|
|
76
|
-
catch (e) {
|
|
77
|
-
throw new Error(`The JSON config at '${filepath}' cannot be loaded. Original error: ${e.message}`);
|
|
78
|
-
}
|
|
79
|
-
}
|
|
80
|
-
/**
|
|
81
|
-
* Loads a config file from an explicit path
|
|
82
|
-
* @param {LilconfigAsyncSearcher} lc - lilconfig instance
|
|
83
|
-
* @param {string} filepath - Path to config file
|
|
84
|
-
* @returns {Promise<import('lilconfig').LilconfigResult>}
|
|
85
|
-
*/
|
|
86
|
-
async function loadConfigFile(lc, filepath) {
|
|
87
|
-
try {
|
|
88
|
-
// removing "await" will cause any rejection to _not_ be caught in this block!
|
|
89
|
-
return await lc.load(filepath);
|
|
90
|
-
}
|
|
91
|
-
catch ( /** @type {unknown} */err) {
|
|
92
|
-
if ( /** @type {NodeJS.ErrnoException} */(err).code === 'ENOENT') {
|
|
93
|
-
/** @type {NodeJS.ErrnoException} */ (err).message = `Config file not found at user-provided path: ${filepath}`;
|
|
94
|
-
throw err;
|
|
95
|
-
}
|
|
96
|
-
else if (err instanceof SyntaxError) {
|
|
97
|
-
// generally invalid JSON
|
|
98
|
-
err.message = `Config file at user-provided path ${filepath} is invalid:\n${err.message}`;
|
|
99
|
-
throw err;
|
|
100
|
-
}
|
|
101
|
-
throw err;
|
|
102
|
-
}
|
|
103
|
-
}
|
|
104
|
-
/**
|
|
105
|
-
* Searches for a config file
|
|
106
|
-
* @param {LilconfigAsyncSearcher} lc - lilconfig instance
|
|
107
|
-
* @returns {Promise<import('lilconfig').LilconfigResult>}
|
|
108
|
-
*/
|
|
109
|
-
async function searchConfigFile(lc) {
|
|
110
|
-
return await lc.search();
|
|
111
|
-
}
|
|
112
|
-
/**
|
|
113
|
-
* Given an array of errors and the result of loading a config file, generate a
|
|
114
|
-
* helpful string for the user.
|
|
115
|
-
*
|
|
116
|
-
* - If `opts` contains a `json` property, this should be the original JSON
|
|
117
|
-
* _string_ of the config file. This is only applicable if the config file
|
|
118
|
-
* was in JSON format. If present, it will associate line numbers with errors.
|
|
119
|
-
* - If `errors` happens to be empty, this will throw.
|
|
120
|
-
* @param {import('ajv').ErrorObject[]} errors - Non-empty array of errors. Required.
|
|
121
|
-
* @param {ReadConfigFileResult['config']|any} [config] -
|
|
122
|
-
* Configuration & metadata
|
|
123
|
-
* @param {FormatConfigErrorsOptions} [opts]
|
|
124
|
-
* @throws {TypeError} If `errors` is empty
|
|
125
|
-
* @returns {string}
|
|
126
|
-
*/
|
|
127
|
-
function formatErrors(errors = [], config = {}, opts = {}) {
|
|
128
|
-
if (errors && !errors.length) {
|
|
129
|
-
throw new TypeError('Array of errors must be non-empty');
|
|
130
|
-
}
|
|
131
|
-
return (0, better_ajv_errors_1.default)((0, schema_1.getSchema)(opts.schemaId), config, errors, {
|
|
132
|
-
json: opts.json,
|
|
133
|
-
format: 'cli',
|
|
134
|
-
});
|
|
135
|
-
}
|
|
136
52
|
/**
|
|
137
53
|
* Given an optional path, read a config file. Validates the config file.
|
|
138
54
|
*
|
|
139
55
|
* Call {@link validate} if you already have a config object.
|
|
140
|
-
* @param {string} [filepath] - Path to config file, if we have one
|
|
141
|
-
* @param {ReadConfigFileOptions} [opts] - Options
|
|
142
56
|
* @public
|
|
143
|
-
* @
|
|
57
|
+
* @param filepath - Explicit config path; when omitted, searches with lilconfig
|
|
58
|
+
* @param opts - e.g. `pretty` for formatted validation errors
|
|
59
|
+
* @returns Contains config and filepath, if found, and any errors
|
|
144
60
|
*/
|
|
145
61
|
async function readConfigFile(filepath, opts = {}) {
|
|
146
62
|
const lc = (0, lilconfig_1.lilconfig)('appium', {
|
|
@@ -162,14 +78,14 @@ async function readConfigFile(filepath, opts = {}) {
|
|
|
162
78
|
configResult = { ...result, errors };
|
|
163
79
|
}
|
|
164
80
|
else {
|
|
165
|
-
const reason = formatErrors(errors, result.config, {
|
|
81
|
+
const reason = (0, format_errors_1.formatErrors)(errors, result.config, {
|
|
166
82
|
json: rawConfig.get(result.filepath),
|
|
167
83
|
pretty,
|
|
168
84
|
});
|
|
169
85
|
configResult = reason ? { ...result, errors, reason } : { ...result, errors };
|
|
170
86
|
}
|
|
171
87
|
// normalize (to camel case) all top-level property names of the config file
|
|
172
|
-
configResult.config = normalizeConfig(
|
|
88
|
+
configResult.config = normalizeConfig(configResult.config);
|
|
173
89
|
return configResult;
|
|
174
90
|
}
|
|
175
91
|
finally {
|
|
@@ -180,70 +96,78 @@ async function readConfigFile(filepath, opts = {}) {
|
|
|
180
96
|
return result ?? {};
|
|
181
97
|
}
|
|
182
98
|
/**
|
|
183
|
-
*
|
|
184
|
-
*
|
|
185
|
-
* @
|
|
99
|
+
* Converts schema property names to either the `appiumCliDest` value, if any, or camelCase.
|
|
100
|
+
*
|
|
101
|
+
* @param config - Raw config object as parsed from file
|
|
102
|
+
* @returns New object with camel-cased keys (or CLI `dest` keys).
|
|
186
103
|
*/
|
|
187
104
|
function normalizeConfig(config) {
|
|
188
105
|
const schema = (0, schema_1.getSchema)();
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
const normalize = (config, section) => {
|
|
196
|
-
const obj = lodash_1.default.isUndefined(section) ? config : lodash_1.default.get(config, section, config);
|
|
197
|
-
const mappedObj = lodash_1.default.mapKeys(obj, (__, prop) => lodash_1.default.get(schema, `properties.server.properties[${prop}].appiumCliDest`, lodash_1.default.camelCase(prop)));
|
|
106
|
+
const isSchemaTypeObject = (schemaObj) => Boolean(schemaObj?.properties || schemaObj?.type === 'object');
|
|
107
|
+
const normalize = (rootConfig, section) => {
|
|
108
|
+
const obj = lodash_1.default.isUndefined(section)
|
|
109
|
+
? rootConfig
|
|
110
|
+
: lodash_1.default.get(rootConfig, section, rootConfig);
|
|
111
|
+
const mappedObj = lodash_1.default.mapKeys(obj, (_v, prop) => lodash_1.default.get(schema, `properties.server.properties[${prop}].appiumCliDest`, lodash_1.default.camelCase(prop)));
|
|
198
112
|
return lodash_1.default.mapValues(mappedObj, (value, property) => {
|
|
199
113
|
const nextSection = section ? `${section}.${property}` : property;
|
|
200
114
|
return isSchemaTypeObject(schema.properties?.[property])
|
|
201
|
-
? normalize(
|
|
115
|
+
? normalize(rootConfig, nextSection)
|
|
202
116
|
: value;
|
|
203
117
|
});
|
|
204
118
|
};
|
|
205
|
-
/**
|
|
206
|
-
* Returns `true` if the schema prop references an object, or if it's an object itself
|
|
207
|
-
* @param {import('ajv').SchemaObject|object} schema - Referencing schema object
|
|
208
|
-
*/
|
|
209
|
-
const isSchemaTypeObject = (schema) => Boolean(schema?.properties || schema?.type === 'object');
|
|
210
119
|
return normalize(config);
|
|
211
120
|
}
|
|
212
121
|
/**
|
|
213
|
-
*
|
|
214
|
-
* @typedef ReadConfigFileResult
|
|
215
|
-
* @property {import('ajv').ErrorObject[]} [errors] - Validation errors
|
|
216
|
-
* @property {string} [filepath] - The path to the config file, if found
|
|
217
|
-
* @property {boolean} [isEmpty] - If `true`, the config file exists but is empty
|
|
218
|
-
* @property {NormalizedAppiumConfig} [config] - The parsed configuration
|
|
219
|
-
* @property {string|import('@sidvind/better-ajv-errors').IOutputError[]} [reason] - Human-readable error messages and suggestions. If the `pretty` option is `true`, this will be a nice string to print.
|
|
220
|
-
*/
|
|
221
|
-
/**
|
|
222
|
-
* Options for {@link readConfigFile}.
|
|
223
|
-
* @typedef ReadConfigFileOptions
|
|
224
|
-
* @property {boolean} [pretty=true] If `false`, do not use color and fancy formatting in the `reason` property of the {@link ReadConfigFileResult}. The value of `reason` is then suitable for machine-reading.
|
|
225
|
-
*/
|
|
226
|
-
/**
|
|
227
|
-
* This is an `AsyncSearcher` which is inexplicably _not_ exported by the `lilconfig` type definition.
|
|
228
|
-
* @typedef {ReturnType<import('lilconfig')["lilconfig"]>} LilconfigAsyncSearcher
|
|
229
|
-
*/
|
|
230
|
-
/**
|
|
231
|
-
* The contents of an Appium config file. Generated from schema
|
|
232
|
-
* @typedef {import('@appium/types').AppiumConfig} AppiumConfig
|
|
122
|
+
* lilconfig loader to handle `.yaml` files
|
|
233
123
|
*/
|
|
124
|
+
function yamlLoader(filepath, content) {
|
|
125
|
+
try {
|
|
126
|
+
return yaml.parse(content);
|
|
127
|
+
}
|
|
128
|
+
catch (e) {
|
|
129
|
+
throw new Error(`The YAML config at '${filepath}' cannot be loaded. Original error: ${e.message}`);
|
|
130
|
+
}
|
|
131
|
+
}
|
|
234
132
|
/**
|
|
235
|
-
*
|
|
236
|
-
*
|
|
133
|
+
* Custom JSON loader that caches the raw config file (for use with `better-ajv-errors`).
|
|
134
|
+
* If it weren't for this cache, this would be unnecessary.
|
|
237
135
|
*/
|
|
136
|
+
function jsonLoader(filepath, content) {
|
|
137
|
+
rawConfig.set(filepath, content);
|
|
138
|
+
try {
|
|
139
|
+
return JSON.parse(content);
|
|
140
|
+
}
|
|
141
|
+
catch (e) {
|
|
142
|
+
rawConfig.delete(filepath);
|
|
143
|
+
throw new Error(`The JSON config at '${filepath}' cannot be loaded. Original error: ${e.message}`);
|
|
144
|
+
}
|
|
145
|
+
}
|
|
238
146
|
/**
|
|
239
|
-
*
|
|
240
|
-
* @typedef {string} RawJson
|
|
147
|
+
* Loads a config file from an explicit path
|
|
241
148
|
*/
|
|
149
|
+
async function loadConfigFile(lc, filepath) {
|
|
150
|
+
try {
|
|
151
|
+
// removing "await" will cause any rejection to _not_ be caught in this block!
|
|
152
|
+
return await lc.load(filepath);
|
|
153
|
+
}
|
|
154
|
+
catch (err) {
|
|
155
|
+
if (err.code === 'ENOENT') {
|
|
156
|
+
err.message = `Config file not found at user-provided path: ${filepath}`;
|
|
157
|
+
throw err;
|
|
158
|
+
}
|
|
159
|
+
else if (err instanceof SyntaxError) {
|
|
160
|
+
// generally invalid JSON
|
|
161
|
+
err.message = `Config file at user-provided path ${filepath} is invalid:\n${err.message}`;
|
|
162
|
+
throw err;
|
|
163
|
+
}
|
|
164
|
+
throw err;
|
|
165
|
+
}
|
|
166
|
+
}
|
|
242
167
|
/**
|
|
243
|
-
*
|
|
244
|
-
* @typedef FormatConfigErrorsOptions
|
|
245
|
-
* @property {import('./config-file').RawJson} [json] - Raw JSON config (as string)
|
|
246
|
-
* @property {boolean} [pretty=true] - Whether to format errors as a CLI-friendly string
|
|
247
|
-
* @property {string} [schemaId] - Specific ID of a prop; otherwise entire schema
|
|
168
|
+
* Searches for a config file
|
|
248
169
|
*/
|
|
170
|
+
async function searchConfigFile(lc) {
|
|
171
|
+
return await lc.search();
|
|
172
|
+
}
|
|
249
173
|
//# sourceMappingURL=config-file.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"config-file.js","sourceRoot":"","sources":["../../../lib/bootstrap/config-file.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAgDA,wCAyCC;AAQD,0CAwBC;AAvHD,yCAA2E;AAC3E,oDAAuB;AACvB,2CAA6B;AAE7B,6CAAqD;AACrD,2DAAqD;AAErD;;;;GAIG;AACH,MAAM,SAAS,GAAG,IAAI,GAAG,EAAkB,CAAC;AAyB5C;;;;;;;;GAQG;AACI,KAAK,UAAU,cAAc,CAClC,QAAiB,EACjB,OAA8B,EAAE;IAEhC,MAAM,EAAE,GAAG,IAAA,qBAAS,EAAC,QAAQ,EAAE;QAC7B,OAAO,EAAE;YACP,OAAO,EAAE,UAAwB;YACjC,MAAM,EAAE,UAAwB;YAChC,OAAO,EAAE,UAAwB;YACjC,KAAK,EAAE,UAAwB;SAChC;QACD,WAAW,EAAE,cAAc;KAC5B,CAAC,CAAC;IAEH,MAAM,MAAM,GAAG,QAAQ,CAAC,CAAC,CAAC,MAAM,cAAc,CAAC,EAAE,EAAE,QAAQ,CAAC,CAAC,CAAC,CAAC,MAAM,gBAAgB,CAAC,EAAE,CAAC,CAAC;IAE1F,IAAI,MAAM,EAAE,QAAQ,IAAI,CAAC,MAAM,EAAE,OAAO,EAAE,CAAC;QACzC,MAAM,EAAC,MAAM,GAAG,IAA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CAAC,CAAC;IACjC,IAAI,CAAC;QACH,OAAO,IAAI,CAAC,KAAK,CAAC,OAAO,CAAC,CAAC;IAC7B,CAAC;IAAC,OAAO,CAAC,EAAE,CAAC;QACX,SAAS,CAAC,MAAM,CAAC,QAAQ,CAAC,CAAC;QAC3B,MAAM,IAAI,KAAK,CACb,uBAAuB,QAAQ,uCAAwC,CAAW,CAAC,OAAO,EAAE,CAC7F,CAAC;IACJ,CAAC;AACH,CAAC;AAED;;GAEG;AACH,KAAK,UAAU,cAAc,CAAC,EAA0B,EAAE,QAAgB;IACxE,IAAI,CAAC;QACH,8EAA8E;QAC9E,OAAO,MAAM,EAAE,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;IACjC,CAAC;IAAC,OAAO,GAAG,EAAE,CAAC;QACb,IAAK,GAA6B,CAAC,IAAI,KAAK,QAAQ,EAAE,CAAC;YACpD,GAA6B,CAAC,OAAO,GAAG,gDAAgD,QAAQ,EAAE,CAAC;YACpG,MAAM,GAAG,CAAC;QACZ,CAAC;aAAM,IAAI,GAAG,YAAY,WAAW,EAAE,CAAC;YACtC,yBAAyB;YACzB,GAAG,CAAC,OAAO,GAAG,qCAAqC,QAAQ,iBAAiB,GAAG,CAAC,OAAO,EAAE,CAAC;YAC1F,MAAM,GAAG,CAAC;QACZ,CAAC;QACD,MAAM,GAAG,CAAC;IACZ,CAAC;AACH,CAAC;AAED;;GAEG;AACH,KAAK,UAAU,gBAAgB,CAAC,EAA0B;IACxD,OAAO,MAAM,EAAE,CAAC,MAAM,EAAE,CAAC;AAC3B,CAAC"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import type { StringRecord } from '@appium/types';
|
|
2
|
+
interface Grid3HubConfiguration {
|
|
3
|
+
hubProtocol?: string;
|
|
4
|
+
hubHost?: string;
|
|
5
|
+
hubPort?: number;
|
|
6
|
+
url?: string;
|
|
7
|
+
host?: string;
|
|
8
|
+
port?: number;
|
|
9
|
+
id?: string;
|
|
10
|
+
register?: boolean;
|
|
11
|
+
registerCycle?: number;
|
|
12
|
+
}
|
|
13
|
+
interface Grid3NodeConfig extends StringRecord {
|
|
14
|
+
configuration?: Grid3HubConfiguration;
|
|
15
|
+
capabilities?: unknown;
|
|
16
|
+
}
|
|
17
|
+
export default function registerNode(data: string, addr: string, port: number, basePath: string): Promise<void>;
|
|
18
|
+
export default function registerNode(data: Grid3NodeConfig, addr?: string, port?: number, basePath?: string): Promise<void>;
|
|
19
|
+
export {};
|
|
20
|
+
//# sourceMappingURL=grid-v3-register.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"grid-v3-register.d.ts","sourceRoot":"","sources":["../../../lib/bootstrap/grid-v3-register.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAC,YAAY,EAAC,MAAM,eAAe,CAAC;AAkBhD,UAAU,qBAAqB;IAC7B,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,OAAO,CAAC,EAAE,MAAM,CAAC;IACjB,GAAG,CAAC,EAAE,MAAM,CAAC;IACb,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,EAAE,CAAC,EAAE,MAAM,CAAC;IACZ,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB;AAED,UAAU,eAAgB,SAAQ,YAAY;IAC5C,aAAa,CAAC,EAAE,qBAAqB,CAAC;IACtC,YAAY,CAAC,EAAE,OAAO,CAAC;CACxB;AAOD,wBAA8B,YAAY,CACxC,IAAI,EAAE,MAAM,EACZ,IAAI,EAAE,MAAM,EACZ,IAAI,EAAE,MAAM,EACZ,QAAQ,EAAE,MAAM,GACf,OAAO,CAAC,IAAI,CAAC,CAAC;AACjB,wBAA8B,YAAY,CACxC,IAAI,EAAE,eAAe,EACrB,IAAI,CAAC,EAAE,MAAM,EACb,IAAI,CAAC,EAAE,MAAM,EACb,QAAQ,CAAC,EAAE,MAAM,GAChB,OAAO,CAAC,IAAI,CAAC,CAAC"}
|
|
@@ -0,0 +1,185 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.default = registerNode;
|
|
7
|
+
const axios_1 = __importDefault(require("axios"));
|
|
8
|
+
const support_1 = require("@appium/support");
|
|
9
|
+
const lodash_1 = __importDefault(require("lodash"));
|
|
10
|
+
const logger_1 = require("../logger");
|
|
11
|
+
/**
|
|
12
|
+
* Selenium **Grid 3** (legacy hub) node integration.
|
|
13
|
+
*
|
|
14
|
+
* Registers this Appium process as a node with a Selenium Grid 3 hub using the classic
|
|
15
|
+
* `/grid/register` endpoint and `/grid/api/proxy` for re-registration checks.
|
|
16
|
+
* This does **not** apply to Selenium Grid 4 (which uses a different topology and APIs).
|
|
17
|
+
*
|
|
18
|
+
* @see https://www.selenium.dev/documentation/legacy/grid_3/
|
|
19
|
+
*/
|
|
20
|
+
/** REST paths exposed by a Selenium Grid 3 hub. */
|
|
21
|
+
const GRID_V3_REGISTER_PATH = '/grid/register';
|
|
22
|
+
const GRID_V3_PROXY_API_PATH = '/grid/api/proxy';
|
|
23
|
+
/**
|
|
24
|
+
* Registers this server as a node with a **Selenium Grid 3** hub.
|
|
25
|
+
*
|
|
26
|
+
* When `data` is a path to a JSON config file, `addr`, `port`, and `basePath` are required (they define
|
|
27
|
+
* how the hub reaches this Appium server). When `data` is an inline config object, those parameters are
|
|
28
|
+
* optional and only used to fill missing node URL fields in the config.
|
|
29
|
+
*
|
|
30
|
+
* @deprecated Selenium Grid 3 registration is legacy and slated for removal.
|
|
31
|
+
* Use Selenium Grid 4 integration (node relay) instead.
|
|
32
|
+
*
|
|
33
|
+
* @param data - Path to a JSON file or an inline parsed config object
|
|
34
|
+
* @param addr - Bind to this address
|
|
35
|
+
* @param port - Bind to this port
|
|
36
|
+
* @param basePath - Base path for the Appium server (used in the node URL sent to the hub; may be `''`)
|
|
37
|
+
*/
|
|
38
|
+
async function registerNode(data, addr, port, basePath) {
|
|
39
|
+
if (typeof data === 'string') {
|
|
40
|
+
if (addr === undefined || port === undefined || basePath === undefined) {
|
|
41
|
+
throw logger_1.log.errorWithException('When the first argument is a Selenium Grid 3 node config file path, address, port, and basePath ' +
|
|
42
|
+
'are required (e.g. match your Appium `--address`, `--port`, and base path).');
|
|
43
|
+
}
|
|
44
|
+
if (typeof port !== 'number' || !Number.isFinite(port)) {
|
|
45
|
+
throw logger_1.log.errorWithException('When registering from a node config file path, port must be a finite number.');
|
|
46
|
+
}
|
|
47
|
+
}
|
|
48
|
+
let configHolder;
|
|
49
|
+
if (lodash_1.default.isString(data)) {
|
|
50
|
+
const configFilePath = data;
|
|
51
|
+
let fileContent;
|
|
52
|
+
try {
|
|
53
|
+
fileContent = await support_1.fs.readFile(data, 'utf-8');
|
|
54
|
+
}
|
|
55
|
+
catch (err) {
|
|
56
|
+
logger_1.log.error(`Unable to load Selenium Grid 3 node configuration file ${configFilePath} to ` +
|
|
57
|
+
`register with the hub: ${err.message}`);
|
|
58
|
+
return;
|
|
59
|
+
}
|
|
60
|
+
try {
|
|
61
|
+
configHolder = JSON.parse(fileContent);
|
|
62
|
+
}
|
|
63
|
+
catch (err) {
|
|
64
|
+
throw logger_1.log.errorWithException(`Syntax error in Selenium Grid 3 node configuration file ${configFilePath}: ` +
|
|
65
|
+
err.message);
|
|
66
|
+
}
|
|
67
|
+
}
|
|
68
|
+
else {
|
|
69
|
+
configHolder = data;
|
|
70
|
+
}
|
|
71
|
+
postRequest(configHolder, addr, port, basePath);
|
|
72
|
+
}
|
|
73
|
+
/** Base URL for the Selenium Grid 3 hub (protocol + host + port). */
|
|
74
|
+
function hubUri(config) {
|
|
75
|
+
const protocol = config.hubProtocol || 'http';
|
|
76
|
+
return `${protocol}://${config.hubHost}:${config.hubPort}`;
|
|
77
|
+
}
|
|
78
|
+
/** POST registration payload to the Selenium Grid 3 hub. */
|
|
79
|
+
async function registerToGrid(postOptions, configHolder) {
|
|
80
|
+
const hubCfg = configHolder.configuration;
|
|
81
|
+
if (!hubCfg) {
|
|
82
|
+
return;
|
|
83
|
+
}
|
|
84
|
+
try {
|
|
85
|
+
const { status } = await (0, axios_1.default)(postOptions);
|
|
86
|
+
if (status !== 200) {
|
|
87
|
+
throw new Error(`Request failed with code ${status}`);
|
|
88
|
+
}
|
|
89
|
+
logger_1.log.debug(`Appium successfully registered with the Selenium Grid 3 hub at ` + hubUri(hubCfg));
|
|
90
|
+
}
|
|
91
|
+
catch (err) {
|
|
92
|
+
logger_1.log.error(`An attempt to register with the Selenium Grid 3 hub was unsuccessful: ` +
|
|
93
|
+
err.message);
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
function postRequest(configHolder, addr, port, basePath) {
|
|
97
|
+
// Move Selenium Grid 3 (flat) configuration properties into `configuration`
|
|
98
|
+
if (!lodash_1.default.has(configHolder, 'configuration')) {
|
|
99
|
+
const configuration = {};
|
|
100
|
+
const holder = configHolder;
|
|
101
|
+
for (const property in holder) {
|
|
102
|
+
if (lodash_1.default.has(holder, property) && property !== 'capabilities') {
|
|
103
|
+
configuration[property] = holder[property];
|
|
104
|
+
delete holder[property];
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
holder.configuration = configuration;
|
|
108
|
+
}
|
|
109
|
+
const cfg = configHolder.configuration;
|
|
110
|
+
if (!cfg) {
|
|
111
|
+
return;
|
|
112
|
+
}
|
|
113
|
+
// if the node config does not have the appium/webdriver url, host, and port,
|
|
114
|
+
// automatically add it based on how appium was initialized
|
|
115
|
+
// otherwise, we will take whatever the user setup
|
|
116
|
+
// because we will always set localhost/127.0.0.1. this won't work if your
|
|
117
|
+
// node and hub aren't in the same place
|
|
118
|
+
if (!cfg.url || !cfg.host || !cfg.port) {
|
|
119
|
+
cfg.url = `http://${addr}:${port}${basePath}`;
|
|
120
|
+
cfg.host = addr;
|
|
121
|
+
cfg.port = port;
|
|
122
|
+
}
|
|
123
|
+
// if the node config does not have id automatically add it
|
|
124
|
+
if (!cfg.id) {
|
|
125
|
+
cfg.id = `http://${cfg.host}:${cfg.port}`;
|
|
126
|
+
}
|
|
127
|
+
// the post options
|
|
128
|
+
const regRequest = {
|
|
129
|
+
url: `${hubUri(cfg)}${GRID_V3_REGISTER_PATH}`,
|
|
130
|
+
method: 'POST',
|
|
131
|
+
data: configHolder,
|
|
132
|
+
};
|
|
133
|
+
if (cfg.register !== true) {
|
|
134
|
+
logger_1.log.debug(`No Selenium Grid 3 hub registration sent (${cfg.register} = false)`);
|
|
135
|
+
return;
|
|
136
|
+
}
|
|
137
|
+
const registerCycleInterval = cfg.registerCycle;
|
|
138
|
+
if (registerCycleInterval === undefined || isNaN(registerCycleInterval) || registerCycleInterval <= 0) {
|
|
139
|
+
logger_1.log.warn(`'registerCycle' is not a valid positive number. ` +
|
|
140
|
+
`No registration request will be sent to the Selenium Grid 3 hub.`);
|
|
141
|
+
return;
|
|
142
|
+
}
|
|
143
|
+
// initiate a new Thread
|
|
144
|
+
let first = true;
|
|
145
|
+
logger_1.log.debug(`Starting auto-register thread for Selenium Grid 3. ` +
|
|
146
|
+
`Will try to register every ${registerCycleInterval} ms.`);
|
|
147
|
+
setInterval(async function registerRetry() {
|
|
148
|
+
if (first) {
|
|
149
|
+
first = false;
|
|
150
|
+
await registerToGrid(regRequest, configHolder);
|
|
151
|
+
}
|
|
152
|
+
else if (!(await isAlreadyRegistered(configHolder))) {
|
|
153
|
+
// make the http POST to the Selenium Grid 3 hub for registration
|
|
154
|
+
await registerToGrid(regRequest, configHolder);
|
|
155
|
+
}
|
|
156
|
+
}, registerCycleInterval);
|
|
157
|
+
}
|
|
158
|
+
/** Query the Selenium Grid 3 hub to see if this node id is already registered. */
|
|
159
|
+
async function isAlreadyRegistered(configHolder) {
|
|
160
|
+
//check if node is already registered
|
|
161
|
+
const hubCfg = configHolder.configuration;
|
|
162
|
+
if (!hubCfg?.id) {
|
|
163
|
+
return;
|
|
164
|
+
}
|
|
165
|
+
const id = hubCfg.id;
|
|
166
|
+
try {
|
|
167
|
+
const { data, status } = await (0, axios_1.default)({
|
|
168
|
+
url: `${hubUri(hubCfg)}${GRID_V3_PROXY_API_PATH}`,
|
|
169
|
+
params: { id },
|
|
170
|
+
timeout: 10000,
|
|
171
|
+
});
|
|
172
|
+
if (status !== 200) {
|
|
173
|
+
throw new Error(`Request failed with code ${status}`);
|
|
174
|
+
}
|
|
175
|
+
if (!data.success) {
|
|
176
|
+
// if register fail, print the debug msg
|
|
177
|
+
logger_1.log.debug(`Selenium Grid 3 hub registration check: ${data.msg}`);
|
|
178
|
+
}
|
|
179
|
+
return data.success;
|
|
180
|
+
}
|
|
181
|
+
catch (err) {
|
|
182
|
+
logger_1.log.debug(`Selenium Grid 3 hub down or not responding: ${err.message}`);
|
|
183
|
+
}
|
|
184
|
+
}
|
|
185
|
+
//# sourceMappingURL=grid-v3-register.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"grid-v3-register.js","sourceRoot":"","sources":["../../../lib/bootstrap/grid-v3-register.ts"],"names":[],"mappings":";;;;;AAqEA,+BA8CC;AAnHD,kDAA0B;AAC1B,6CAAmC;AAEnC,oDAAuB;AACvB,sCAAwC;AAExC;;;;;;;;GAQG;AAEH,mDAAmD;AACnD,MAAM,qBAAqB,GAAG,gBAAgB,CAAC;AAC/C,MAAM,sBAAsB,GAAG,iBAAiB,CAAC;AAoCjD;;;;;;;;;;;;;;GAcG;AACY,KAAK,UAAU,YAAY,CACxC,IAA8B,EAC9B,IAAa,EACb,IAAa,EACb,QAAiB;IAEjB,IAAI,OAAO,IAAI,KAAK,QAAQ,EAAE,CAAC;QAC7B,IAAI,IAAI,KAAK,SAAS,IAAI,IAAI,KAAK,SAAS,IAAI,QAAQ,KAAK,SAAS,EAAE,C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OAAO,GAAG,EAAE,CAAC;QACb,YAAM,CAAC,KAAK,CAAC,+CAAgD,GAAa,CAAC,OAAO,EAAE,CAAC,CAAC;IACxF,CAAC;AACH,CAAC"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import type { AppiumDriver } from '../appium';
|
|
2
|
+
import type { Args, CliCommand, CliCommandServer, CliCommandSetupSubcommand, CliExtensionSubcommand, ParsedArgs } from 'appium/types';
|
|
3
|
+
import type { ExtensionConfigs } from '../extension';
|
|
4
|
+
/** Empty object returned when `init` completes for non-server CLI flows (extension/setup). */
|
|
5
|
+
export type ExtCommandInitResult = Record<string, never>;
|
|
6
|
+
/** Driver/plugin config plus server instance and merged server args after successful server `init`. */
|
|
7
|
+
export type ServerInitData = ExtensionConfigs & {
|
|
8
|
+
appiumDriver: AppiumDriver;
|
|
9
|
+
parsedArgs: ParsedArgs<CliCommandServer>;
|
|
10
|
+
appiumHome: string;
|
|
11
|
+
};
|
|
12
|
+
/** Discriminated by CLI command: server subcommand yields {@link ServerInitData}; otherwise {@link ExtCommandInitResult}. */
|
|
13
|
+
export type InitResult<Cmd extends CliCommand = CliCommandServer> = Cmd extends CliCommandServer ? ServerInitData : ExtCommandInitResult;
|
|
14
|
+
/** CLI + programmatic args before `init` narrows by `subcommand`. */
|
|
15
|
+
export type PreConfigArgs = Args<CliCommand, CliExtensionSubcommand | CliCommandSetupSubcommand | void>;
|
|
16
|
+
//# sourceMappingURL=init-types.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"init-types.d.ts","sourceRoot":"","sources":["../../../lib/bootstrap/init-types.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAC,YAAY,EAAC,MAAM,WAAW,CAAC;AAC5C,OAAO,KAAK,EACV,IAAI,EACJ,UAAU,EACV,gBAAgB,EAChB,yBAAyB,EACzB,sBAAsB,EACtB,UAAU,EACX,MAAM,cAAc,CAAC;AACtB,OAAO,KAAK,EAAC,gBAAgB,EAAC,MAAM,cAAc,CAAC;AAEnD,8FAA8F;AAC9F,MAAM,MAAM,oBAAoB,GAAG,MAAM,CAAC,MAAM,EAAE,KAAK,CAAC,CAAC;AAEzD,uGAAuG;AACvG,MAAM,MAAM,cAAc,GAAG,gBAAgB,GAAG;IAC9C,YAAY,EAAE,YAAY,CAAC;IAC3B,UAAU,EAAE,UAAU,CAAC,gBAAgB,CAAC,CAAC;IACzC,UAAU,EAAE,MAAM,CAAC;CACpB,CAAC;AAEF,6HAA6H;AAC7H,MAAM,MAAM,UAAU,CAAC,GAAG,SAAS,UAAU,GAAG,gBAAgB,IAAI,GAAG,SAAS,gBAAgB,GAC5F,cAAc,GACd,oBAAoB,CAAC;AAEzB,qEAAqE;AACrE,MAAM,MAAM,aAAa,GAAG,IAAI,CAC9B,UAAU,EACV,sBAAsB,GAAG,yBAAyB,GAAG,IAAI,CAC1D,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"init-types.js","sourceRoot":"","sources":["../../../lib/bootstrap/init-types.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
import { type ServerOpts } from '@appium/base-driver';
|
|
2
|
+
import type { AppiumServer, Driver, MethodMap, UpdateServerCallback } from '@appium/types';
|
|
3
|
+
import type { AppiumDriver } from '../appium';
|
|
4
|
+
import type { ParsedArgs, CliCommandServer } from 'appium/types';
|
|
5
|
+
import type { DriverNameMap, PluginNameMap } from '../extension';
|
|
6
|
+
/**
|
|
7
|
+
* Logs a value to the console using the info logger (with util.inspect formatting).
|
|
8
|
+
*/
|
|
9
|
+
export declare const inspect: (t1: unknown) => void;
|
|
10
|
+
/**
|
|
11
|
+
* Prints the current build info JSON to stdout.
|
|
12
|
+
*
|
|
13
|
+
* This updates build metadata first (using GitHub fallback) and then logs the
|
|
14
|
+
* resulting {@link BuildInfo} object.
|
|
15
|
+
*/
|
|
16
|
+
export declare function showBuildInfo(): Promise<void>;
|
|
17
|
+
/**
|
|
18
|
+
* Human-readable label for where Appium resolved `APPIUM_HOME` from (CLI, env, or autodetect).
|
|
19
|
+
*/
|
|
20
|
+
export declare function determineAppiumHomeSource(appiumHomeFromArgs?: string | null): string;
|
|
21
|
+
/**
|
|
22
|
+
* Logs the REST listener URL; if the bind address is a broadcast address, lists concrete interface URLs.
|
|
23
|
+
*/
|
|
24
|
+
export declare function logServerAddress(url: string): void;
|
|
25
|
+
/**
|
|
26
|
+
* Validates Node version, optional long stack traces, schema, tmp dir, and `--build-info` early exit.
|
|
27
|
+
*
|
|
28
|
+
* @param args - Parsed server CLI args
|
|
29
|
+
* @param throwInsteadOfExit - When true, rethrows failures instead of calling `process.exit(1)`
|
|
30
|
+
*/
|
|
31
|
+
export declare function preflightChecks(args: ParsedArgs<CliCommandServer>, throwInsteadOfExit?: boolean): Promise<void>;
|
|
32
|
+
/**
|
|
33
|
+
* Prints welcome line (version + optional git rev), non-default server args, and default capabilities.
|
|
34
|
+
*/
|
|
35
|
+
export declare function logStartupInfo(args: ParsedArgs<CliCommandServer>): Promise<void>;
|
|
36
|
+
/**
|
|
37
|
+
* Collects `updateServer` hooks from active driver and plugin classes for HTTP server customization.
|
|
38
|
+
*/
|
|
39
|
+
export declare function getServerUpdaters(driverClasses: DriverNameMap, pluginClasses: PluginNameMap): UpdateServerCallback[];
|
|
40
|
+
/**
|
|
41
|
+
* Merges `newMethodMap` contributions from all active drivers and plugins into one method map.
|
|
42
|
+
*/
|
|
43
|
+
export declare function getExtraMethodMap(driverClasses: DriverNameMap, pluginClasses: PluginNameMap): MethodMap<Driver>;
|
|
44
|
+
/**
|
|
45
|
+
* Builds {@link ServerOpts} and normalized base path for the Appium HTTP server from CLI args and extensions.
|
|
46
|
+
*/
|
|
47
|
+
export declare function buildServerOpts(appiumDriver: AppiumDriver, parsedArgs: ParsedArgs<CliCommandServer>, driverClasses: DriverNameMap, pluginClasses: PluginNameMap): {
|
|
48
|
+
serverOpts: ServerOpts;
|
|
49
|
+
normalizedBasePath: string;
|
|
50
|
+
};
|
|
51
|
+
/**
|
|
52
|
+
* Creates the Appium HTTP server and attaches WebSocket handlers for BiDi under the normalized base path.
|
|
53
|
+
*/
|
|
54
|
+
export declare function createAppiumServer(serverOpts: ServerOpts, appiumDriver: AppiumDriver, normalizedBasePath: string): Promise<AppiumServer>;
|
|
55
|
+
//# sourceMappingURL=main-helpers.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"main-helpers.d.ts","sourceRoot":"","sources":["../../../lib/bootstrap/main-helpers.ts"],"names":[],"mappings":"AAEA,OAAO,EAIL,KAAK,UAAU,EAChB,MAAM,qBAAqB,CAAC;AAE7B,OAAO,KAAK,EAAC,YAAY,EAAE,MAAM,EAAE,SAAS,EAAE,oBAAoB,EAAC,MAAM,eAAe,CAAC;AAGzF,OAAO,KAAK,EAAC,YAAY,EAAC,MAAM,WAAW,CAAC;AAO5C,OAAO,KAAK,EAAO,UAAU,EAAE,gBAAgB,EAAC,MAAM,cAAc,CAAC;AACrE,OAAO,KAAK,EAAC,aAAa,EAAE,aAAa,EAAC,MAAM,cAAc,CAAC;AAI/D;;GAEG;AACH,eAAO,MAAM,OAAO,uBASnB,CAAC;AAEF;;;;;GAKG;AACH,wBAAsB,aAAa,IAAI,OAAO,CAAC,IAAI,CAAC,CAInD;AAED;;GAEG;AACH,wBAAgB,yBAAyB,CAAC,kBAAkB,CAAC,EAAE,MAAM,GAAG,IAAI,GAAG,MAAM,CAQpF;AAED;;GAEG;AACH,wBAAgB,gBAAgB,CAAC,GAAG,EAAE,MAAM,GAAG,IAAI,CAiBlD;AAED;;;;;GAKG;AACH,wBAAsB,eAAe,CACnC,IAAI,EAAE,UAAU,CAAC,gBAAgB,CAAC,EAClC,kBAAkB,UAAQ,GACzB,OAAO,CAAC,IAAI,CAAC,CAyBf;AAED;;GAEG;AACH,wBAAsB,cAAc,CAAC,IAAI,EAAE,UAAU,CAAC,gBAAgB,CAAC,GAAG,OAAO,CAAC,IAAI,C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