graphql-python / graphql-python/graphene
Is it necessary to prevent a datasclass field name from being a Python keyword?
- Lenguaje dominante
- Python
- Estrellas
- 8.2k
- Forks
- 818
- Métricas de merge de PR
- Sin PR fusionados en 30 d
Descripción
I ran into this error when dynamically creating an dataclass:
"Field names must not be keywords: {name!r}"
https://github.com/graphql-python/graphene/blob/master/graphene/pyutils/dataclasses.py#L1196-L1197
The field names come from a defined external dataset, and one field name happens to be a Python keyword, but I don't think that causes any harm.
Guía de contribución
No hay ninguna guía de contribución indexada para este repositorio
Línea de trabajo
Start by reading graphene/pyutils/dataclasses.py around lines 1196–1197 and trace how dynamically created dataclass field names are handled. Determine whether rejecting Python keywords is required for this path and define the expected behavior for field names from external datasets before identifying the necessary coverage.
Escrito por el modelo de indexación a partir del texto del issue.
Evaluación
- Stack tecnológico
- python
- Área
- backend-api-design
- Tipo de issue
- Nueva funcionalidad
- Dificultad
- 4/5
- Tiempo estimado
- 3-5 días
- Estado de actividad
- Estancado
- Claridad
- Necesita aclaración
- Aptitud para principiantes
- 30/100