create can leave a page that nothing on disk names
まだ誰も着手していません。
評価
調査の方向性
Start in cmd/create/create.go at reserveOne, then trace CreatePage, os.WriteFile, persistToManifest, and failKeepingPage. Compare the recovery and failure paths and confirm the chosen behavior with maintainers; done means a failed reservation cannot leave an unrecorded page, or provides an exact actionable recovery record.
索引モデルが issue の本文から書いたものです。
説明
create can leave a page in Confluence that nothing on disk names.
In the reserve phase, reserveOne (cmd/create/create.go) calls CreatePage and only then records the new page_id. It records it in one of two places: the file's frontmatter (os.WriteFile) or a pages: entry in markfluence.yaml (persistToManifest). If that write fails, the page already exists. Examples are a read-only .md file, a read-only markfluence.yaml, or a manifest write that gives up after its one retry.
failKeepingPage keeps the id and URL in the command's result, so the run's own output is the only record. A second create makes a second page, because nothing says the first one exists. update cannot pick it up either, because nothing names the page.
This is the one case in create's partial-failure story that update cannot recover from. The other two recover:
- A network failure during publish leaves a stub whose id is already on disk, so
updatefinishes it. - An unreadable attachment fails the same way, after the id is on disk.
Options:
- Check that the destination is writable before
CreatePage. This is cheap, but it races: the check can pass and the write can still fail. - Write first, create second. Reserve a placeholder on disk, create the page, then fill in the id. A failure then leaves a local marker instead of a remote orphan.
- Make the failure loud and actionable. For example, print the exact frontmatter line or manifest entry to add by hand, and give it an exit code a script can recognize.
- 主要言語
- Go
- スター
- 2
- フォーク
- 0
- 平均マージ
- 2時間 50分
- マージ済み PR(30日)
- 52
コントリビューションガイド
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
mozilla/markfluence のほかの issue
-
難易度 4/5 3〜5日 初心者へのやさしさ 55/100
mozilla/markfluence#186 ·
-
難易度 5/5 1週間以上 初心者へのやさしさ 35/100
mozilla/markfluence#184 ·
-
bug
難易度 3/5 1〜2日 初心者へのやさしさ 55/100
mozilla/markfluence#181 · コメント 1 件 ·
-
bug
難易度 5/5 1週間以上 初心者へのやさしさ 48/100
mozilla/markfluence#163 ·
-
enhancement
難易度 5/5 1週間以上 初心者へのやさしさ 25/100
mozilla/markfluence#162 ·
mozilla/markfluence の issue をすべて見る
似ている issue
-
bug github_actions
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
registrystack/registry-stack#1393 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
JakeChampion/lang#10213 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100
oasisprotocol/oasis-sdk#2523 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 75/100
-
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100