@deeeed/metamask-harness 0.59.0 → 0.61.0
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/CHANGELOG.md +31 -0
- package/README.md +48 -0
- package/adapters/extension/build-handoff.cjs +4 -0
- package/adapters/extension/live.sh +15 -11
- package/adapters/extension/pin-remote-flags.cjs +69 -30
- package/adapters/mobile/bridge-runtime/cdp-bridge.cjs +16 -0
- package/adapters/mobile/bridge-runtime/setup-wallet.sh +69 -2
- package/dist/adapters/extension/feature-flags.js +41 -0
- package/dist/adapters/extension/runtime-decision.js +1 -0
- package/dist/adapters/mobile/feature-flags.js +127 -0
- package/dist/adapters.js +6 -1
- package/dist/command-contract.js +6 -3
- package/dist/commands/doctor.js +9 -1
- package/dist/commands/fixtures.js +45 -3
- package/dist/commands/launch/extension.js +28 -6
- package/dist/commands/launch/index.js +128 -17
- package/dist/commands/launch/mobile.js +26 -2
- package/dist/commands/mobile-device-view.js +8 -1
- package/dist/commands/prepare.js +20 -3
- package/dist/commands/run-engine.js +10 -1
- package/dist/commands/runtime-launch.js +10 -1
- package/dist/commands/status-probe.js +14 -1
- package/dist/commands/status-watch.js +32 -0
- package/dist/commands/status.js +13 -0
- package/dist/doctor.js +9 -1
- package/dist/feature-flags.js +193 -0
- package/dist/mm-harness-cli.js +15 -2
- package/dist/task-view.js +34 -1
- package/library/actions/core/feature_flags/_unsupported.mjs +29 -0
- package/library/actions/core/feature_flags/clear.mjs +8 -0
- package/library/actions/core/feature_flags/read.mjs +8 -0
- package/library/actions/core/feature_flags/set.mjs +8 -0
- package/library/actions/extension/feature_flags/clear.mjs +48 -0
- package/library/actions/extension/feature_flags/read.mjs +27 -0
- package/library/actions/extension/feature_flags/set.mjs +36 -0
- package/library/actions/extension/feature_flags/state.mjs +129 -0
- package/library/actions/harness-exports.mjs +14 -0
- package/library/actions/mobile/feature_flags/clear.mjs +20 -0
- package/library/actions/mobile/feature_flags/controller.mjs +120 -0
- package/library/actions/mobile/feature_flags/read.mjs +20 -0
- package/library/actions/mobile/feature_flags/set.mjs +25 -0
- package/library/actions/mobile/platform/bridge.mjs +2 -2
- package/library/actions/mobile/wallet/reset.mjs +22 -1
- package/library/manifests/core.action-manifest.json +90 -0
- package/library/manifests/extension.action-manifest.json +70 -0
- package/library/manifests/mobile.action-manifest.json +90 -0
- package/package.json +5 -5
|
@@ -1,6 +1,96 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://farmslot.io/schemas/action-manifest-v1.schema.json",
|
|
3
3
|
"actions": {
|
|
4
|
+
"metamask.feature_flags.set": {
|
|
5
|
+
"description": "Pin remote feature-flag overrides on the running app and read them back. Overrides persist and win over every later remote refetch.",
|
|
6
|
+
"schema": {
|
|
7
|
+
"type": "object",
|
|
8
|
+
"properties": {
|
|
9
|
+
"flags": {
|
|
10
|
+
"type": "object",
|
|
11
|
+
"description": "Flag key to value. A bare word is a named A/B variant (\"treatment\" becomes { \"name\": \"treatment\" }); true/false is a boolean; an object or array is used as authored."
|
|
12
|
+
},
|
|
13
|
+
"controller_ready_timeout_ms": {
|
|
14
|
+
"type": "number",
|
|
15
|
+
"minimum": 1,
|
|
16
|
+
"description": "Maximum time in milliseconds to wait for the app runtime to accept the override."
|
|
17
|
+
}
|
|
18
|
+
},
|
|
19
|
+
"required": [
|
|
20
|
+
"flags"
|
|
21
|
+
],
|
|
22
|
+
"additionalProperties": false
|
|
23
|
+
},
|
|
24
|
+
"examples": [
|
|
25
|
+
{
|
|
26
|
+
"action": "metamask.feature_flags.set",
|
|
27
|
+
"flags": {
|
|
28
|
+
"perpsTAT3938AbtestScreenVsBottomSheet": "treatment"
|
|
29
|
+
},
|
|
30
|
+
"intent": "Pin the A/B variant the proof runs under",
|
|
31
|
+
"next": "done"
|
|
32
|
+
}
|
|
33
|
+
],
|
|
34
|
+
"execution_capabilities": [
|
|
35
|
+
"app-mutation"
|
|
36
|
+
]
|
|
37
|
+
},
|
|
38
|
+
"metamask.feature_flags.read": {
|
|
39
|
+
"description": "Read the effective remote feature flags and the local overrides from the running app.",
|
|
40
|
+
"schema": {
|
|
41
|
+
"type": "object",
|
|
42
|
+
"properties": {
|
|
43
|
+
"keys": {
|
|
44
|
+
"type": "array",
|
|
45
|
+
"items": {
|
|
46
|
+
"type": "string"
|
|
47
|
+
},
|
|
48
|
+
"description": "Restrict the reported flags to these keys. Omit to report every flag."
|
|
49
|
+
},
|
|
50
|
+
"controller_ready_timeout_ms": {
|
|
51
|
+
"type": "number",
|
|
52
|
+
"minimum": 1,
|
|
53
|
+
"description": "Maximum time in milliseconds to wait for the app runtime to answer."
|
|
54
|
+
}
|
|
55
|
+
},
|
|
56
|
+
"additionalProperties": false
|
|
57
|
+
},
|
|
58
|
+
"examples": [
|
|
59
|
+
{
|
|
60
|
+
"action": "metamask.feature_flags.read",
|
|
61
|
+
"keys": [
|
|
62
|
+
"perpsTAT3938AbtestScreenVsBottomSheet"
|
|
63
|
+
],
|
|
64
|
+
"intent": "Record the A/B variant the proof ran under",
|
|
65
|
+
"next": "done"
|
|
66
|
+
}
|
|
67
|
+
],
|
|
68
|
+
"execution_capabilities": []
|
|
69
|
+
},
|
|
70
|
+
"metamask.feature_flags.clear": {
|
|
71
|
+
"description": "Drop every local remote feature-flag override so the slot leaks no variant into the next run.",
|
|
72
|
+
"schema": {
|
|
73
|
+
"type": "object",
|
|
74
|
+
"properties": {
|
|
75
|
+
"controller_ready_timeout_ms": {
|
|
76
|
+
"type": "number",
|
|
77
|
+
"minimum": 1,
|
|
78
|
+
"description": "Maximum time in milliseconds to wait for the app runtime to answer."
|
|
79
|
+
}
|
|
80
|
+
},
|
|
81
|
+
"additionalProperties": false
|
|
82
|
+
},
|
|
83
|
+
"examples": [
|
|
84
|
+
{
|
|
85
|
+
"action": "metamask.feature_flags.clear",
|
|
86
|
+
"intent": "Drop the pinned variant before the next run",
|
|
87
|
+
"next": "done"
|
|
88
|
+
}
|
|
89
|
+
],
|
|
90
|
+
"execution_capabilities": [
|
|
91
|
+
"app-mutation"
|
|
92
|
+
]
|
|
93
|
+
},
|
|
4
94
|
"command": {
|
|
5
95
|
"description": "Run a shell command from the project root.",
|
|
6
96
|
"examples": [
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@deeeed/metamask-harness",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.61.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"bin": {
|
|
6
6
|
"mm-harness": "bin/mm-harness"
|
|
@@ -20,11 +20,11 @@
|
|
|
20
20
|
"check:syntax": "find . -name '*.mjs' -print0 | xargs -0 -n1 node --check"
|
|
21
21
|
},
|
|
22
22
|
"dependencies": {
|
|
23
|
-
"@farmslot/agent-runtime": "0.
|
|
24
|
-
"@farmslot/expo-recipe": "0.
|
|
23
|
+
"@farmslot/agent-runtime": "0.13.0",
|
|
24
|
+
"@farmslot/expo-recipe": "0.11.0",
|
|
25
25
|
"@farmslot/handoff": "^0.3.1",
|
|
26
|
-
"@farmslot/protocol": "0.
|
|
27
|
-
"@farmslot/recipe-harness": "0.
|
|
26
|
+
"@farmslot/protocol": "0.30.0",
|
|
27
|
+
"@farmslot/recipe-harness": "0.18.0",
|
|
28
28
|
"agent-device": "0.19.3",
|
|
29
29
|
"commander": "^12.0.0",
|
|
30
30
|
"es-module-lexer": "2.3.1",
|