@poe-platform/safe-bash 0.1.640 → 0.1.642
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/dist/safe-bash/commands/playwright/index.d.ts.map +1 -1
- package/dist/safe-bash/commands/playwright/index.js +9 -1
- package/dist/safe-bash/commands/playwright/index.js.map +1 -1
- package/dist/safe-bash/playwright/abilities.d.ts +40 -0
- package/dist/safe-bash/playwright/abilities.d.ts.map +1 -0
- package/dist/safe-bash/playwright/abilities.js +43 -0
- package/dist/safe-bash/playwright/abilities.js.map +1 -0
- package/dist/safe-bash/playwright/ability-execution.d.ts +10 -0
- package/dist/safe-bash/playwright/ability-execution.d.ts.map +1 -0
- package/dist/safe-bash/playwright/ability-execution.js +126 -0
- package/dist/safe-bash/playwright/ability-execution.js.map +1 -0
- package/dist/safe-bash/playwright/builtins.d.ts +61 -0
- package/dist/safe-bash/playwright/builtins.d.ts.map +1 -0
- package/dist/safe-bash/playwright/builtins.js +23 -0
- package/dist/safe-bash/playwright/builtins.js.map +1 -0
- package/dist/safe-bash/playwright/catalog.d.ts +19 -0
- package/dist/safe-bash/playwright/catalog.d.ts.map +1 -0
- package/dist/safe-bash/playwright/catalog.js +35 -0
- package/dist/safe-bash/playwright/catalog.js.map +1 -0
- package/dist/safe-bash/playwright/command-reference.d.ts +584 -0
- package/dist/safe-bash/playwright/command-reference.d.ts.map +1 -0
- package/dist/safe-bash/playwright/command-reference.js +712 -0
- package/dist/safe-bash/playwright/command-reference.js.map +1 -0
- package/dist/safe-bash/playwright/controller.d.ts +3 -0
- package/dist/safe-bash/playwright/controller.d.ts.map +1 -1
- package/dist/safe-bash/playwright/controller.js +68 -9
- package/dist/safe-bash/playwright/controller.js.map +1 -1
- package/dist/safe-bash/playwright/help.d.ts +3 -60
- package/dist/safe-bash/playwright/help.d.ts.map +1 -1
- package/dist/safe-bash/playwright/help.js +48 -50
- package/dist/safe-bash/playwright/help.js.map +1 -1
- package/dist/safe-bash/playwright/index.d.ts +2 -0
- package/dist/safe-bash/playwright/index.d.ts.map +1 -1
- package/dist/safe-bash/playwright/index.js +1 -0
- package/dist/safe-bash/playwright/index.js.map +1 -1
- package/dist/safe-bash/playwright/invocation.d.ts +6 -4
- package/dist/safe-bash/playwright/invocation.d.ts.map +1 -1
- package/dist/safe-bash/playwright/invocation.js +106 -74
- package/dist/safe-bash/playwright/invocation.js.map +1 -1
- package/package.json +2 -2
|
@@ -1,123 +1,155 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export function parseInvocation(invocation, adapter) {
|
|
3
|
-
let session;
|
|
4
|
-
let browser = 'chromium';
|
|
5
|
-
let headless = true;
|
|
6
|
-
let filename;
|
|
7
|
-
let fullPage = false;
|
|
8
|
-
let browserOption = false;
|
|
9
|
-
let modeOption = false;
|
|
10
|
-
let help = false;
|
|
1
|
+
import { playwrightCommandCatalog } from './catalog.js';
|
|
2
|
+
export function parseInvocation(invocation, abilities, adapter) {
|
|
11
3
|
const positional = [];
|
|
12
|
-
const
|
|
4
|
+
const supplied = new Map();
|
|
5
|
+
const knownOptions = new Map(Object.values(playwrightCommandCatalog).flatMap(command => Object.entries(command.options)));
|
|
6
|
+
knownOptions.set('headless', { type: 'boolean', description: '' });
|
|
7
|
+
knownOptions.set('session', { type: 'string', description: '' });
|
|
8
|
+
let help = false;
|
|
13
9
|
let literal = false;
|
|
14
|
-
for (let
|
|
15
|
-
const arg = invocation.args[
|
|
10
|
+
for (let index = 0; index < invocation.args.length; index++) {
|
|
11
|
+
const arg = invocation.args[index];
|
|
12
|
+
if (typeof arg !== 'string' || arg.includes('\0'))
|
|
13
|
+
throw new Error('Invalid Playwright argument');
|
|
16
14
|
if (arg === '--' && !literal) {
|
|
17
15
|
literal = true;
|
|
18
16
|
continue;
|
|
19
17
|
}
|
|
20
|
-
|
|
18
|
+
const numeric = arg.startsWith('-') && arg.length > 1 && '0123456789.'.includes(arg[1]) && Number.isFinite(Number(arg));
|
|
19
|
+
if (literal || !arg.startsWith('-') || numeric) {
|
|
21
20
|
positional.push(arg);
|
|
22
21
|
continue;
|
|
23
22
|
}
|
|
24
23
|
const separator = arg.indexOf('=');
|
|
25
24
|
const flag = separator === -1 ? arg : arg.slice(0, separator);
|
|
26
|
-
const key = flag === '-s' ? '
|
|
27
|
-
if (
|
|
28
|
-
throw new Error(`Repeated option: ${flag}`);
|
|
29
|
-
seen.add(key);
|
|
30
|
-
if (key === '--session' || key === '--browser' || key === '--filename') {
|
|
31
|
-
const value = separator === -1 ? invocation.args[++i] : arg.slice(separator + 1);
|
|
32
|
-
if (!value || value.startsWith('-') || value.includes('\0'))
|
|
33
|
-
throw new Error(`Missing or invalid value: ${flag}`);
|
|
34
|
-
if (key === '--session')
|
|
35
|
-
session = value;
|
|
36
|
-
else if (key === '--filename')
|
|
37
|
-
filename = value;
|
|
38
|
-
else {
|
|
39
|
-
browser = value;
|
|
40
|
-
browserOption = true;
|
|
41
|
-
}
|
|
42
|
-
}
|
|
43
|
-
else if ((key === '--help' || key === '-h') && separator === -1)
|
|
25
|
+
const key = flag === '-s' ? 'session' : flag === '-g' ? 'global' : flag.slice(2);
|
|
26
|
+
if ((flag === '-h' || flag === '--help') && separator === -1) {
|
|
44
27
|
help = true;
|
|
45
|
-
|
|
46
|
-
if (separator !== -1 || modeOption)
|
|
47
|
-
throw new Error(`Invalid option: ${arg}`);
|
|
48
|
-
headless = key === '--headless';
|
|
49
|
-
modeOption = true;
|
|
28
|
+
continue;
|
|
50
29
|
}
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
else
|
|
30
|
+
const definition = knownOptions.get(key);
|
|
31
|
+
if (!definition || flag !== '-s' && flag !== '-g' && !flag.startsWith('--'))
|
|
54
32
|
throw new Error(`Unsupported option: ${arg}`);
|
|
33
|
+
let value;
|
|
34
|
+
if (definition.type === 'boolean') {
|
|
35
|
+
if (separator !== -1)
|
|
36
|
+
throw new Error(`Invalid option: ${arg}`);
|
|
37
|
+
value = true;
|
|
38
|
+
}
|
|
39
|
+
else if (definition.optionalValue && separator === -1 && (invocation.args[index + 1] === undefined || invocation.args[index + 1].startsWith('-'))) {
|
|
40
|
+
value = true;
|
|
41
|
+
}
|
|
42
|
+
else {
|
|
43
|
+
const candidate = separator === -1 ? invocation.args[++index] : arg.slice(separator + 1);
|
|
44
|
+
if (candidate === undefined || candidate.includes('\0') || separator === -1 && candidate.startsWith('-') && !Number.isFinite(Number(candidate)))
|
|
45
|
+
throw new Error(`Missing or invalid value: ${flag}`);
|
|
46
|
+
value = candidate;
|
|
47
|
+
}
|
|
48
|
+
const values = supplied.get(key) ?? [];
|
|
49
|
+
values.push(value);
|
|
50
|
+
supplied.set(key, values);
|
|
55
51
|
}
|
|
56
52
|
if (positional[0] === 'help') {
|
|
57
53
|
help = true;
|
|
58
54
|
positional.shift();
|
|
59
55
|
}
|
|
56
|
+
if (!positional.length && !supplied.size)
|
|
57
|
+
help = true;
|
|
60
58
|
if (help && (positional.length === 0 || positional.length === 1 && positional[0] === 'tab'))
|
|
61
59
|
return { command: 'help', ...(positional[0] === 'tab' ? { topic: 'tab' } : {}) };
|
|
62
|
-
// Accept both agent-oriented CLI tab-* spellings and tab <operation>.
|
|
63
60
|
if (positional[0] === 'tab')
|
|
64
61
|
positional.splice(0, 2, `tab-${positional[1] ?? ''}`);
|
|
65
|
-
const command = positional
|
|
66
|
-
if (!Object.hasOwn(
|
|
67
|
-
throw new Error(`Unsupported command
|
|
62
|
+
const command = positional.shift();
|
|
63
|
+
if (!Object.hasOwn(playwrightCommandCatalog, command))
|
|
64
|
+
throw new Error(`Unsupported command: ${command ?? ''}`);
|
|
68
65
|
if (help)
|
|
69
66
|
return { command: 'help', topic: command };
|
|
70
|
-
|
|
67
|
+
const ability = abilities.get(command);
|
|
68
|
+
if (!ability)
|
|
69
|
+
throw new Error(`Playwright ability not enabled: ${command}`);
|
|
70
|
+
const sessionValues = supplied.get('session');
|
|
71
|
+
if (sessionValues && sessionValues.length !== 1)
|
|
72
|
+
throw new Error('Repeated option: --session');
|
|
73
|
+
const session = sessionValues?.[0] ?? invocation.env.PLAYWRIGHT_CLI_SESSION ?? 'default';
|
|
71
74
|
if (!session || session.length > 128 || [...session].some(char => !'abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789_-'.includes(char)))
|
|
72
75
|
throw new Error('Invalid session name');
|
|
73
|
-
|
|
76
|
+
supplied.delete('session');
|
|
77
|
+
const options = {};
|
|
78
|
+
for (const [flag, values] of supplied) {
|
|
79
|
+
const definition = ability.options[flag];
|
|
80
|
+
if (!definition)
|
|
81
|
+
throw new Error(`Unsupported option: --${flag}`);
|
|
82
|
+
if (values.length > 1 && !definition.repeatable)
|
|
83
|
+
throw new Error(`Repeated option: --${flag}`);
|
|
84
|
+
options[flag] = definition.repeatable ? Object.freeze(values) : values[0];
|
|
85
|
+
}
|
|
86
|
+
const [min, max] = ability.arity;
|
|
74
87
|
if (positional.length < min || positional.length > max)
|
|
75
88
|
throw new Error(`Invalid arguments for ${command}`);
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
if (
|
|
81
|
-
throw new Error(
|
|
82
|
-
|
|
89
|
+
const parsed = { command, session, args: Object.freeze(positional), options: Object.freeze(options), browser: 'chromium', headless: true, fullPage: false, imageType: 'png' };
|
|
90
|
+
if (ability.execute)
|
|
91
|
+
return parsed;
|
|
92
|
+
const browser = options.browser ?? 'chromium';
|
|
93
|
+
if (browser !== 'chromium' && browser !== 'firefox' && browser !== 'webkit')
|
|
94
|
+
throw new Error(`Unsupported browser: ${browser}`);
|
|
95
|
+
parsed.browser = browser;
|
|
96
|
+
if (options.headed && options.headless)
|
|
97
|
+
throw new Error('Invalid option: --headless');
|
|
98
|
+
parsed.headless = !options.headed;
|
|
99
|
+
parsed.fullPage = options['full-page'] === true;
|
|
100
|
+
if (options.filename !== undefined) {
|
|
101
|
+
const filename = options.filename;
|
|
102
|
+
if (!filename)
|
|
103
|
+
throw new Error('Missing or invalid value: --filename');
|
|
104
|
+
parsed.filename = filename;
|
|
105
|
+
}
|
|
106
|
+
if (command === 'screenshot' || parsed.filename !== undefined) {
|
|
83
107
|
if (typeof invocation.writeArtifact !== 'function')
|
|
84
108
|
throw new Error('Artifact byte destination unsupported');
|
|
85
109
|
}
|
|
86
|
-
if (browser !== 'chromium' && browser !== 'firefox' && browser !== 'webkit')
|
|
87
|
-
throw new Error(`Unsupported browser: ${browser}`);
|
|
88
110
|
if (command === 'open') {
|
|
89
111
|
if (!adapter)
|
|
90
112
|
throw new Error('An injected Playwright adapter is required');
|
|
91
113
|
const capability = adapter.browsers[browser];
|
|
92
114
|
if (!capability)
|
|
93
115
|
throw new Error(`Unsupported browser: ${browser}`);
|
|
94
|
-
if (!headless && !capability.headed)
|
|
116
|
+
if (!parsed.headless && !capability.headed)
|
|
95
117
|
throw new Error(`Headed mode is unsupported for ${browser}`);
|
|
96
118
|
}
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
const lower = filename.toLowerCase();
|
|
119
|
+
if (command === 'screenshot' && parsed.filename !== undefined) {
|
|
120
|
+
const lower = parsed.filename.toLowerCase();
|
|
100
121
|
if (lower.endsWith('.jpg') || lower.endsWith('.jpeg'))
|
|
101
|
-
imageType = 'jpeg';
|
|
122
|
+
parsed.imageType = 'jpeg';
|
|
102
123
|
else if (!lower.endsWith('.png'))
|
|
103
124
|
throw new Error('Unsupported screenshot extension; use png or jpeg');
|
|
104
125
|
}
|
|
105
|
-
const url = command === 'open' || command === 'goto' || command === 'tab-new' ? positional[
|
|
126
|
+
const url = command === 'open' || command === 'goto' || command === 'tab-new' ? positional[0] : undefined;
|
|
106
127
|
if (url !== undefined) {
|
|
107
|
-
const
|
|
108
|
-
if (
|
|
128
|
+
const parsedUrl = new URL(url);
|
|
129
|
+
if (parsedUrl.protocol !== 'https:' && parsedUrl.protocol !== 'http:' && url !== 'about:blank')
|
|
109
130
|
throw new Error('Unsupported navigation URL');
|
|
131
|
+
parsed.url = url;
|
|
132
|
+
}
|
|
133
|
+
if (command === 'click' || command === 'fill') {
|
|
134
|
+
const ref = positional[0];
|
|
135
|
+
if (ref[0] !== 'e' || ref.length < 2 || [...ref.slice(1)].some(char => !'0123456789'.includes(char)))
|
|
136
|
+
throw new Error('Action requires a snapshot ref');
|
|
137
|
+
parsed.ref = ref;
|
|
138
|
+
}
|
|
139
|
+
if (command === 'fill')
|
|
140
|
+
parsed.value = positional[1];
|
|
141
|
+
if (command === 'press') {
|
|
142
|
+
if (!positional[0])
|
|
143
|
+
throw new Error('Missing press key');
|
|
144
|
+
parsed.value = positional[0];
|
|
145
|
+
}
|
|
146
|
+
const tabValue = command === 'tab-select' || command === 'tab-close' ? positional[0] : undefined;
|
|
147
|
+
if (tabValue !== undefined) {
|
|
148
|
+
const tab = Number(tabValue);
|
|
149
|
+
if (!tabValue || [...tabValue].some(char => !'0123456789'.includes(char)) || !Number.isSafeInteger(tab))
|
|
150
|
+
throw new Error('Invalid tab index');
|
|
151
|
+
parsed.tab = tab;
|
|
110
152
|
}
|
|
111
|
-
|
|
112
|
-
if (ref !== undefined && (ref[0] !== 'e' || ref.length < 2 || [...ref.slice(1)].some(char => !'0123456789'.includes(char))))
|
|
113
|
-
throw new Error('Action requires a snapshot ref');
|
|
114
|
-
const value = command === 'fill' ? positional[2] : command === 'press' ? positional[1] : undefined;
|
|
115
|
-
if (command === 'press' && !value)
|
|
116
|
-
throw new Error('Missing press key');
|
|
117
|
-
const tabValue = command === 'tab-select' || command === 'tab-close' ? positional[1] : undefined;
|
|
118
|
-
const tab = tabValue === undefined ? undefined : Number(tabValue);
|
|
119
|
-
if (tabValue !== undefined && (!tabValue || [...tabValue].some(char => !'0123456789'.includes(char)) || !Number.isSafeInteger(tab)))
|
|
120
|
-
throw new Error('Invalid tab index');
|
|
121
|
-
return { command, session, browser, headless, fullPage, imageType, ...(url === undefined ? {} : { url }), ...(ref === undefined ? {} : { ref }), ...(value === undefined ? {} : { value }), ...(tab === undefined ? {} : { tab }), ...(filename === undefined ? {} : { filename }) };
|
|
153
|
+
return parsed;
|
|
122
154
|
}
|
|
123
155
|
//# sourceMappingURL=invocation.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"invocation.js","sourceRoot":"","sources":["../../src/playwright/invocation.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,
|
|
1
|
+
{"version":3,"file":"invocation.js","sourceRoot":"","sources":["../../src/playwright/invocation.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,wBAAwB,EAA0B,MAAM,cAAc,CAAC;AA6BhF,MAAM,UAAU,eAAe,CAAC,UAAgC,EAAE,SAAsE,EAAE,OAA2B;IACnK,MAAM,UAAU,GAAa,EAAE,CAAC;IAChC,MAAM,QAAQ,GAAG,IAAI,GAAG,EAAgC,CAAC;IACzD,MAAM,YAAY,GAAG,IAAI,GAAG,CAAC,MAAM,CAAC,MAAM,CAAC,wBAAwB,CAAC,CAAC,OAAO,CAAC,OAAO,CAAC,EAAE,CAAC,MAAM,CAAC,OAAO,CAAC,OAAO,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC;IAC1H,YAAY,CAAC,GAAG,CAAC,UAAU,EAAE,EAAE,IAAI,EAAE,SAAS,EAAE,WAAW,EAAE,EAAE,EAAE,CAAC,CAAC;IACnE,YAAY,CAAC,GAAG,CAAC,SAAS,EAAE,EAAE,IAAI,EAAE,QAAQ,EAAE,WAAW,EAAE,EAAE,EAAE,CAAC,CAAC;IACjE,IAAI,IAAI,GAAG,KAAK,CAAC;IACjB,IAAI,OAAO,GAAG,KAAK,CAAC;IACpB,KAAK,IAAI,KAAK,GAAG,CAAC,EAAE,KAAK,GAAG,UAAU,CAAC,IAAI,CAAC,MAAM,EAAE,KAAK,EAAE,EAAE,CAAC;QAC5D,MAAM,GAAG,GAAG,UAAU,CAAC,IAAI,CAAC,KAAK,CAAE,CAAC;QACpC,IAAI,OAAO,GAAG,KAAK,QAAQ,IAAI,GAAG,CAAC,QAAQ,CAAC,IAAI,CAAC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,CAAC;QAC7B,IAAI,CAAC,QAAQ,IAAI,CAAC,GAAG,QAAQ,CAAC,CAAC,IAAI,CAAC,IAAI,CAAC,EAAE,CAAC,CAAC,YAAY,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC,IAAI,CAAC,MAAM,CAAC,aAAa,CAAC,GAAG,CAAC;YAAE,MAAM,IAAI,KAAK,CAAC,mBAAmB,CAAC,CAAC;QAC9I,MAAM,CAAC,GAAG,GAAG,GAAG,CAAC;IACnB,CAAC;IACD,OAAO,MAAM,CAAC;AAChB,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@poe-platform/safe-bash",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.642",
|
|
4
4
|
"description": "Extensible virtual shell with pluggable filesystems and streaming commands",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -356,7 +356,7 @@
|
|
|
356
356
|
"access": "public"
|
|
357
357
|
},
|
|
358
358
|
"dependencies": {
|
|
359
|
-
"@poe-platform/safe-fs": "0.1.
|
|
359
|
+
"@poe-platform/safe-fs": "0.1.642",
|
|
360
360
|
"pako": "3.0.1",
|
|
361
361
|
"@noble/hashes": "2.4.0",
|
|
362
362
|
"@types/node": "^25.2.2",
|