Review followup: PR #1866 — GH#1863: Prevent duplicate-key site clone failures
メンテナーはふだん 1 日以内に返信
まだ誰も着手していません。
評価
- 難易度
- 3/5
- 見積もり時間
- 1〜2日
- 初心者へのやさしさ
- 48/100
調査の方向性
Start in inc/duplication/data.php:141 and verify the cited duplicate-key behavior in db_copy_tables. Read tests/WP_Ultimo/Duplication/MUCD_Data_Test.php, especially test_db_copy_tables_ignores_destination_key_collisions, then run the relevant duplication tests. Done means the bot premise is verified and the issue is either closed with a cited falsification or resolved through a tested, justified change.
索引モデルが issue の本文から書いたものです。
説明
Unaddressed review bot suggestions
PR #1866 was merged with unaddressed review bot feedback. Each comment
below includes its file path, line number, a direct link to the inline
review comment, and a diff fence with the code context the bot was
flagging. Resolved and outdated threads are filtered out via GitHub's
GraphQL review-thread state. Read the relevant lines, decide whether
the suggestion is correct, and either apply the fix or close this issue
with a wontfix rationale.
Source PR: https://github.com/Ultimate-Multisite/ultimate-multisite/pull/1866
You are the triager (worker-is-triager rule)
This issue is auto-created from review bot output and dispatched
directly to you. Review bots can be wrong: hallucinated line refs, false
premises about codebase structure, template-driven sweeps without
measurements (see GH#17832-17835 for prior art and AGENTS.md
"AI-Generated Issue Quality"). Do not assume the bot is correct. Verify before acting.
You must end in exactly one of three outcomes — no fourth "hand it back
to the human" path exists. Humans approve decisions; they do not re-do
analysis.
Outcome A — Premise falsified → close the issue
-
Read the cited
file:line(listed under Files to modify below). -
If the bot's claim is factually wrong (file doesn't exist at that
line, function doesn't behave as described, "auto-generated" section
isn't actually auto-generated, etc.), close the issue with a
comment in this shape:Premise falsified. <what the bot claimed>. <what the code
actually shows, with afile:linecitation or one-line quote>.
Not acting.No PR. No further dispatch. The closing comment trains the next
session reading this thread and the noise filter.
Outcome B — Premise correct + fix is obvious → implement and PR
- Verify the bot's premise as above.
- Read the Worker Guidance section below, open a worktree, implement.
- Open a PR with
Resolves #<this-issue-number>in the body
(use THIS issue's number, not the source PR's) so merge auto-closes it. - Follow the normal Lifecycle Gate (brief, tests, review-bot-gate,
merge, postflight).
Outcome C — Premise correct but approach is a genuine judgment call
Only use this path if you reach it after Outcomes A and B don't apply:
the bot's finding is real, but the fix requires a decision that is
architectural, policy, breaking-change, or otherwise genuinely outside
what you can resolve autonomously. In that case, post a decision
comment with exactly these fields:
- Premise check: one line, confirming the finding is real.
- Analysis: 2-4 bullets on the trade-offs.
- Recommended path: the option you would take if the decision were
yours, with rationale. - Specific question: the single decision the human needs to make
(yes/no or pick-one, not open-ended).
Then apply hold-for-review and stop. The human wakes up to a
ready-to-approve recommendation, not a blank task.
Ambiguity about scope or style is not Outcome C. Per
AGENTS.md"Reasoning responsibility", the model does the
thinking and delivers a recommendation. Only escalate what is genuinely
a maintainer-only decision.
Worker Guidance
Files to modify:
inc/duplication/data.php:141
Implementation steps (Outcome B path):
- Read the
diffblock under each inline comment below — it shows the
exact code the bot was flagging. Open the file only if you need
surrounding context beyond what the diff tail shows. - Read the bot's full comment below the diff — it contains the rationale
and any suggested change. - Verify the premise before implementing (see Outcome A). If the premise
is wrong, switch to Outcome A instead of burning iterations trying to
satisfy a wrong suggestion. - If multiple comments target the same file, group your edits into one
logical commit. - Run
shellcheck/markdownlint-cli2/ project tests as appropriate.
Verification:
- Open the new PR with
Resolves #<this-issue>so this followup is auto-closed on merge. - If the bot's suggestion was incorrect, close this issue with a Outcome A comment — do not open a no-op PR.
Inline comments
coderabbitai on inc/duplication/data.php:141
@@ -138,7 +138,7 @@ public static function db_copy_tables($from_site_id, $to_site_id) {
self::do_sql_query($create_statement_sql);
// Populate database with data from source table
- self::do_sql_query('INSERT `' . $table_name . '` SELECT * FROM `' . $table . '`');
+ self::do_sql_query('INSERT IGNORE `' . $table_name . '` SELECT * FROM `' . $table . '`');
🗄️ Data Integrity & Integration | 🟠 Major | 🏗️ Heavy lift
🔎 Supported by static analysis
🏁 Script executed:
sed -n '81,150p' inc/duplication/data.php sed -n '620,695p' tests/WP_Ultimo/Duplication/MUCD_Data_Test.php rg -n "option_id|option_name|CREATE TABLE.*options|wp_get_db_schema" tests incRepository: Ultimate-Multisite/ultimate-multisite
Length of output: 14568
🏁 Script executed:
#!/bin/bash set -o pipefail printf '%s\n' '--- db_copy_tables callers and surrounding implementation ---' rg -n -C 4 "db_copy_tables\(|test_db_copy_tables_ignores_destination_key_collisions|wu_mucd_should_copy_table" inc tests printf '%s\n' '--- complete collision test context ---' sed -n '560,685p' tests/WP_Ultimo/Duplication/MUCD_Data_Test.php printf '%s\n' '--- options schema and fixtures ---' rg -n -C 8 "option_id bigint|CREATE TABLE.*options|INSERT INTO .*options|blog_charset|siteurl|home|active_plugins|wp_options" . --glob '*.php' --glob '*.sql' --glob '*.feature' --glob '*.xml' --glob '*.json' --glob '*.yml' --glob '*.yaml' | head -n 500Repository: Ultimate-Multisite/ultimate-multisite
Length of output: 41640
🏁 Script executed:
#!/bin/bash set -o pipefail printf '%s\n' '--- exact implementation and caller context ---' sed -n '20,45p' inc/duplication/data.php sed -n '120,150p' inc/duplication/data.php sed -n '130,150p' tests/WP_Ultimo/Orphaned_Tables_Manager_Test.php sed -n '630,682p' tests/WP_Ultimo/Duplication/MUCD_Data_Test.php printf '%s\n' '--- test bootstrap and WordPress fixture sources ---' git ls-files | rg '(^|/)(phpunit|bootstrap|wp-tests|tests)/|schema|install|factory' | head -n 200 rg -n -C 5 "wp_initialize_site|populate_options|populate_network|siteurl|blogname|admin_email|option_id" tests --glob '*.php' --glob '*.sql' --glob '*.xml' | head -n 400Repository: Ultimate-Multisite/ultimate-multisite
Length of output: 41099
🏁 Script executed:
#!/bin/bash set
PR review summaries
(none)
aidevops.sh v3.32.317 automated scan.
- 主要言語
- PHP
- スター
- 218
- フォーク
- 87
- 平均マージ
- 1日 7時間
- マージ済み PR(30日)
- 85
環境構築
- Dockerfile・Docker Compose ファイルなし
- プルリクエストのテンプレートなし
- コントリビューションガイドを読む
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
Ultimate-Multisite/ultimate-multisite のほかの issue
-
perf: lazy-load the top My Sites toolbar and defer initial site-list hydration対応中かも @superdav42 が 3 日前に担当しました。 オープンenhancement origin:interactive priority:medium status:in-review tier:standard
難易度 5/5 1週間以上 初心者へのやさしさ 25/100
Ultimate-Multisite/ultimate-multisite#2015 · コメント 6 件 · 担当者 1 名 ·
メンテナーはふだん 1 日以内に返信
-
Secondary networks: sunrise queries unregistered scoped tables, and wu_{N}_* tables are never created対応中かも @superdav42 が 3 日前に担当しました。 オープンbug origin:interactive status:in-review
難易度 5/5 1週間以上 初心者へのやさしさ 35/100
Ultimate-Multisite/ultimate-multisite#2012 · コメント 13 件 · 担当者 1 名 ·
メンテナーはふだん 1 日以内に返信
-
Secondary networks never get Ultimate Multisite tables created or upgraded対応中かも @superdav42 が 4 日前に担当しました。 オープンbug origin:interactive status:claimed
Ultimate-Multisite/ultimate-multisite#2009 · コメント 1 件 · 担当者 1 名 ·
メンテナーはふだん 1 日以内に返信
-
needs-maintainer-review review:approve
難易度 3/5 1〜2日 初心者へのやさしさ 62/100
Ultimate-Multisite/ultimate-multisite#1952 · コメント 2 件 ·
メンテナーはふだん 1 日以内に返信
-
auto-dispatch needs-investigation origin:worker security status:available tier:standard type:bug
難易度 3/5 半日 初心者へのやさしさ 30/100
Ultimate-Multisite/ultimate-multisite#1938 ·
メンテナーはふだん 1 日以内に返信
Ultimate-Multisite/ultimate-multisite の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 65/100
getgrav/grav-plugin-api#66 ·
-
frontend good first issue healthcare-review
難易度 2/5 1〜3時間 初心者へのやさしさ 83/100
AfyaLinkAfrica/afyalink-web#25 ·
メンテナーはふだん 1 日以内に返信
-
priority:medium type:chore
難易度 1/5 1〜3時間 初心者へのやさしさ 84/100
crazy-goat/php-fpm-ng#1041 ·
メンテナーはふだん 1 日以内に返信
-
Bug Status: Needs Triage
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
メンテナーはふだん 1 日以内に返信
-
難易度 2/5 1〜3時間 初心者へのやさしさ 68/100
メンテナーはふだん 1 日以内に返信