[PR #718] [MERGED] [Feature] Rework Archive duplicates tagging #1102

Closed
opened 2026-05-06 12:35:03 +02:00 by BreizhHardware · 0 comments

📋 Pull Request Information

Original PR: https://github.com/maziggy/bambuddy/pull/718
Author: @Keybored02
Created: 3/15/2026
Status: Merged
Merged: 3/16/2026
Merged by: @maziggy

Base: devHead: feature/duplicate_rework_2


📝 Commits (10+)

  • 7a000a5 Use SHA256 for duplicate count, show archive_id on card
  • 6c9e1b9 Fix double scrollbars on Archive page
  • 6b79a21 Show reduced SHA256 to identify print file
  • cae40b8 Compact duplicate tags, send to father on click
  • e830c37 Add Hide Duplicates button
  • b0b65b5 Add button localisation
  • d884582 Refactor duplicate handling to return name/hash pairs
  • 769a80c Fix title attribute to reference original archive ID in ArchiveCard and ArchiveListRow
  • 9521ffd Add localization for "view original print" message
  • 5238cb0 Add duplicate sequence and original archive ID to archive responses

📊 Changes

12 files changed (+251 additions, -27 deletions)

View changed files

📝 backend/app/api/routes/archives.py (+94 -6)
📝 backend/app/schemas/archive.py (+2 -0)
📝 backend/app/services/archive.py (+25 -11)
📝 frontend/src/api/client.ts (+2 -0)
📝 frontend/src/i18n/locales/de.ts (+3 -0)
📝 frontend/src/i18n/locales/en.ts (+3 -0)
📝 frontend/src/i18n/locales/fr.ts (+3 -0)
📝 frontend/src/i18n/locales/it.ts (+3 -0)
📝 frontend/src/i18n/locales/ja.ts (+3 -0)
📝 frontend/src/i18n/locales/pt-BR.ts (+3 -0)
📝 frontend/src/i18n/locales/zh-CN.ts (+3 -0)
📝 frontend/src/pages/ArchivesPage.tsx (+107 -10)

📄 Description

Description

This PR proposes a quick fix to improve duplication handling in the archive page. The idea is to improve usability without fully reworking the archiving behavior. This Pr introduces a different logic to tag duplicates, an UI improvement on the tag itself, a more detailed Archive card, and minor fixes to the Archive page. This is a reimplementation of #582.

Fixes #397 and #512

Type of Change

  • Bug fix (non-breaking change that fixes an issue)
  • New feature (non-breaking change that adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation update
  • Code refactoring
  • Performance improvement
  • Test addition or update

Changes Made

  • Changed duplicate tagging: now both the name and SHA256 need to match to tag a print as duplicates. Fixes different print being tagged only on the base of the same name
  • "Duplicate" text removed form the tag, now the tag shows the number of reprints
  • Tag is now a button that sends back to the parent print, with outline highlights. Parent (original) print has a unique icon and a reprint counter.
  • A new filter Hide Duplicates has been added to the filter bar, with localisation
  • Archive cards included a reduced SHA256 hash to identify associated files and an archive_id to distinguish similar archive entries. Details appear on hover
  • Fixed double scrollbar appearing in Archive page

Screenshots

image image

Testing

  • I have tested this on my local machine
  • I have tested with my printer model: H2C

Checklist

  • My code follows the project's coding style
  • I have commented my code where necessary
  • I have updated the documentation (if needed)
  • My changes generate no new warnings
  • I have tested my changes thoroughly

Additional Notes


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/maziggy/bambuddy/pull/718 **Author:** [@Keybored02](https://github.com/Keybored02) **Created:** 3/15/2026 **Status:** ✅ Merged **Merged:** 3/16/2026 **Merged by:** [@maziggy](https://github.com/maziggy) **Base:** `dev` ← **Head:** `feature/duplicate_rework_2` --- ### 📝 Commits (10+) - [`7a000a5`](https://github.com/maziggy/bambuddy/commit/7a000a5d6b04e39e103b13f48d3bc24f87b2c9bd) Use SHA256 for duplicate count, show archive_id on card - [`6c9e1b9`](https://github.com/maziggy/bambuddy/commit/6c9e1b986938dc19c5b1f930c32c0ec3bcffc0d4) Fix double scrollbars on Archive page - [`6b79a21`](https://github.com/maziggy/bambuddy/commit/6b79a21a3427115b02b2cc92677fba42938546e9) Show reduced SHA256 to identify print file - [`cae40b8`](https://github.com/maziggy/bambuddy/commit/cae40b8e6b15616ce590bca6f34d3f12a7f21269) Compact duplicate tags, send to father on click - [`e830c37`](https://github.com/maziggy/bambuddy/commit/e830c37daa8d5f8e16087b42f80cd4dc59268af4) Add Hide Duplicates button - [`b0b65b5`](https://github.com/maziggy/bambuddy/commit/b0b65b53918307608e939b3f7b4b1848cd68da94) Add button localisation - [`d884582`](https://github.com/maziggy/bambuddy/commit/d884582f18c539070e35ce5f39e3d3ae70c2bdf5) Refactor duplicate handling to return name/hash pairs - [`769a80c`](https://github.com/maziggy/bambuddy/commit/769a80cba232289ce922376d55d644d24fb9e4be) Fix title attribute to reference original archive ID in ArchiveCard and ArchiveListRow - [`9521ffd`](https://github.com/maziggy/bambuddy/commit/9521ffdc032604a0395606193ab2aa19df626a1a) Add localization for "view original print" message - [`5238cb0`](https://github.com/maziggy/bambuddy/commit/5238cb08fa9232e7a226f03e3182126bac68e25c) Add duplicate sequence and original archive ID to archive responses ### 📊 Changes **12 files changed** (+251 additions, -27 deletions) <details> <summary>View changed files</summary> 📝 `backend/app/api/routes/archives.py` (+94 -6) 📝 `backend/app/schemas/archive.py` (+2 -0) 📝 `backend/app/services/archive.py` (+25 -11) 📝 `frontend/src/api/client.ts` (+2 -0) 📝 `frontend/src/i18n/locales/de.ts` (+3 -0) 📝 `frontend/src/i18n/locales/en.ts` (+3 -0) 📝 `frontend/src/i18n/locales/fr.ts` (+3 -0) 📝 `frontend/src/i18n/locales/it.ts` (+3 -0) 📝 `frontend/src/i18n/locales/ja.ts` (+3 -0) 📝 `frontend/src/i18n/locales/pt-BR.ts` (+3 -0) 📝 `frontend/src/i18n/locales/zh-CN.ts` (+3 -0) 📝 `frontend/src/pages/ArchivesPage.tsx` (+107 -10) </details> ### 📄 Description ## Description This PR proposes a quick fix to improve duplication handling in the archive page. The idea is to improve usability without fully reworking the archiving behavior. This Pr introduces a different logic to tag duplicates, an UI improvement on the tag itself, a more detailed Archive card, and minor fixes to the Archive page. This is a reimplementation of #582. ## Related Issue <!-- Link to the issue this PR addresses (if applicable) --> Fixes #397 and #512 ## Type of Change <!-- Mark the relevant option with an "x" --> - [x] Bug fix (non-breaking change that fixes an issue) - [x] New feature (non-breaking change that adds functionality) - [ ] Breaking change (fix or feature that would cause existing functionality to change) - [ ] Documentation update - [ ] Code refactoring - [ ] Performance improvement - [ ] Test addition or update ## Changes Made <!-- List the specific changes made in this PR --> - Changed duplicate tagging: now both the name and SHA256 need to match to tag a print as duplicates. Fixes different print being tagged only on the base of the same name - "Duplicate" text removed form the tag, now the tag shows the number of reprints - Tag is now a button that sends back to the parent print, with outline highlights. Parent (original) print has a unique icon and a reprint counter. - A new filter Hide Duplicates has been added to the filter bar, with localisation - Archive cards included a reduced SHA256 hash to identify associated files and an `archive_id` to distinguish similar archive entries. Details appear on hover - Fixed double scrollbar appearing in Archive page ## Screenshots <!-- If applicable, add screenshots to demonstrate your changes --> <img width="396" height="531" alt="image" src="https://github.com/user-attachments/assets/aa0fc2b3-973a-414d-a6ba-da63dfa71369" /> <img width="438" height="67" alt="image" src="https://github.com/user-attachments/assets/a2e2408c-3bec-4fa5-9fba-183a0e16dd8c" /> ## Testing <!-- Describe how you tested your changes --> - [x] I have tested this on my local machine - [x] I have tested with my printer model: H2C ## Checklist - [x] My code follows the project's coding style - [x] I have commented my code where necessary - [ ] I have updated the documentation (if needed) - [x] My changes generate no new warnings - [x] I have tested my changes thoroughly ## Additional Notes <!-- Add any additional information that reviewers should know --> --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
BreizhHardware 2026-05-06 12:35:03 +02:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
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
starred/bambuddy#1102
No description provided.