pi-studio 0.11.14 → 0.11.15

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
@@ -4,6 +4,11 @@ All notable changes to `pi-studio` are documented here.
4
4
 
5
5
  ## [Unreleased]
6
6
 
7
+ ## [0.11.15] — 2026-11-11
8
+
9
+ ### Fixed
10
+ - A Python cell's record and result no longer start with the `exec(open(…))` line Studio types to run it when IPython 9 or Python's own REPL wraps that line across rows, as they do in a pane narrower than the line. IPython 9 starts each further row with `⋮`, and Python 3.13 and later end each full row with `\`. Studio recognised only IPython 8's `...:`. pi-repl 0.12.2 makes the same fix.
11
+
7
12
  ## [0.11.14] — 2026-11-11
8
13
 
9
14
  ### Changed
package/ROADMAP.md CHANGED
@@ -4,7 +4,7 @@ This is the current planning source of truth for Studio work. `NEXT-STAGE.md` is
4
4
 
5
5
  ## Current status (11 Nov 2026)
6
6
 
7
- `0.11.14` is the current release. Studio is in a feature freeze from `0.11.9`, for use in normal work. Before the freeze, `0.11.9` added the images and PDFs a REPL entry's code saved, shown under the entry, and a PDF header that fits on one line. Each release since has been an approved exception. `0.11.10` works with pi-repl `0.12.1` so that, with both loaded, the agent is told each REPL record entry once. `0.11.11` gets Studio's URL out of a terminal too narrow to show it: `/studio --copy-url` copies it, and `PI_STUDIO_URL_FILE` keeps it in a file for programs ([#7](https://github.com/omaclaren/pi-studio/issues/7)). `0.11.12` makes **Follow** one switch, fixes two WebKit scrolling glitches in Muxy, and lines Working's sections up under their step. `0.11.13` gives Studio's tabs ASCII titles, working around a crash in Muxy 2.3.0's browser on the ellipsis in Studio's title. `0.11.14` lets **Suggest** offer a next prompt when Pi's last reply asks you a question, as pi-next now does. During the freeze, changes are limited to fixes for failures in normal use, lost data, effects on other people's processes or files, and security. [TODO.md](TODO.md) lists the known limits and what comes after the freeze.
7
+ `0.11.15` is the current release. Studio is in a feature freeze from `0.11.9`, for use in normal work. Before the freeze, `0.11.9` added the images and PDFs a REPL entry's code saved, shown under the entry, and a PDF header that fits on one line. Each release since has been an approved exception. `0.11.10` works with pi-repl `0.12.1` so that, with both loaded, the agent is told each REPL record entry once. `0.11.11` gets Studio's URL out of a terminal too narrow to show it: `/studio --copy-url` copies it, and `PI_STUDIO_URL_FILE` keeps it in a file for programs ([#7](https://github.com/omaclaren/pi-studio/issues/7)). `0.11.12` makes **Follow** one switch, fixes two WebKit scrolling glitches in Muxy, and lines Working's sections up under their step. `0.11.13` gives Studio's tabs ASCII titles, working around a crash in Muxy 2.3.0's browser on the ellipsis in Studio's title. `0.11.14` lets **Suggest** offer a next prompt when Pi's last reply asks you a question, as pi-next now does. `0.11.15` keeps the line Studio types to run a Python cell out of the cell's record when IPython 9 or Python's own REPL wraps it. During the freeze, changes are limited to fixes for failures in normal use, lost data, effects on other people's processes or files, and security. [TODO.md](TODO.md) lists the known limits and what comes after the freeze.
8
8
 
9
9
  `0.10.0` (14 Oct) made the buffer-first workspace the default, as **dual editor mode** (Prompt and Document), with **single editor mode** one switch away (footer button, `/studio --single`). It went through real course use as private alpha candidates 49–69. The `PI_STUDIO_*` flags described further down are development overrides only: when any is set it decides, and the mode switch is hidden.
10
10
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pi-studio",
3
- "version": "0.11.14",
3
+ "version": "0.11.15",
4
4
  "description": "Two-pane browser workspace for pi with prompt/response editing, annotations, critiques, active quiz, prompt/response history, live previews, and tmux-backed REPL/literate REPL workflows",
5
5
  "type": "module",
6
6
  "license": "MIT",
@@ -211,7 +211,9 @@ const compact = (text) => text.replace(/\s+/g, "");
211
211
  /**
212
212
  * Remove this submission's loader echo from the start of the lines, once. The
213
213
  * loader names a private file with a random token, so only this submission's
214
- * echo matches. IPython can wrap a long echo onto "...:" continuation rows.
214
+ * echo matches. A runtime's line editor can wrap a long echo itself, so tmux's
215
+ * -J can't rejoin the rows: IPython 8 starts each further row with "...:",
216
+ * IPython 9 with "⋮", and Python 3.13's REPL ends each full row with "\".
215
217
  *
216
218
  * @param {string[]} lines
217
219
  * @param {string} submissionLine
@@ -237,21 +239,28 @@ function removeLoaderEcho(lines, submissionLine, anyPrefix, scoped = null) {
237
239
  if (first.length > 2048) return false;
238
240
  const want = compact(submissionLine);
239
241
  const head = compact(submissionLine.slice(0, 12));
242
+ // Add a row's text, without a "\" wrap mark where the loader has none.
243
+ const extend = (/** @type {string} */ joined, /** @type {string} */ row) => {
244
+ const piece = compact(row);
245
+ if (want.startsWith(joined + piece)) return joined + piece;
246
+ if (piece.endsWith("\\") && want.startsWith(joined + piece.slice(0, -1))) return joined + piece.slice(0, -1);
247
+ return undefined;
248
+ };
240
249
  for (let start = 0; start < first.length; start += 1) {
241
- const piece = compact(first.slice(start));
242
- if (!piece.startsWith(head) || !want.startsWith(piece) || !prefixOk(start)) continue;
243
- if (piece === want) {
250
+ if (!compact(first.slice(start)).startsWith(head) || !prefixOk(start)) continue;
251
+ let joined = extend("", first.slice(start));
252
+ if (joined === undefined) continue;
253
+ if (joined === want) {
244
254
  lines.shift();
245
255
  return true;
246
256
  }
247
- let joined = piece;
248
257
  for (let row = 1; row < Math.min(lines.length, 8); row += 1) {
249
- joined += compact((lines[row] ?? "").replace(/^\s*\.\.\.:?/, ""));
258
+ joined = extend(joined, (lines[row] ?? "").replace(/^\s*(?:\.\.\.:?|⋮)/, ""));
259
+ if (joined === undefined) return false;
250
260
  if (joined === want) {
251
261
  lines.splice(0, row + 1);
252
262
  return true;
253
263
  }
254
- if (!want.startsWith(joined)) return false;
255
264
  }
256
265
  return false;
257
266
  }