@mjasnikovs/pi-task 0.18.16 → 0.18.17
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.
|
@@ -94,7 +94,10 @@ export function keepGroundedScripts(names, sourceDoc) {
|
|
|
94
94
|
export function enumerateScriptCandidates(sourceDoc) {
|
|
95
95
|
const out = [];
|
|
96
96
|
const seen = new Set();
|
|
97
|
-
|
|
97
|
+
// Normalise CRLF/CR → LF first: a Windows-authored design would otherwise
|
|
98
|
+
// collapse into one paragraph (the split marker never matches `\r\n\r\n`),
|
|
99
|
+
// caps out on early package-name backticks, and drops the real scripts.
|
|
100
|
+
for (const para of sourceDoc.replace(/\r\n?/g, '\n').split(/\n[ \t]*\n/)) {
|
|
98
101
|
if (!/\bscripts?\b/i.test(para))
|
|
99
102
|
continue;
|
|
100
103
|
for (const m of para.matchAll(/`([^`\n]+)`/g)) {
|
|
@@ -8,6 +8,16 @@ export type RenderOutcome = {
|
|
|
8
8
|
outcome: 'skip';
|
|
9
9
|
note: string;
|
|
10
10
|
};
|
|
11
|
+
/**
|
|
12
|
+
* The newest Playwright-cache Chromium, if any — the HEADLESS SHELL preferred over
|
|
13
|
+
* the full build. Found, never installed: the cache exists on any box that ever ran
|
|
14
|
+
* Playwright browsers (the mx5-class projects install it as their own test
|
|
15
|
+
* dependency). The headless shell is purpose-built for `--dump-dom` and returns
|
|
16
|
+
* promptly on a network URL where the full system chromium can stall under a
|
|
17
|
+
* virtual-time budget (validated live on this box: shell exits 0 in ~1s, full
|
|
18
|
+
* chromium times out at 30s on the same http:// URL).
|
|
19
|
+
*/
|
|
20
|
+
export declare function playwrightCachedChromium(): string | null;
|
|
11
21
|
/**
|
|
12
22
|
* A launchable Chrome-family binary, or null when this box has none: the explicit
|
|
13
23
|
* CHROME_BIN override first, then the Playwright cache (headless shell — reliable
|
|
@@ -52,7 +52,7 @@ function onPath(bin) {
|
|
|
52
52
|
* virtual-time budget (validated live on this box: shell exits 0 in ~1s, full
|
|
53
53
|
* chromium times out at 30s on the same http:// URL).
|
|
54
54
|
*/
|
|
55
|
-
function playwrightCachedChromium() {
|
|
55
|
+
export function playwrightCachedChromium() {
|
|
56
56
|
const cache = process.env.PLAYWRIGHT_BROWSERS_PATH
|
|
57
57
|
?? (process.platform === 'darwin' ?
|
|
58
58
|
path.join(os.homedir(), 'Library', 'Caches', 'ms-playwright')
|
|
@@ -109,7 +109,10 @@ export function capRequirements(entries, passages) {
|
|
|
109
109
|
*/
|
|
110
110
|
export function enumerateObligationPassages(doc) {
|
|
111
111
|
const out = [];
|
|
112
|
-
|
|
112
|
+
// Normalise CRLF/CR → LF: a Windows-authored spec would otherwise collapse
|
|
113
|
+
// into one giant paragraph (the split marker never matches `\r\n\r\n`) and
|
|
114
|
+
// the per-obligation recall floor would enumerate nothing.
|
|
115
|
+
for (const para of doc.replace(/\r\n?/g, '\n').split(/\n[ \t]*\n/)) {
|
|
113
116
|
const p = para.trim();
|
|
114
117
|
if (p.length < MIN_QUOTE_LENGTH)
|
|
115
118
|
continue;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mjasnikovs/pi-task",
|
|
3
|
-
"version": "0.18.
|
|
3
|
+
"version": "0.18.17",
|
|
4
4
|
"description": "Deterministic task planning and spec-orchestration for local models — crash-safe /task pipelines with verify/enforce gates, a real-time remote web view, and web/docs/fetch/worker subagent tools.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.js",
|