jekyll-github-metadata calls Pages API for private repos with Pages disabled, causing fatal 403
まだ誰も着手していません。
評価
- 難易度
- 3/5
- 見積もり時間
- 1〜2日
- 初心者へのやさしさ
- 58/100
- issue の種類
- バグ
- 明瞭さ
- おおむね明確
- 活発さ
- 静か
- 技術スタック
- github, jekyll, ruby
- 領域
- api, build-system
調査の方向性
Start by locating the code that derives url and baseurl and invokes GET /repos/{owner}/{repo}/pages, then reproduce the build with a private repository that has Pages disabled. Check the existing tests around metadata defaults and API failures. Done means the build no longer aborts on this 403 while preserving the documented fallback behavior.
索引モデルが issue の本文から書いたものです。
説明
Beep boop, I am Claude Code 🤖, my user has reviewed and approved the following written by me:
Description
When a repo is private and GitHub Pages is not enabled, the jekyll-github-metadata gem (v2.16.1, bundled in github-pages v232) makes a GET /repos/{owner}/{repo}/pages API call and throws a fatal 403 error during build.
This happens because the gem uses ||= to set url/baseurl as fallbacks — if those values aren't already set in _config.yml, it tries to detect them via the Pages API. A private repo with Pages disabled has no Pages resource, so the API returns 403 and the build aborts.
Environment
- jekyll-github-metadata v2.16.1
- github-pages v232
- Private repo with GitHub Pages disabled
Steps to reproduce
- Create a private repo with GitHub Pages disabled.
- Build the Jekyll site locally (or via the gem) without explicitly setting
url/baseurlin_config.yml.
Expected
The gem falls back gracefully (e.g. omitting url/baseurl detection, or handling the 403 without aborting the build) when Pages is disabled.
Actual
The build aborts with a fatal 403 error from the GET /repos/{owner}/{repo}/pages call.
Workaround
Setting url and baseurl explicitly in _config.yml short-circuits the ||= fallback, so the Pages API is never called. This requirement isn't documented anywhere, and the error message gives no hint that setting config values would avoid the API call entirely.
Beep boop, Claude Code 🤖 out!
- 主要言語
- Ruby
- スター
- 309
- フォーク
- 159
- PR マージ指標
- 30日以内にマージされた PR はありません
環境構築
このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
jekyll/github-metadata のほかの issue
-
Pageオープン
難易度 5/5 1週間以上 初心者へのやさしさ 10/100
jekyll/github-metadata#294 ·
-
難易度 4/5 3〜5日 初心者へのやさしさ 25/100
jekyll/github-metadata#290 · コメント 1 件 ·
-
Limit and/or Cache API requests to avoid: 403 - API rate limit exceeded for installation ID ___オープン
難易度 4/5 3〜5日 初心者へのやさしさ 35/100
jekyll/github-metadata#266 · コメント 6 件 · リアクション 4 件 ·
-
難易度 3/5 1〜2日 初心者へのやさしさ 35/100
jekyll/github-metadata#264 · コメント 1 件 · リアクション 3 件 ·
-
pinned
難易度 5/5 1週間以上 初心者へのやさしさ 28/100
jekyll/github-metadata#130 · コメント 5 件 · リアクション 6 件 ·
jekyll/github-metadata の issue をすべて見る
似ている issue
-
instrumentation-sidekiq
難易度 2/5 1〜3時間 初心者へのやさしさ 65/100
open-telemetry/opentelemetry-ruby-contrib#2735 ·
メンテナーはふだん 2 日以内に返信
-
SecureRandom.alphanumeric can silently return an empty or wrong-length secret instead of raisingオープン
難易度 2/5 1〜3時間 初心者へのやさしさ 67/100
ruby/securerandom#92 ·
-
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
we-promise/sure#5902 ·
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 70/100
-
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
メンテナーはふだん 1 日以内に返信