Summary
Inbound follow tracking uses mutable usernames as relationship identifiers.
Username changes can break relationship consistency and historical analytics.
Affected Files
- follow.ts
- analytics.ts
- schema.prisma
Root Cause
Follow relationships reference usernames rather than immutable user identifiers.
When usernames change, historical records become disconnected from the current account identity.
Reproduction
- Follow a user.
- Rename the followed account.
- Inspect inbound follow records.
- Observe inconsistencies between historical records and current account identity.
Expected Behavior
Follow relationships should remain stable regardless of username changes.
Actual Behavior
Username changes affect relationship consistency.
Why This Is Difficult To Detect
The issue only appears after account renames.
Most follow testing uses static usernames.
Production Impact
- Broken analytics
- Inconsistent relationship tracking
- Historical data corruption
- Identity ambiguity
Suggested Fix
Store immutable user IDs rather than mutable usernames.
Severity
Medium-High
Summary
Inbound follow tracking uses mutable usernames as relationship identifiers.
Username changes can break relationship consistency and historical analytics.
Affected Files
Root Cause
Follow relationships reference usernames rather than immutable user identifiers.
When usernames change, historical records become disconnected from the current account identity.
Reproduction
Expected Behavior
Follow relationships should remain stable regardless of username changes.
Actual Behavior
Username changes affect relationship consistency.
Why This Is Difficult To Detect
The issue only appears after account renames.
Most follow testing uses static usernames.
Production Impact
Suggested Fix
Store immutable user IDs rather than mutable usernames.
Severity
Medium-High