microsoftgraph / microsoftgraph/msgraph-sdk-python-core
NationalClouds are wrongly prefixed
Nadie ha tomado este issue todavía.
- Lenguaje dominante
- Python
- Estrellas
- 288
- Forks
- 52
- Merge medio
- 8 h 10 min
- PR fusionados (30 d)
- 1
Descripción
Describe the bug
NationalClouds is defined in https://github.com/microsoftgraph/msgraph-sdk-python-core/blob/e54022acf0b0779ad471d324dae460175408d2c3/src/msgraph_core/_enums.py#L33-L43 where all values are prefixed by https,
however, since we pass them as allowed hosts to the AzureIdentityAuthenticationProvider by default in https://github.com/microsoftgraph/msgraph-sdk-python-core/blob/e54022acf0b0779ad471d324dae460175408d2c3/src/msgraph_core/authentication/azure_identity_authentication_provider.py#L22
they are fed to the AllowedHostsValidator which in https://github.com/microsoft/kiota-python/blob/b23edcbf268efdb81d14ef59cecc6c9565288248/packages/abstractions/kiota_abstractions/authentication/allowed_hosts_validator.py#L20 raises an exception if they are prefixed.
Expected behavior
The validator should either strip the urls or the enum should be updated.
How to reproduce
Instantiate an AzureIdentityAuthenticationProvider with default allowed hosts.
SDK Version
1.3.3
Latest version known to work for scenario above?
No response
Known Workarounds
Pass allowed_hosts manually.
Debug output
No response
Configuration
No response
Other information
No response
Guía de contribución
Primeros pasos
- Lee el issue completo y luego la guía de contribución del proyecto.
- Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
- Haz un fork del repositorio y trabaja en una rama.
- Abre un pull request que haga referencia al número del issue.
Línea de trabajo
Empieza por src/msgraph_core/_enums.py y src/msgraph_core/authentication/azure_identity_authentication_provider.py; después, inspecciona el allowed_hosts_validator.py de Kiota. Reproduce el problema instanciando AzureIdentityAuthenticationProvider con los hosts permitidos predeterminados. La corrección está completa cuando los valores predeterminados de NationalClouds se aceptan sin la excepción del validador, mientras que la configuración manual de hosts permitidos sigue siendo utilizable.
Escrito por el modelo de indexación a partir del texto del issue.
Evaluación
- Stack tecnológico
- azure, python
- Área
- authentication
- Tipo de issue
- Error
- Dificultad
- 3/5
- Tiempo estimado
- 1-2 días
- Estado de actividad
- Estancado
- Claridad
- Bastante claro
- Aptitud para principiantes
- 48/100