Flagsmith / Flagsmith/flagsmith

`identities_v2` table has a lot of overrides for deleted features

Open
#6,098 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
6.6k
Forks
567
Avg merge
1d 14h
Merged PRs (30d)
124

Description

After https://github.com/Flagsmith/flagsmith/pull/5080, we did not retroactively update the table, which resulted in a large number of stale override data which affects limits/pagination.

We need a management command that iterates over every v2 document, cross-checks the key with current feature ids in the main environment document, and removes the document if the key is stale.

Contributor guide

Open the contributing guide

Research direction

Start by locating the management-command entry point and the code representing the identities_v2 and main environment documents. Verify how feature IDs are compared, then confirm that stale v2 documents are removed and no longer affect limits or pagination.

Written by the indexing model from the issue text.

Assessment

Tech stack
python
Domain
backend, databases
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.