@oh-my-pi/pi-coding-agent 14.9.7 → 14.9.8

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 CHANGED
@@ -1,22 +1,39 @@
1
1
  # Changelog
2
2
 
3
3
  ## [Unreleased]
4
+
5
+ ## [14.9.8] - 2026-05-12
6
+
4
7
  ### Breaking Changes
5
8
 
6
9
  - Changed the `eval` tool input format to a single-line `*** Cell <lang>:"<title>" [t:<duration>] [rst]` header per cell, replacing the `*** Begin <LANG>` / `*** End <LANG>` envelope and the standalone `*** Title:` / `*** Timeout:` / `*** Reset` directives. The lark grammar enforces a fixed attribute order; the runtime parser remains lenient (alias keys, bare positional tokens, single-quoted titles).
7
10
 
8
11
  ### Added
9
12
 
13
+ - Added `:conflicts` read selector (`read <path>:conflicts`) to return a one-line index of all unresolved merge conflicts with stable `#N` IDs for quick inspection
14
+ - Added bulk conflict resolution with `write({ path: "conflict://*", content })` to resolve all currently registered conflicts across files in one call, expanding `@ours`/`@theirs`/`@base`/`@both` per conflict and returning per-file counts
15
+ - Added `read` support for `conflict://<N>` and `read conflict://<N>/<scope>` to inspect unresolved conflict regions captured by a prior read, including `ours`, `theirs`, and `base` side views with original file line alignment
16
+ - Added shorthand content tokens `@ours`, `@theirs`, `@both`, and `@base` to conflict-resolution writes using `path: "conflict://<N>"` so replacement content can be composed from recorded conflict sections
17
+ - Added conflict count metadata to read results so conflict files now show a warning badge (`⚠ N`) in the read tool UI
10
18
  - Added support for explicit boolean `rst` values (`rst:true`, `rst:false`, `rst:1`, `rst:0`, `rst:yes`, `rst:no`, `rst:on`, `rst:off`) in `*** Cell` headers
19
+ - Added detection of unresolved git merge conflicts in `read` output: each marker block is registered with a session-stable id and surfaced in a footer with `ours`/`theirs` previews. Resolve a block by calling `write({ path: "conflict://<id>", content })` — the tool splices the recorded marker region (markers and all sides) with the supplied content and routes through the normal writethrough (LSP format/diagnostics, fs-cache invalidation).
11
20
 
12
21
  ### Changed
13
22
 
23
+ - Changed `read` conflict warning footers to show `X of Y` unresolved conflicts when a range only captures part of a file and provide a `read <path>:conflicts` hint for the full list
24
+ - Changed conflict scanning in conflict read paths to inspect the whole file (with a 10 MB cap) so totals better reflect hidden conflicts and truncated scans are called out
25
+ - Changed conflict marker scanning during `read` to only register fully formed, column-0 merge-marker blocks, so indented or malformed marker-like lines are no longer treated as conflicts
26
+ - Changed `write` conflict resolution to validate `conflict://` IDs and report clear errors for malformed or unknown conflict URIs
14
27
  - Changed the HTML transcript renderer to parse the new `*** Cell` headers while keeping the older `*** Begin <LANG>` and `===== ... =====` formats renderable for historical sessions.
15
28
  - Changed the `eval` tool parser so a stray non-marker line between cells no longer crashes with `null is not an object (evaluating 'BEGIN_RE.exec(lines[i])[1]')`; stray content is consumed without aborting parsing.
