Hacktoberfest 2026:メンテナが10月に向けて印を付けた、オープンで初心者向けの issue。 Hacktoberfest の issue を見る

Failed to apply patch with scissors

オープン
#78 コメント 0 件 リアクション 0 件 担当者 0 名 GitHub で見る

まだ誰も着手していません。

評価

難易度
3/5
見積もり時間
1〜2日
初心者へのやさしさ
45/100
issue の種類
バグ
明瞭さ
おおむね明確
活発さ
停滞
技術スタック
git, python
領域
cli, tooling

調査の方向性

まず git-pw patch apply 120008 で失敗を再現し、git-pw patch download --mbox を、動作する --diff および Thunderbird が生成した入力と比較します。git-pw が From patchwork 行の周辺で mbox をどのように構築しているかを調査し、scissors を含むパッチも含めて、結果を git am でテストします。その行を手動で削除せずに報告されたパッチを適用できれば完了です。

索引モデルが issue の本文から書いたものです。

説明

I ran into the following problem while trying to apply this patch:

$ git-pw patch apply 120008
Failed to apply patch:
Applying: New '--binary-output' command line option, fix gdb.mi/ testing on Windows
error: No valid patches in input (allow with "--allow-empty")
error: could not build fake ancestor
hint: Use 'git am --show-current-patch=diff' to see the failed patch
hint: When you have resolved this problem, run "git am --continue".
hint: If you prefer to skip this patch, run "git am --skip" instead.
hint: To restore the original branch and stop patching, run "git am --abort".
hint: Disable this message with "git config set advice.mergeConflict false"
Patch failed at 0001 New '--binary-output' command line option, fix gdb.mi/ testing on Windows

$ git am --show-current-patch=diff
--- 8< ---
$

The following things do work:

  • get the patch by saving email using Thunderbird, and use git am to apply it
  • get the patch using git-pw patch download --diff, and use patch to apply it

But this doesn't work (I suppose because it's the equivalent of git-pw patch apply):

  • use git-pw patch download --mbox and use git am to apply it

After downloading the patch in the mbox format, I took a look.

On a hunch, I removed the first line:

From patchwork Wed Sep 10 20:46:42 2025                                                        

and got:

$ git am v2-New---binary-output-command-line-option-fix-gdb.mi-testing-on-Windows.patch
Applying: New '--binary-output' command line option, fix gdb.mi/ testing on Windows
$

What I understand from this is that the mbox format that patchwork generates is incompatible with git am if the patch contains scissors.

主要言語
Python
スター
39
フォーク
23
平均マージ
48分
マージ済み PR(30日)
1

コントリビューションガイド

このリポジトリのコントリビューションガイドは索引されていません

はじめの一歩

  1. issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
  2. 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
  3. リポジトリをフォークし、ブランチを切って変更します。
  4. issue 番号を参照したプルリクエストを送ります。

getpatchwork/git-pw のほかの issue

getpatchwork/git-pw の issue をすべて見る

似ている issue

Python の issue をもっと見る

新しい issue をメールで受け取る

初心者向けの GitHub issue を短くまとめたダイジェスト。