openapi-generators / openapi-generators/openapi-python-client
Parsing Error
Personne n'a encore pris cette issue.
- Langage dominant
- Python
- Étoiles
- 2k
- Forks
- 293
- Merge moyen
- 34 min
- PR mergées (30 j)
- 1
Description
Describe the bug
I tried to parse the v3 openapi specification as can be downloaded here
https://apidocs.wyscout.com/
I ran
poetry run openapi-python-client generate --path path_to_file
It worked halfway. Quite a few of the model files were generated, but it was incomplete.
The error message I got was
File name too long:
'[...]wyscout-api-v-3-client/wyscout_api_v_3_client/models/match_events_a_response_element_object_substitution_fetch_the_substitutions_related_to_the_team_with_id_team_id_the_substitutions_related_to_match_p
eriod_match_period_the_substitution_that_happened_at_start_sec_seconds_elapsed_from_the_start_the_entrance_of_a_player_as_a_substitute.py'
which suggested that some fields that were not meant for parsing got parsed into a header.
OpenAPI Spec File
A link to an OpenAPI document which produces this issue. Ideally, write a minimal reproduction only containing the problematic pieces.
Desktop (please complete the following information):
- MacOS 15.1.1 (24B91)
- Python Version: 3.12.7
- openapi-python-client version 0.23.1
Additional context
Thank you for your help
Guide de contribution
Ouvrir le guide de contribution
Par où commencer
- Lisez l'issue en entier, puis le guide de contribution du projet.
- Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
- Forkez le dépôt et travaillez sur une branche.
- Ouvrez une pull request qui référence le numéro de l'issue.
Piste de recherche
Commencez par télécharger le document Wyscout OpenAPI v3 et relancez poetry run openapi-python-client generate --path path_to_file avec openapi-python-client 0.23.1. Suivez la génération du nom de fichier du modèle indiquée par le chemin models/match_events...py et déterminez comment les champs analysés longs produisent l’erreur du système de fichiers. La tâche est terminée lorsque la spécification est générée sans erreur filename-too-long et que la sortie est complète.
Rédigé par le modèle d'indexation à partir du texte de l'issue.
Évaluation
- Stack technique
- openapi, python
- Domaine
- api, tooling
- Type d'issue
- Bug
- Difficulté
- 4/5
- Temps estimé
- 3-5 jours
- Activité
- À l'abandon
- Clarté
- À clarifier
- Accessibilité débutants
- 35/100