Prevent Game Clones From Sharing Source Boxart #777

Closed
opened 2026-06-28 14:05:26 -05:00 by Veilor · 1 comment
Member

Cloned games must not share the source game's boxart filename or storage object.

The current admin clone flow uses model replication, so the cloned game can inherit the same boxart value as the source game. When admins later upload new boxart for the clone, the edit flow deletes the clone's previous boxart path, which can remove the source game's image because both records pointed at the same file.

Scope

  • Admin game clone persistence in Admin\GameController::storeClone.
  • Boxart filename handling when creating a cloned game.
  • Admin game edit upload behavior that deletes the previous boxart before storing a replacement.
  • Source game image preservation when a clone is edited.
  • Existing boxart upload validation and storage path conventions.

Acceptance Criteria

  • New cloned games do not inherit the source game's boxart value.
  • Editing a cloned game's boxart never deletes or changes the source game's boxart.
  • The source game keeps its original image and storage path after cloning and after the clone receives a new upload.
  • The clone can be saved with no boxart until an admin uploads or selects a new image.
  • Existing admin boxart upload validation and tamper protection remain intact.
  • Existing non-clone game edit behavior for replacing a game's own boxart remains unchanged.

Test Coverage Required

  • Add feature coverage that cloning a game with boxart creates a clone with no shared boxart value.
  • Add regression coverage that uploading boxart to a clone does not delete the source game's stored image.
  • Preserve existing admin upload security coverage for ignored/tampered hidden boxart fields.
  • Cover the clone flow with Storage::fake('s3') so source and clone storage paths can be asserted safely.
  • Run focused admin game clone/upload tests before closing the issue.
  • Run vendor/bin/pint --dirty --format agent before implementation closeout if PHP files change.

Progress Checklist

  • Clear or isolate boxart when creating a game clone
  • Preserve the source game's boxart filename and storage object during clone creation
  • Ensure clone boxart replacement only affects the clone's own previous file
  • Add storage-backed regression coverage for source image preservation
  • Preserve existing admin upload validation and tamper protection
  • Run focused admin game clone/upload tests
  • Run vendor/bin/pint --dirty --format agent if PHP files changed
  • Move the issue out of Codex review once verification is complete
Cloned games must not share the source game's boxart filename or storage object. The current admin clone flow uses model replication, so the cloned game can inherit the same `boxart` value as the source game. When admins later upload new boxart for the clone, the edit flow deletes the clone's previous boxart path, which can remove the source game's image because both records pointed at the same file. ## Scope - Admin game clone persistence in `Admin\GameController::storeClone`. - Boxart filename handling when creating a cloned game. - Admin game edit upload behavior that deletes the previous boxart before storing a replacement. - Source game image preservation when a clone is edited. - Existing boxart upload validation and storage path conventions. ## Acceptance Criteria - New cloned games do not inherit the source game's `boxart` value. - Editing a cloned game's boxart never deletes or changes the source game's boxart. - The source game keeps its original image and storage path after cloning and after the clone receives a new upload. - The clone can be saved with no boxart until an admin uploads or selects a new image. - Existing admin boxart upload validation and tamper protection remain intact. - Existing non-clone game edit behavior for replacing a game's own boxart remains unchanged. ## Test Coverage Required - Add feature coverage that cloning a game with boxart creates a clone with no shared boxart value. - Add regression coverage that uploading boxart to a clone does not delete the source game's stored image. - Preserve existing admin upload security coverage for ignored/tampered hidden boxart fields. - Cover the clone flow with `Storage::fake('s3')` so source and clone storage paths can be asserted safely. - Run focused admin game clone/upload tests before closing the issue. - Run `vendor/bin/pint --dirty --format agent` before implementation closeout if PHP files change. ## Progress Checklist - [ ] Clear or isolate boxart when creating a game clone - [ ] Preserve the source game's boxart filename and storage object during clone creation - [ ] Ensure clone boxart replacement only affects the clone's own previous file - [ ] Add storage-backed regression coverage for source image preservation - [ ] Preserve existing admin upload validation and tamper protection - [ ] Run focused admin game clone/upload tests - [ ] Run `vendor/bin/pint --dirty --format agent` if PHP files changed - [ ] Move the issue out of Codex review once verification is complete
Codex changed title from Cloned entries should not use the same image as the chosen game to Prevent Game Clones From Sharing Source Boxart 2026-06-28 16:30:38 -05:00
Codex self-assigned this 2026-07-01 17:14:26 -05:00
Member

