Skip to content

Fix: properly use unique_bodyparts and identity_scores arguments in ShelfWriter.add_prediction#3112

Open
maximpavliv wants to merge 6 commits intomainfrom
maxim/fix_shelf_writer
Open

Fix: properly use unique_bodyparts and identity_scores arguments in ShelfWriter.add_prediction#3112
maximpavliv wants to merge 6 commits intomainfrom
maxim/fix_shelf_writer

Conversation

@maximpavliv
Copy link
Contributor

This PR fixes a bug introduced in PR #2861 and reported in Issue #3108, where the unique_bodyparts and identity_scores arguments in ShelfWriter.add_prediction() were being overwritten with None due to redundant kwargs.get() calls.

These reassignments caused the method to ignore valid input arguments when passed directly. The fix removes the two lines that overwrote these parameters, restoring the correct behavior while keeping **kwargs in the signature for subclass compatibility.

@arashsm79
Copy link
Contributor

LGTM. Thanks!

@deruyter92 deruyter92 requested a review from Copilot January 13, 2026 08:44
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR fixes a bug where unique_bodyparts and identity_scores arguments in ShelfWriter.add_prediction() were being overwritten with None by redundant kwargs.get() calls, causing the method to ignore valid direct arguments.

Changes:

  • Removed two lines that were reassigning unique_bodyparts and identity_scores parameters with values from kwargs

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@deruyter92 deruyter92 self-requested a review January 15, 2026 12:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug fix! fix for a real buggy one... DLC3.0🔥

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants