Commit Graph

2 Commits

Author SHA1 Message Date
Charles P. Cross
8c1f865e23 Fix doctor incorrectly diagnosing hash IDs as sequential (issue #322)
- Enhanced checkIDFormat to sample multiple issues instead of just one
- Added detectHashBasedIDs function with robust multi-heuristic detection:
  * Checks for child_counters table (hash ID schema indicator)
  * Detects letters in IDs (base36 encoding)
  * Identifies leading zeros (common in hash IDs, rare in sequential)
  * Analyzes variable length patterns (adaptive hash IDs)
  * Checks for non-sequential numeric ordering
- Added comprehensive test coverage (16 new test cases)
- Fixes false positives for numeric-only hash IDs like 'pf-0088'

Closes #322
2025-11-18 05:20:11 -05:00
Steve Yegge
0858bdb7ed Implement hash ID migration tool (bd-173)
- Add migrate-hash-ids command for converting sequential to hash-based IDs
- Integrate into bd migrate --to-hash-ids for transparent user experience
- Generate hash IDs for top-level issues, hierarchical IDs for children
- Update all references: dependencies, comments, text mentions
- Auto-backup database before migration
- Comprehensive tests covering migration scenarios
- Update AGENTS.md with migration documentation

Amp-Thread-ID: https://ampcode.com/threads/T-492f81db-5b0e-437a-b54d-ae4525dd7827
Co-authored-by: Amp <amp@ampcode.com>
2025-10-30 16:28:13 -07:00