"""Debug: find actual VWP2 folder paths in drive 3 CSV.""" import csv WIZ = 'clients/valleywide/app-modernization/WizTree_20260516174356.csv' hits = [] with open(WIZ, encoding='utf-8-sig', errors='replace') as f: r = csv.reader(f); next(r); next(r) for row in r: if not row: continue p = row[0] pl = p.lower() # Look for any path containing 'g$' (server snapshot pattern) and 'vwp2' as a folder name (with surrounding backslash) if 'vwp2' + chr(92) in pl and 'g$' in pl: hits.append(p) if len(hits) > 15: break print(f'sample vwp2 folder paths in drive 3 (15):') for h in hits[:15]: print(f' {h!r}') # Also check what server snapshots exist print('\nServer snapshot leaf folders containing "g$":') seen = set() with open(WIZ, encoding='utf-8-sig', errors='replace') as f: r = csv.reader(f); next(r); next(r) for row in r: if not row: continue p = row[0] if not p.endswith(chr(92)): continue leaf = p.rstrip(chr(92)).rsplit(chr(92), 1)[-1] if leaf.lower().startswith('g$') and leaf not in seen: seen.add(leaf) print(f' {leaf!r}')