Skip to content

fix : prevented duplicate entries in _partition_lists case-insensitive comparison - #1341

Open
tmdeveloper007 wants to merge 1 commit into
komalharshita:mainfrom
tmdeveloper007:#1336
Open

fix : prevented duplicate entries in _partition_lists case-insensitive comparison#1341
tmdeveloper007 wants to merge 1 commit into
komalharshita:mainfrom
tmdeveloper007:#1336

Conversation

@tmdeveloper007

Copy link
Copy Markdown
Contributor

Summary of What Has Been Done

Fixed the _partition_lists function in src/utils/roadmap_comparer.py to prevent duplicate entries when the same semantic item appears in both lists with different capitalizations.

The bug caused items like "Python" (list_a) and "python" (list_b) to appear both in the overlapping list AND in the unique_b list, because the unique_b comprehension only checked key not in norm_a without considering that the key had already been claimed as overlapping.

Changes Made

  • Modified the unique_b list comprehension in _partition_lists to exclude keys that have already been added to the overlapping list:
    # Before:
    unique_b = [original for key, original in norm_b.items() if key not in norm_a]
    
    # After:
    unique_b = [original for key, original in norm_b.items()
               if key not in norm_a and key not in seen_overlap]

Impact it Made

  • Roadmap comparisons no longer contain duplicate skill/topic entries
  • Users see clean, non-redundant comparison data
  • Fixes data integrity issue in the roadmap comparison feature

Closes #1336

Note: Please assign this PR to the tmdeveloper007 account.

@vercel

vercel Bot commented Jul 25, 2026

Copy link
Copy Markdown

@tmdeveloper007 is attempting to deploy a commit to the komalsony234-1530's projects Team on Vercel.

A member of the Team first needs to authorize it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fix : duplicate entries in _partition_lists when items differ only by case

1 participant