From b230356dee7c40c647728cfe56829f4a5d1a2388 Mon Sep 17 00:00:00 2001 From: NiJingzhe <1448976235@qq.com> Date: Thu, 15 Oct 2026 20:13:08 +0800 Subject: [PATCH] release: 2.2.5 Co-Authored-By: Claude Sonnet 5.5 --- CHANGELOG.md | 34 +++++++++++++++++++++++++ README.md | 20 +++++++++------ README.zh-CN.md | 17 ++++++++----- docs/skill/SKILL.md | 4 +-- docs/updates/2.2.5.md | 51 +++++++++++++++++++++++++++++++++++++ docs/updates/2.2.5.zh-CN.md | 41 +++++++++++++++++++++++++++++ pyproject.toml | 2 +- uv.lock | 2 +- 8 files changed, 152 insertions(+), 19 deletions(-) create mode 100644 docs/updates/2.2.5.md create mode 100644 docs/updates/2.2.5.zh-CN.md diff --git a/CHANGELOG.md b/CHANGELOG.md index 62d0994..45904ea 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,40 @@ user-facing notes live in [`docs/updates/`](docs/updates/) (English and ## Unreleased +## 2.2.5 — 2026-10-15 + +### Fixed + +- Editor: `sca cell` finds the editor through a container's proxy environment: the recorded + url is always the loopback (`--host 0.0.0.0` included), the health check and the editor + calls bypass `http_proxy`, and a record whose server does not answer is an error naming + the record and the url instead of a silent "no editor is running". A record whose pid is + gone reports the stale record and the remedy. A fallback to reading the file says so on + stderr. + +### Added + +- Run: `sca run --through N` runs the first N cells only (a stage, numbered the way the + editor numbers cells), `--no-product` runs a work-in-progress notebook that has no product + yet, and `--timeout SECONDS` fails a run that takes longer (off by default). +- Editor: a failing or blocked cell's report names its upstream cells (failing ones first), + with marimo's own dependency semantics. + +### Changed + +- Editor: `sca cell put/insert/run` report the console output and every cell left unhealthy + by the change, and the dependents a write made stale are run, not left stale. A write whose + rerun outlives the call says the edit was applied and names `sca cell ls` + (`SCA_EDITOR_CALL_TIMEOUT` raises the wait, default 300s). +- Inspect: printing a `BRepInspection` shows a one-line summary; the full record is + `to_dict()` / `.faces` / `.edges`. +- Runs are quieter: the cache loaders' degraded-state warnings no longer print at WARNING, + and the render paths switch VTK's warning display off process-wide (this also hides VTK + chatter from code run in the same process); a real failure is still raised and named. +- Skill: while an editor runs, `sca cell` is the only way to change a regular cell; `dof=0` + says the constraint system closed, not that the shape is right (mirror solutions); modeling + projects are version-controlled with git. + ## 2.2.4 — 2026-10-15 ### Fixed diff --git a/README.md b/README.md index a3ca357..35adeac 100644 --- a/README.md +++ b/README.md @@ -149,18 +149,21 @@ the full crank cycle sweeps clean in the same sim · --- -## Update Notes (2.2.4) +## Update Notes (2.2.5) > Validate generated definitions, assembly constraints, and manufacturing > geometry before production use. -- **The editor tells you why no model is coming.** A failed build is reported on every run you or - an agent asks for (rerun, `sca cell`, a file change, a module reload), and to a page that opens - or refreshes afterwards — the "building the model" veil lifts with the reason instead of - waiting out its fallback. -- **The header's jump-to-marimo button is gone.** +- **`sca cell` works behind container proxies.** The editor's discovery record is loopback and + proxy-proof, an unreachable record is reported instead of silently ignored, and file + fallbacks say so on stderr. +- **Cell feedback carries the chain.** put/insert/run return console output and every cell + left unhealthy, stale dependents are run, and a failing cell names its upstream. +- **Validate a stage headlessly.** `sca run --through N / --no-product / --timeout`. +- **Quieter output, shorter prints.** Cache and VTK chatter is gone; a printed + `BRepInspection` is a one-line summary. -Full notes for this version: [`docs/updates/2.2.4.md`](docs/updates/2.2.4.md). +Full notes for this version: [`docs/updates/2.2.5.md`](docs/updates/2.2.5.md). Earlier versions: the [changelog](CHANGELOG.md) and [`docs/updates/`](docs/updates/). --- @@ -181,7 +184,7 @@ in a compact public API for creating solids, applying features, tagging semantic intent, querying topology, exporting manufacturing files, and translating recorded models into FreeCAD workflows. -Current release: `simplecadapi==2.2.4`. +Current release: `simplecadapi==2.2.5`. ## What It Provides @@ -696,6 +699,7 @@ and the [STEP reconstruction workflow](docs/skill/references/workflows/step-reco ## Documentation +- 2.2.5 update notes: [`docs/updates/2.2.5.md`](docs/updates/2.2.5.md) - 2.2.4 update notes: [`docs/updates/2.2.4.md`](docs/updates/2.2.4.md) - 2.2.3 update notes: [`docs/updates/2.2.3.md`](docs/updates/2.2.3.md) - 2.2.2 update notes: [`docs/updates/2.2.2.md`](docs/updates/2.2.2.md) diff --git a/README.zh-CN.md b/README.zh-CN.md index c882069..1c76f52 100644 --- a/README.zh-CN.md +++ b/README.zh-CN.md @@ -133,16 +133,18 @@ CalculiX 静力 FEM(边界面按保真的 `interface.*` 标签选取,仿真 --- -## 更新日志(2.2.4) +## 更新日志(2.2.5) > 投入生产前请验证生成的定义、装配约束和制造几何。 -- **编辑器会告诉你模型为什么没出来。** 你或 agent 主动发起的每次运行(重跑、`sca cell`、文件变更、 - 模块重载)失败都会重新报告,失败后打开或刷新的页面也会立刻拿到原因——"building the model" - 遮罩随原因揭开,不再等兜底超时。 -- **顶栏跳转 marimo 的按钮已移除。** +- **`sca cell` 在容器代理后面也能用。** 编辑器发现记录钉在回环地址并绕过代理,应答不了的记录会报出来 + 而不是被静默忽略,降级读文件会在 stderr 上说明。 +- **cell 反馈带着整条链。** put/insert/run 返回 console 输出和每个不健康的 cell,stale 依赖会被运行, + 出错 cell 会列出上游。 +- **按阶段做无头校验。** `sca run --through N / --no-product / --timeout`。 +- **更安静的输出、更短的打印。** 缓存与 VTK 噪声消失,打印 `BRepInspection` 是一行摘要。 -本版本的完整说明:[`docs/updates/2.2.4.zh-CN.md`](docs/updates/2.2.4.zh-CN.md)。 +本版本的完整说明:[`docs/updates/2.2.5.zh-CN.md`](docs/updates/2.2.5.zh-CN.md)。 更早的版本:见[更新日志](CHANGELOG.md)和 [`docs/updates/`](docs/updates/)。 --- @@ -160,7 +162,7 @@ CalculiX 静力 FEM(边界面按保真的 `interface.*` 标签选取,仿真 SimpleCADAPI 是一个基于 OCP 的 Python CAD SDK,提供清晰的函数式建模操作和可重放的模型图。它在 OpenCascade 几何内核之上提供精简的公共 API,可用于创建实体、应用特征、添加语义标签、查询拓扑、导出制造文件,以及将记录的模型转换为 FreeCAD 工作流。 -当前版本:`simplecadapi==2.2.4`。 +当前版本:`simplecadapi==2.2.5`。 ## 核心能力 @@ -586,6 +588,7 @@ uv run --extra fem python examples/ap242_gmsh_volume_mesh/run_calculix.py ## 文档 +- 2.2.5 更新说明:[`docs/updates/2.2.5.zh-CN.md`](docs/updates/2.2.5.zh-CN.md) - 2.2.4 更新说明:[`docs/updates/2.2.4.zh-CN.md`](docs/updates/2.2.4.zh-CN.md) - 2.2.3 更新说明:[`docs/updates/2.2.3.zh-CN.md`](docs/updates/2.2.3.zh-CN.md) - 2.2.2 更新说明:[`docs/updates/2.2.2.zh-CN.md`](docs/updates/2.2.2.zh-CN.md) diff --git a/docs/skill/SKILL.md b/docs/skill/SKILL.md index d6eeb57..b1798fe 100644 --- a/docs/skill/SKILL.md +++ b/docs/skill/SKILL.md @@ -4,9 +4,9 @@ description: Build, assemble, inspect, reconstruct, and export parametric CAD mo license: Apache-2.0 metadata: project: simplecadapi - version: 2.2.4 + version: 2.2.5 package-name: simplecadapi - package-version: 2.2.4 + package-version: 2.2.5 --- # SimpleCAD SDK Skill diff --git a/docs/updates/2.2.5.md b/docs/updates/2.2.5.md new file mode 100644 index 0000000..10f1e1b --- /dev/null +++ b/docs/updates/2.2.5.md @@ -0,0 +1,51 @@ +# 2.2.5 Update Notes + +From a container agent's field report: the editor now works the way agents actually use it, +and says what happened instead of leaving silence. + +## `sca cell` works behind container proxies + +Before, a container's `http_proxy` swallowed the editor's health check and `sca cell` +answered "no editor is running" while one was. Now the editor's discovery record always +carries a loopback url (`--host 0.0.0.0` included), the checks bypass the proxy environment, +and a record whose server does not answer is reported with its path and url instead of being +skipped quietly. A record whose pid is gone says "stale record … delete it or restart the +editor". When `sca cell ls`/`get` fall back to reading the file, they say so on stderr. + +## Cell feedback carries the chain + +`sca cell put/insert/run` now return the console output and every cell left unhealthy by the +change, and the dependents a write made stale are run instead of waiting. A failing cell's +report names its upstream cells (the failing ones first), so the error you see can be traced +to its cause. A write whose rerun takes longer than the call now answers "the edit was +applied and the rerun is still going; check `sca cell ls`" instead of a raw socket error +(`SCA_EDITOR_CALL_TIMEOUT` raises the wait, default 300s). + +## Validate a stage headlessly + +```bash +sca run stage.py --through 3 --no-product # the first 3 cells, no product needed +sca run stage.py --timeout 600 # a wall clock for heavy fillets +``` + +`--through N` runs the first N cells, numbered the way the editor numbers them; `--no-product` +runs a work-in-progress notebook that has no product yet; `--timeout` fails a run that takes +longer (off by default). + +## Quieter output, shorter prints + +The cache loaders' degraded-state warnings (unsigned entries, a value restored as a stub) no +longer print at WARNING, and the render paths switch VTK's warning display off process-wide — +this also hides VTK chatter from code you run in the same process. A real failure is still +raised and named. Printing a `BRepInspection` shows a one-line summary; the per-face records +are `to_dict()` / `.faces` / `.edges`. + +## Skill + +While an editor runs, `sca cell` is the only way to change a regular cell — the file only when +no editor runs, or for the setup / `@app.function` cells `sca cell` refuses. `dof=0` says the +constraint system closed, not that the shape is right (angle constraints can solve to the +mirror solution): verify by measurement. And a modeling project is managed like software: +git from the first file, commits at verified milestones. + +See the [changelog](../../CHANGELOG.md) for the complete list. diff --git a/docs/updates/2.2.5.zh-CN.md b/docs/updates/2.2.5.zh-CN.md new file mode 100644 index 0000000..d5a6f37 --- /dev/null +++ b/docs/updates/2.2.5.zh-CN.md @@ -0,0 +1,41 @@ +# 2.2.5 更新说明 + +来自容器 agent 的实战复盘:编辑器现在按 agent 真实的使用方式工作,并且把发生的事说出来,而不是留下沉默。 + +## `sca cell` 在容器代理后面也能找到编辑器 + +以前容器的 `http_proxy` 会吞掉编辑器的健康检查,`sca cell` 在编辑器明明运行时回答"no editor is running"。 +现在编辑器的发现记录始终携带回环地址(`--host 0.0.0.0` 也是),检查绕过代理环境,应答不了的服务器记录会带着 +路径和 url 报出来,而不是被悄悄跳过。pid 已消失的记录会说"stale record … delete it or restart the editor"。 +`sca cell ls`/`get` 降级读文件时会在 stderr 上说明。 + +## cell 反馈带着整条链 + +`sca cell put/insert/run` 现在返回 console 输出和这次修改留下的每一个不健康的 cell,写操作导致的 stale 依赖 +会被运行而不是晾着。出错 cell 的报告会列出它的上游 cell(先列出同样在报错的),让错误能追溯到根因。重跑超出 +调用时长的写操作现在回答"the edit was applied and the rerun is still going; check `sca cell ls`"而不是裸的 +socket 错误(`SCA_EDITOR_CALL_TIMEOUT` 可加大等待,默认 300 秒)。 + +## 按阶段做无头校验 + +```bash +sca run stage.py --through 3 --no-product # 只跑前 3 个 cell,不需要产品 +sca run stage.py --timeout 600 # 给重 fillet 一个墙上时钟 +``` + +`--through N` 只跑前 N 个 cell(按编辑器的编号方式计);`--no-product` 运行还没有产品的半成品 notebook; +`--timeout` 让超时的运行失败(默认不限时)。 + +## 更安静的输出、更短的打印 + +缓存加载器的降级警告(未签名的条目、以 stub 恢复的值)不再以 WARNING 打印,渲染路径进程级关闭 VTK 的警告 +显示——同一进程里你自己代码的 VTK 警告也会被隐藏。真正的失败仍然会大声报出并点名。打印 `BRepInspection` +现在是一行摘要;逐面记录在 `to_dict()` / `.faces` / `.edges`。 + +## Skill + +编辑器运行时,`sca cell` 是修改普通 cell 的唯一方式——直接改文件只在没有编辑器运行时,或用于 `sca cell` +拒绝的 setup / `@app.function` cell。`dof=0` 说明约束系统闭合了,不说明形状是对的(角度约束可能解出镜像 +解):用测量来验证。建模项目按软件工程的方式管理:从第一个文件就用 git,在验证通过的节点提交。 + +完整列表见[更新日志](../../CHANGELOG.md)。 diff --git a/pyproject.toml b/pyproject.toml index 9dadbe4..54c071b 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "simplecadapi" -version = "2.2.4" +version = "2.2.5" description = "A simplified OCP-native CAD modeling Python API" readme = "README.md" license = { file = "LICENSE" } diff --git a/uv.lock b/uv.lock index 52c4bc0..8243691 100644 --- a/uv.lock +++ b/uv.lock @@ -3227,7 +3227,7 @@ wheels = [ [[package]] name = "simplecadapi" -version = "2.2.4" +version = "2.2.5" source = { editable = "." } dependencies = [ { name = "cadquery-ocp" },