-
-
Notifications
You must be signed in to change notification settings - Fork 202
Implement Safe Purge for Invalid Users in DevIndex Updater #9135
Copy link
Copy link
Closed
Labels
aibugSomething isn't workingSomething isn't workingenhancementNew feature or requestNew feature or request
Description
We need a mechanism to purge invalid entities (Organizations, deleted users) from the tracker.json index while ensuring we don't accidentally delete valid users due to API glitches.
The "Safe Purge" Protocol:
- Trigger:
Updater.mjscatches a fatal error (Could not resolve to a UserorNOT_FOUND). - Safety Check: Check if the user exists in
users.jsonl(Rich Data Store).- If Exists: This implies the user was valid in the past. Treat the 404 as suspicious (glitch, rename, suspension). Action: Move to Penalty Box (
failed.json) for manual review. Do NOT delete. - If NOT Exists: The user has never been indexed. It is likely a "Bad Seed" (Org, Bot, Typo) that leaked into the tracker. Action: Mark for deletion (
{ delete: true }) intracker.json.
- If Exists: This implies the user was valid in the past. Treat the 404 as suspicious (glitch, rename, suspension). Action: Move to Penalty Box (
Implementation:
- Modify
apps/devindex/services/Updater.mjsinsideprocessBatch. - Load
users.jsonl(or useStorage.getUsers()) to perform the existence check.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
aibugSomething isn't workingSomething isn't workingenhancementNew feature or requestNew feature or request