Complete restore can leave the site half-restored
評価
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 初心者へのやさしさ
- 20/100
調査の方向性
The issue describes restore behavior in the file-copy and EventSource request paths, but names no source files or tests. Read the restore implementation and inspect the open pull request #251 to understand the proposed fix. Done means the running BackWPup version remains in place and the copy finishes after the browser leaves the page.
索引モデルが issue の本文から書いたものです。
説明
Describe the bug
Two ways a complete restore leaves a mix of old and restored files:
- The backup's BackWPup replaces the running plugin. The file step copies
wp-content/plugins/backwpupfrom the backup over the plugin running the restore. The database step and the cleanup then run the backup's (often older) code, so fixes in the installed version are not used. - Leaving the restore page aborts the copy. The file copy runs in one EventSource request without
ignore_user_abort. Following a link, closing the tab or dismissing an admin notice via its link makes PHP abort the copy halfway.
To Reproduce
- Install a newer BackWPup than the one in the backup and start a complete restore. After the file step,
wp-content/plugins/backwpup/backwpup.phphas the backup's version. - On a site with All-In-One WP Security's firewall (loaded via
auto_prepend_file), restore a backup containing a different AIOS version and leave the page while "Restoring: Directories" is running.
Observed
For case 2, the restore log stops mid-way and every request, including / and the restore page, fails with:
PHP Fatal error: Trait "AIOWPS\Firewall\File_Prefix_Trait" not found
AIOS' new config.php was copied, but the libs/traits/ folder it needs was still queued. The restore can't be resumed from the browser.
Expected behavior
The restore keeps the running BackWPup plugin and finishes the copy even if the browser leaves the page.
System
- BackWPup 5.7.8 (restore code shared with 4.x)
- PHP 8.3, MariaDB, All-In-One WP Security with firewall enabled
A fix is ready as a pull request.
- 主要言語
- PHP
- スター
- 96
- フォーク
- 48
- PR マージ指標
- 30日以内にマージされた PR はありません
環境構築
このプロジェクトには開発コンテナ、Dockerfile、コントリビューションガイドがありません。まず README を読み、一般的な手順ははじめてのコントリビューションガイドを参照してください。
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
wp-media/backwpup のほかの issue
-
難易度 1/5 1時間未満 初心者へのやさしさ 85/100
-
S3 backup list times are shifted by the site's UTC offset (timezone offset applied twice)再び着手できるかも このイシューのプルリクエストはマージされずにクローズされました。 オープン
難易度 2/5 1〜3時間 初心者へのやさしさ 76/100
-
WordPress XML export: posts have no categories or tags since 5.6.6対応中かも @rafaelmaeuer が 14 日前に担当しました。 オープン
難易度 3/5 1〜2日 初心者へのやさしさ 25/100
-
Complete restore stops after the file step: user is logged out, database is not restored対応中かも @rafaelmaeuer が 14 日前に担当しました。 オープン
難易度 4/5 3〜5日 初心者へのやさしさ 25/100
-
Database restore loses data when a row is larger than max_allowed_packet対応中かも @rafaelmaeuer が 14 日前に担当しました。 オープン
難易度 4/5 3〜5日 初心者へのやさしさ 25/100
wp-media/backwpup の issue をすべて見る
似ている issue
-
難易度 2/5 1〜3時間 初心者へのやさしさ 84/100
メンテナーはふだん 3 日以内に返信
-
sync-en
難易度 2/5 1〜3時間 初心者へのやさしさ 74/100
メンテナーはふだん 1 日以内に返信
-
[Sync EN] Formatting improvements to "Large Objects (LOBs)" docs (#6056)対応中かも このイシューにリンクされたプルリクエストがオープン中、またはマージ済みです。 オープンsync-en
難易度 1/5 1時間未満 初心者へのやさしさ 74/100
メンテナーはふだん 1 日以内に返信
-
Перевод устарел
難易度 2/5 1〜3時間 初心者へのやさしさ 73/100
メンテナーはふだん 1 日以内に返信
-
repo:cms
難易度 2/5 1〜3時間 初心者へのやさしさ 78/100
craftcms/cms#20613 · コメント 1 件 ·
メンテナーはふだん 1 日以内に返信