Re-review after expanding the branch to cover clone/source boxart isolation:

The branch codex/issue-775-prefilled-clone-form now meets the intent of this issue as well as #775. The clone form shows source boxart as reference only, does not submit the source boxart filename, and clone persistence no longer uses model replication. A clone can be saved with no boxart, or with a fresh upload that receives its own storage object. Later clone boxart uploads operate on the clone record and preserve the source game image.

Checklist mapping:

  • Clear or isolate boxart when creating a game clone
  • Preserve the source game boxart filename and storage object during clone creation
  • Ensure clone boxart replacement only affects the clone own previous file
  • Add storage-backed regression coverage for source image preservation
  • Preserve existing admin upload validation and tamper protection
  • Run focused admin game clone/upload tests
  • Run vendor/bin/pint --dirty --format agent if PHP files changed
  • Move the issue out of Codex review once verification is complete

Notes on changed scope:

  • The old Admin GameController storeClone replication path is gone. The route name remains, but it now validates the reviewed clone form and creates a fresh game without inheriting source boxart.
  • The clone UI no longer offers source boxart reuse by default; source art is preview-only. This is stricter than the original clone-prefill behavior and directly prevents shared storage deletion.
  • The final tracker transition remains unchecked until branch review/PR closeout.

Verification run:

  • php artisan test --compact tests/Feature/AdminGameCloneTest.php
  • php artisan test --compact tests/Feature/AdminGameIgdbCreateTest.php tests/Feature/AdminGameGenreTest.php tests/Feature/AdminGameRegionalOrderingTest.php tests/Feature/AdminGameUploadSecurityTest.php
  • vendor/bin/pint --dirty --format agent
Re-review after expanding the branch to cover clone/source boxart isolation: The branch codex/issue-775-prefilled-clone-form now meets the intent of this issue as well as #775. The clone form shows source boxart as reference only, does not submit the source boxart filename, and clone persistence no longer uses model replication. A clone can be saved with no boxart, or with a fresh upload that receives its own storage object. Later clone boxart uploads operate on the clone record and preserve the source game image. Checklist mapping: - [x] Clear or isolate boxart when creating a game clone - [x] Preserve the source game boxart filename and storage object during clone creation - [x] Ensure clone boxart replacement only affects the clone own previous file - [x] Add storage-backed regression coverage for source image preservation - [x] Preserve existing admin upload validation and tamper protection - [x] Run focused admin game clone/upload tests - [x] Run vendor/bin/pint --dirty --format agent if PHP files changed - [ ] Move the issue out of Codex review once verification is complete Notes on changed scope: - The old Admin GameController storeClone replication path is gone. The route name remains, but it now validates the reviewed clone form and creates a fresh game without inheriting source boxart. - The clone UI no longer offers source boxart reuse by default; source art is preview-only. This is stricter than the original clone-prefill behavior and directly prevents shared storage deletion. - The final tracker transition remains unchecked until branch review/PR closeout. Verification run: - php artisan test --compact tests/Feature/AdminGameCloneTest.php - php artisan test --compact tests/Feature/AdminGameIgdbCreateTest.php tests/Feature/AdminGameGenreTest.php tests/Feature/AdminGameRegionalOrderingTest.php tests/Feature/AdminGameUploadSecurityTest.php - vendor/bin/pint --dirty --format agent
jimmyb 2026-07-01 17:41:24 -05:00
Sign in to join this conversation.
No milestone
No project
No assignees
2 participants
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
MyVideoGameList/myvideogamelist.com#777
No description provided.