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

Abierto Apto para principiantes
#7,506 1 comentario 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 1 día

Nadie ha tomado este issue todavía.

  • #7548 de @SahilJat — cerrado sin fusionar

Evaluación

Dificultad
2/5
Tiempo estimado
1-3 horas
Aptitud para principiantes
75/100
Tipo de issue
Documentación
Claridad
Bien especificado
Estado de actividad
Tranquilo
Stack tecnológico
python

Línea de trabajo

Comienza con la página de documentación de change requests y compara su redacción actual con el tipo FeatureState y la lógica de is_live en api/features/models.py. Documenta que los valores predeterminados del entorno y las anulaciones de segmentos requieren change requests cuando están habilitados, mientras que las anulaciones a nivel de identidad se activan inmediatamente y omiten el flujo de trabajo. Se considerará terminado cuando la página explique claramente esta distinción y por qué existe.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

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).

Lenguaje dominante
Python
Estrellas
9.9k
Forks
658
Merge medio
1 d 15 h
PR fusionados (30 d)
168

Preparar el entorno

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de Flagsmith/flagsmith

Todos los issues de Flagsmith/flagsmith

Issues similares

Más issues de Python

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.