mirror of
https://github.com/mwisnowski/mtg_python_deckbuilder.git
synced 2025-09-22 04:50:46 +02:00

- Include/exclude cards feature complete with 300+ card knowledge base and intelligent fuzzy matching - Enhanced visual validation with warning icons and performance benchmarks (100% pass rate) - Mobile responsive design with bottom-floating controls, two-column layout, and horizontal scroll prevention - Dark theme confirmation modal for fuzzy matches with card preview and alternatives - Dual architecture support for web UI staging system and CLI direct build paths - All M3 checklist items completed: fuzzy match modal, enhanced algorithm, summary panel, mobile responsive, Playwright tests
35 lines
1.2 KiB
Python
35 lines
1.2 KiB
Python
#!/usr/bin/env python3
|
|
"""Debug what specific Lightning/Bolt cards exist"""
|
|
|
|
import pandas as pd
|
|
|
|
cards_df = pd.read_csv('csv_files/cards.csv')
|
|
|
|
print("=== Lightning cards that start with 'Light' ===")
|
|
lightning_prefix = cards_df[cards_df['name'].str.lower().str.startswith('lightning', na=False)]['name'].unique()
|
|
for card in sorted(lightning_prefix):
|
|
print(f" - {card}")
|
|
|
|
print(f"\n=== Cards containing 'bolt' ===")
|
|
bolt_cards = cards_df[cards_df['name'].str.contains('bolt', case=False, na=False)]['name'].unique()
|
|
for card in sorted(bolt_cards):
|
|
print(f" - {card}")
|
|
|
|
print(f"\n=== Cards containing 'warp' ===")
|
|
warp_cards = cards_df[cards_df['name'].str.contains('warp', case=False, na=False)]['name'].unique()
|
|
for card in sorted(warp_cards):
|
|
print(f" - {card}")
|
|
|
|
print(f"\n=== Manual test of 'lightn' against Lightning cards ===")
|
|
test_input = "lightn"
|
|
lightning_scores = []
|
|
from difflib import SequenceMatcher
|
|
|
|
for card in lightning_prefix:
|
|
score = SequenceMatcher(None, test_input.lower(), card.lower()).ratio()
|
|
lightning_scores.append((score, card))
|
|
|
|
lightning_scores.sort(key=lambda x: x[0], reverse=True)
|
|
print("Top Lightning matches for 'lightn':")
|
|
for score, card in lightning_scores[:5]:
|
|
print(f" {score:.3f} - {card}")
|