quarto publish gh-pages cannot bootstrap a repository with no gh-pages branch (docs say it creates one)
メンテナーはふだん 1 日以内に返信
まだ誰も着手していません。
評価
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 初心者へのやさしさ
- 48/100
- issue の種類
- バグ
- 明瞭さ
- 明確に書かれている
- 活発さ
- 活発
- 技術スタック
- git, github, javascript
調査の方向性
Start at the quarto publish gh-pages command’s resolveDeployment path, which the error trace locates in the bundled quarto.js, and trace how it checks for a remote gh-pages branch. Reproduce with a website project in a subdirectory and an origin that has only main; compare local and CI publishing. Done means first publish creates the branch as documented, or the error explains a working bootstrap procedure.
索引モデルが issue の本文から書いたものです。
説明
Checks
- I have searched the existing issues and discussions, and this has not been reported.
- I have tested with the latest stable version of Quarto.
System
Linux (x86_64), Quarto 1.10.19 stable, git 2.x, remote over HTTPS with a credential helper.
Expected
Per https://quarto.org/docs/publishing/github-pages.html ("Source Branch"):
quarto publish gh-pagesautomatically creates a gh-pages branch (locally and on the remote) on its first run if one does not already exist.
Actual
Running exactly that first run locally fails, and says to do the thing that just failed:
$ quarto publish gh-pages --no-prompt --no-browser
ERROR: Unable to publish to GitHub Pages (the remote origin does not have a branch named
"gh-pages". Use first `quarto publish gh-pages` locally to initialize the remote repository
for publishing.)
at resolveDeployment (file:///opt/quarto/bin/quarto.js:173771:13)
Answering the confirmation prompt interactively (printf 'y\n' | quarto publish gh-pages --no-browser) gives the same error. The same error also aborts quarto-dev/quarto-actions/publish@v2 with target: gh-pages, so the documented CI recipe cannot bootstrap a new repository either: the job fails at the publish step and no gh-pages branch is ever created.
Repository shape that may matter
- Git repository root:
/repo, with the Quarto project in a subdirectory:/repo/05_website/_quarto.yml(project.type: website,output-dir: _site,website.site-urlset to the project-page URL). - Branches on
origin:mainonly. Nogh-pages. - No
_publish.ymlanywhere (i.e. genuinely a first run).
So the case is: valid website project, canonical site-url configured, publishing source absent. That is precisely the case the docs say Quarto initialises.
What we did to get unblocked
Created the branch by hand once, with git plumbing so the working tree was untouched:
empty=$(git hash-object -t tree /dev/null)
commit=$(git commit-tree "$empty" -m "Initialize gh-pages branch for Quarto publishing")
git push origin "$commit:refs/heads/gh-pages"
After that, the same quarto publish gh-pages invocation (from CI) renders and deploys normally, GitHub picks the branch up and Pages reports status: built. So the failure is specific to creating the branch, not to the deployment itself.
Two asks
- If branch creation is conditional on something (project at the repository root? a remote helper? an interactive TTY?
_publish.yml?), please document the condition; the current error message points at a step that cannot be performed, because performing it produces the same error. - Otherwise, either create the branch on first run as documented, or replace the message with the three-command manual bootstrap above.
Happy to test a pre-release against this repository shape.
- 主要言語
- JavaScript
- スター
- 6.1k
- フォーク
- 476
- 平均マージ
- 17時間 7分
- マージ済み PR(30日)
- 112
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートあり
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
quarto-dev/quarto-cli のほかの issue
-
enhancement websites
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
quarto-dev/quarto-cli#15255 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
Website announcement dismiss control cannot be reached or used with a keyboard対応中かも @Xander-AJ が今日担当しました。 オープンaccessibility bug websites
難易度 1/5 1〜3時間 初心者へのやさしさ 88/100
quarto-dev/quarto-cli#15235 ·
メンテナーはふだん 1 日以内に返信
-
quarto.json.decode does not raise on invalid JSON, so pcall cannot catch it対応中かも @sogav21 が 2 日前に担当しました。 オープンbug lua
難易度 2/5 1〜3時間 初心者へのやさしさ 84/100
quarto-dev/quarto-cli#15226 ·
メンテナーはふだん 1 日以内に返信
-
arrow-dark gives region markers a light band that fails contrast対応中かも @vav7 が 1 日前に担当しました。 オープンaccessibility bug themes
難易度 1/5 1時間未満 初心者へのやさしさ 88/100
quarto-dev/quarto-cli#15222 ·
メンテナーはふだん 1 日以内に返信
-
bug code-annotation
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
quarto-dev/quarto-cli#15215 ·
メンテナーはふだん 1 日以内に返信
quarto-dev/quarto-cli の issue をすべて見る
似ている issue
-
needs-triage
難易度 2/5 1〜3時間 初心者へのやさしさ 66/100
microsoft/playwright#43875 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信
-
Run the dependency drift check対応中かも @spaceninja が今日担当しました。 オープン
難易度 1/5 1時間未満 初心者へのやさしさ 82/100
cloudfour/stylelint-config-cloudfour#683 ·
メンテナーはふだん 1 日以内に返信
-
Documentation Enhancement
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
JSPrismarine/JSPrismarine#2706 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 72/100
PostHog/posthog-js#5524 ·
メンテナーはふだん 2 日以内に返信
-
enhancement good first issue help wanted
難易度 2/5 半日 初心者へのやさしさ 66/100
AlphaaCode/Popbook#10 ·