graphql-python / graphql-python/graphql-core-legacy
`print_schema` should be deterministic
- Vorherrschende Sprache
- Python
- Sterne
- 372
- Forks
- 175
- PR-Merge-Kennzahlen
- Keine gemergten PRs in 30 T.
Beschreibung
In our project, we commit a graphql schema to our repo. This is useful for running demos, tests and mocking data.
However, now we also want to be able to ensure that the schema is kept up-to-date with a CI check. Unfortunately, printing the schema twice, seems to not be guaranteed to print values in the same order (especially keys in object types, and field arguments). This makes consistency checks significantly harder.
It'd be great if there was a guarantee of determinism. Running the printer repeatedly, against a given schema always outputs the same file.
Beitragsleitfaden
Für dieses Repository ist kein Beitragsleitfaden indexiert
Rechercherichtung
Beginne damit, den Einstiegspunkt print_schema und alle Tests zu finden, die die Schemaausgabe abdecken. Prüfe, wie Objektfelder und Feldargumente geordnet sind, und verifiziere anschließend, dass das wiederholte Ausgeben desselben Schemas eine identische Ausgabe erzeugt.
Vom Indexierungsmodell aus dem Issue-Text verfasst.
Bewertung
- Tech-Stack
- graphql, python
- Bereich
- api, backend
- Issue-Typ
- Feature
- Schwierigkeit
- 3/5
- Geschätzter Aufwand
- 1-2 Tage
- Aktivitätsstatus
- Veraltet
- Klarheit
- Größtenteils klar
- Anfängerfreundlichkeit
- 35/100