Builder: doSave() writes into a read-only (run) calculation and resets its state to Created
還沒有人認領這個 Issue。
評估
- 難度
- 2/5
- 預估耗時
- 1-3 小時
- 新手友好度
- 74/100
- Issue 類型
- 缺陷
- 描述清晰度
- 描述清楚
- 活躍度
- 活躍
- 技術堆疊
- c
研究方向
閱讀src/apps/builder/Builder.C中Builder::doSave()附近的程式碼,並將其行為與用來停用 File > Save 的唯讀檢查進行比較。issue 也指出了src/dsm/edsiimpl/ChemistryTask.C中的ChemistryTask::fragment(),它會將狀態變更為 Created。請確認唯讀計算無法透過直接的save hook 儲存,且其狀態維持不變。
由索引模型根據 Issue 內容生成。
描述
Where: `Builder::doSave()` (src/apps/builder/Builder.C) has no read-only check. File > Save is disabled for a read-only calculation (state Submitted or later, `PropertyTask::isReadOnly`), but a direct caller of `doSave()` still saves the structure through `ChemistryTask::fragment()`, which then sets the state to Created (src/dsm/edsiimpl/ChemistryTask.C, end of `fragment`). A run calculation, with its outputs and properties, becomes an editable, unrun calculation without any question.
Repro (hooks, one program, isolated home):
- Organizer `ECCE_TEST_ORGANIZER`: `examples`, then `start Builder file:///users/local/Examples/Getting_Started/ammonia` (a stored MOPAC run, state Loaded).
- `ECCE_BUILDER_SCRIPT`: `wait 20000`, `savestate` (dirty=0 save_enabled=0: read-only), `save`, `wait 3000`, `savestate`.
- The calculation's `.ecce-meta` now has `state Created`. Any later edit marks it dirty and enables Save.
Today only the `save` script hook reaches this path; the menu, toolbar and Ctrl+S are disabled. Found while diagnosing #1137.
Expected: `doSave()` refuses on a read-only calculation (as the menu does), or the `save` hook goes through the menu's enable state (`savemenu` already does).
- 主要語言
- C
- 星號
- 10
- 分支
- 8
- PR 合併指標
- 30 天內沒有已合併 PR
環境準備
這個專案沒有提供開發容器、Dockerfile 或貢獻指南,環境需要你自己搭建:先看它的 README,通用步驟見我們的新手貢獻指南。
從這裡開始
- 先讀完整個 Issue,再讀專案的貢獻指南。
- 在 Issue 下留言說明你要接手 —— 這能避免兩個人做同樣的事。
- Fork 儲存庫,在一個分支上完成修改。
- 送出 Pull Request,並在描述裡引用這個 Issue 編號。
FriendsofECCE/ECCE 的其他 Issue
-
Builder: a structure opened without calculation data shows the Diffraction (fibre) view by default未關閉bug
難度 2/5 1-3 小時 新手友好度 65/100
FriendsofECCE/ECCE#1245 · 1 則留言 ·
-
bug
難度 2/5 1-3 小時 新手友好度 82/100
FriendsofECCE/ECCE#1129 ·
-
Organizer: right-click on a calculation — 'Rerun' should be 'Duplicate'; Reset for Rerun missing未關閉bug
難度 2/5 1-3 小時 新手友好度 70/100
FriendsofECCE/ECCE#1089 · 1 則留言 ·
-
難度 2/5 1-3 小時 新手友好度 70/100
FriendsofECCE/ECCE#336 · 1 則留言 ·
-
bug
難度 4/5 3-5 天 新手友好度 18/100
FriendsofECCE/ECCE#1253 ·
查看 FriendsofECCE/ECCE 的全部 Issue
相似的 Issue
-
Arch: ARM/AArch64 Doc
難度 1/5 1 小時以內 新手友好度 90/100
RT-Thread/rt-thread#12082 · 1 則留言 ·
維護者通常 2 天內回覆
-
難度 2/5 1-3 小時 新手友好度 72/100
apache/nuttx-apps#4108 · 4 則留言 ·
維護者通常 1 天內回覆
-
bug
難度 1/5 1 小時以內 新手友好度 84/100
VirtualBox/virtualbox#996 ·
維護者通常 6 天內回覆
-
難度 1/5 1 小時以內 新手友好度 82/100
trezor/trezor-firmware#8357 ·
維護者通常 2 天內回覆
-
難度 2/5 1-3 小時 新手友好度 76/100
維護者通常 1 天內回覆