@farmslot/adapter-web 0.17.3 → 0.17.4
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 +5 -0
- package/package.json +3 -3
- package/src/performance-observer.cjs +11 -8
package/CHANGELOG.md
CHANGED
|
@@ -6,6 +6,11 @@ All notable changes to `@farmslot/adapter-web` are tracked here.
|
|
|
6
6
|
|
|
7
7
|
- Active-development baseline; add user-facing changes here before release or package publication.
|
|
8
8
|
|
|
9
|
+
## 0.17.4 - 2026-11-02
|
|
10
|
+
|
|
11
|
+
- Clock-marker midpoint sync comes from `@farmslot/recipe-runner` 0.46.4's shared helper; no behaviour change.
|
|
12
|
+
- Align `@farmslot/recipe-runner` 0.46.4 and `@farmslot/adapter-sdk` 0.26.1.
|
|
13
|
+
|
|
9
14
|
## 0.17.3 - 2026-11-02
|
|
10
15
|
|
|
11
16
|
- Align `@farmslot/recipe-runner` 0.46.3, `@farmslot/adapter-sdk` 0.26.0 and `@farmslot/protocol` 0.74.10.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@farmslot/adapter-web",
|
|
3
|
-
"version": "0.17.
|
|
3
|
+
"version": "0.17.4",
|
|
4
4
|
"description": "Web platform adapter for Farmslot recipes: resolve and launch an isolated Chromium, own its CDP port, load unpacked extensions, and keep macOS focus.",
|
|
5
5
|
"type": "commonjs",
|
|
6
6
|
"exports": {
|
|
@@ -83,9 +83,9 @@
|
|
|
83
83
|
"prepublishOnly": "node ../../scripts/quality/check-farmslot-package-readiness.mjs --publish --packages @farmslot/adapter-web"
|
|
84
84
|
},
|
|
85
85
|
"dependencies": {
|
|
86
|
-
"@farmslot/adapter-sdk": "0.26.
|
|
86
|
+
"@farmslot/adapter-sdk": "0.26.1",
|
|
87
87
|
"@farmslot/protocol": "0.74.10",
|
|
88
|
-
"@farmslot/recipe-runner": "0.46.
|
|
88
|
+
"@farmslot/recipe-runner": "0.46.4",
|
|
89
89
|
"ws": "^8.18.0"
|
|
90
90
|
},
|
|
91
91
|
"devDependencies": {
|
|
@@ -40,7 +40,10 @@ async function createExtensionPerformanceBackend({
|
|
|
40
40
|
}
|
|
41
41
|
// Loaded on use: recipe-runner's trace engine is an ES module built to dist,
|
|
42
42
|
// and the other adapter-web modules must load without it.
|
|
43
|
-
const {
|
|
43
|
+
const {
|
|
44
|
+
clockMidpoint,
|
|
45
|
+
createCdpTraceCollector,
|
|
46
|
+
} = require('@farmslot/recipe-runner/runtime/cdp-trace');
|
|
44
47
|
const browser = await connectBrowserCdp(cdpPort, {
|
|
45
48
|
timeoutMs: connectTimeoutMs,
|
|
46
49
|
commandTimeoutMs,
|
|
@@ -79,14 +82,14 @@ async function createExtensionPerformanceBackend({
|
|
|
79
82
|
platform,
|
|
80
83
|
markerPrefix,
|
|
81
84
|
marker: async (name) => {
|
|
82
|
-
const
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
85
|
+
const { hostEpochMs, uncertaintyMs } = await clockMidpoint(() =>
|
|
86
|
+
browser.send(
|
|
87
|
+
'Runtime.evaluate',
|
|
88
|
+
{ expression: `performance.mark(${JSON.stringify(name)})`, returnByValue: true },
|
|
89
|
+
sessionId,
|
|
90
|
+
),
|
|
87
91
|
);
|
|
88
|
-
|
|
89
|
-
return { hostEpochMs: (before + after) / 2, uncertaintyMs: (after - before) / 2 };
|
|
92
|
+
return { hostEpochMs, uncertaintyMs };
|
|
90
93
|
},
|
|
91
94
|
});
|
|
92
95
|
}
|