docs: Clarify which flag operations require change requests vs which bypass

Aperta Adatta ai principianti
#7,506 1 commento 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

  • #7548 di @SahilJat — chiusa senza merge

Valutazione

Difficoltà
2/5
Tempo stimato
1-3 ore
Idoneità per principianti
75/100
Tipo di issue
Documentazione
Chiarezza
Specificata chiaramente
Stato di attività
Tranquilla
Stack tecnologico
python
Ambito
documentation

Direzione di ricerca

Inizia dalla pagina della documentazione dei change requests e confronta la formulazione attuale con il tipo FeatureState e la logica is_live in api/features/models.py. Documenta che i valori predefiniti dell’ambiente e gli override dei segmenti richiedono change requests quando sono abilitati, mentre gli override a livello di identità sono attivi immediatamente e bypassano il workflow. Il lavoro è completo quando la pagina spiega chiaramente questa distinzione e il motivo per cui esiste.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

docs

Current state

The change requests docs page generically says "attempting to change a flag value will prompt you to create a new Change Request". The page does not distinguish between feature-state types and which trigger the CR workflow.

What the code does (verified in api/features/models.py)

FeatureState has three types determined by identity_id and feature_segment_id:

@property
def type(self) -> str:
    if self.identity_id and self.feature_segment_id is None:
        return IDENTITY
    elif self.feature_segment_id and self.identity_id is None:
        return FEATURE_SEGMENT
    elif self.identity_id is None and self.feature_segment_id is None:
        return ENVIRONMENT

The is_live property:

@property
def is_live(self) -> bool:
    if self.environment.use_v2_feature_versioning:
        if self.identity_id is not None:
            return True
        return (
            self.environment_feature_version_id is not None
            and self.environment_feature_version.is_live
        )

Identity-level feature states are live immediately. CRs are tied to versioning (environment_feature_version). Identity-level FS does not use versioning, so it is not gated by the CR workflow.

Implication for customers

  • Environment defaults: require CR when enabled
  • Segment overrides: require CR when enabled
  • Identity-level overrides: bypass CR; live immediately

Customers ask "why didn't this require approval?" when they don't see this distinction. The docs should make the scope explicit so the behavior is predictable.

Suggested docs addition

A small section under change requests describing which feature-state types the workflow applies to, and noting that identity-level overrides are live immediately and intentionally bypass the workflow (consistent with the use case of developer/QA targeting).

Lingua principale
Python
Stelle
9.9k
Fork
658
Merge medio
1g 15h
PR unite (30g)
168

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di Flagsmith/flagsmith

Tutte le issue di Flagsmith/flagsmith

Issue simili

Altre issue su Python

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.