16
29
  - Changed `*** End` to be an optional, undocumented per-cell terminator (kept in the lark to satisfy GPT-trained models' natural terminator habit during constrained sampling).
17
30
 
18
31
  ### Fixed
19
32
 
33
+ - Fixed single-conflict `write` retries to re-locate the recorded conflict block by exact marker content so shifted line numbers from out-of-band edits no longer prevent resolution
34
+ - Fixed `read conflict://*` handling by rejecting wildcard reads with a clear write-only guidance error
35
+ - Fixed conflict resolution to verify the live file still contains recorded `<<<<<<<` and `>>>>>>>` markers before splicing, preventing stale conflict IDs from silently corrupting out-of-band-edited files
36
+ - Fixed `@base` token handling so two-way conflicts without a base section now return a clear error
20
37
  - Improved `*** Cell` header parsing to reject invalid `rst` values with a clear `invalid rst value` error
21
38
 
22
39
  ## [14.9.7] - 2026-05-12
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "type": "module",
3
3
  "name": "@oh-my-pi/pi-coding-agent",
4
- "version": "14.9.7",
4
+ "version": "14.9.8",
5
5
  "description": "Coding agent CLI with read, bash, edit, write tools and session management",
6
6
  "homepage": "https://github.com/can1357/oh-my-pi",
7
7
  "author": "Can Boluk",
@@ -47,12 +47,12 @@
47
47
  "@agentclientprotocol/sdk": "0.21.0",
48
48
  "@babel/parser": "^7.29.3",
49
49
  "@mozilla/readability": "^0.6.0",
50
- "@oh-my-pi/omp-stats": "14.9.7",
51
- "@oh-my-pi/pi-agent-core": "14.9.7",
52
- "@oh-my-pi/pi-ai": "14.9.7",
53
- "@oh-my-pi/pi-natives": "14.9.7",
54
- "@oh-my-pi/pi-tui": "14.9.7",
55
- "@oh-my-pi/pi-utils": "14.9.7",
50
+ "@oh-my-pi/omp-stats": "14.9.8",
51
+ "@oh-my-pi/pi-agent-core": "14.9.8",
52
+ "@oh-my-pi/pi-ai": "14.9.8",
53
+ "@oh-my-pi/pi-natives": "14.9.8",
54
+ "@oh-my-pi/pi-tui": "14.9.8",
55
+ "@oh-my-pi/pi-utils": "14.9.8",
56
56
  "@puppeteer/browsers": "^2.13.0",
57
57
  "@sinclair/typebox": "^0.34.49",
58
58
  "@types/turndown": "5.0.6",
@@ -18,10 +18,11 @@ const minifiedCss = css
18
18
  .replace(/\s*([{}:;,])\s*/g, "$1")
19
19
  .trim();
20
20
 
21
- // Inline everything
21
+ // Inline everything; use function replacements so `$'`, `$&`, `$$`, etc. inside
22
+ // the embedded CSS/JS are not interpreted as substitution patterns.
22
23
  const template = html
23
- .replace("<template-css/>", `<style>${minifiedCss}</style>`)
24
- .replace("<template-js/>", `<script>${js}</script>`);
24
+ .replace("<template-css/>", () => `<style>${minifiedCss}</style>`)
25
+ .replace("<template-js/>", () => `<script>${js}</script>`);
25
26
 
26
27
  // Write generated file
27
28
  const output = `// Auto-generated by scripts/generate-template.ts - DO NOT EDIT
@@ -103,9 +103,12 @@ async function generateHtml(sessionData: SessionData, themeName?: string): Promi
103
103
  const themeVars = await generateThemeVars(themeName);
104
104
  const sessionDataBase64 = Buffer.from(JSON.stringify(sessionData)).toBase64();
105
105
 
106
- return TEMPLATE.replace("<theme-vars/>", `<style>:root { ${themeVars} }</style>`).replace(
106
+ // Use function replacements so `$'`, `$&`, `$$`, `$n`, etc. in the
107
+ // substituted CSS/base64 are not interpreted as substitution patterns
108
+ // (see https://mdn.io/String.replace).
109
+ return TEMPLATE.replace("<theme-vars/>", () => `<style>:root { ${themeVars} }</style>`).replace(
107
110
  "{{SESSION_DATA}}",
108
- sessionDataBase64,
111
+ () => sessionDataBase64,
109
112
  );
110
113
  }
111
114