Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Control errores y testing en get_location_info #17

Open
koldLight opened this issue Oct 29, 2020 · 0 comments
Open

Control errores y testing en get_location_info #17

koldLight opened this issue Oct 29, 2020 · 0 comments

Comments

@koldLight
Copy link
Contributor

koldLight commented Oct 29, 2020

En la función get_location_info, habría que:

  • Añadir un control de errores: hay más info en la conversación de la issue Estandarizar gestión de errores en las llamadas a la API #10

    • Si no se encuentra (p.e. lat, lon de input (0, 0)), se devuelve {}, sin hacer saltar ninguna excepción.
    • Añadir argumento a función que sea error, que admite los valores raise (por defecto) e ignore. Si se elige ignore, la función devuelve {}. Si se elige raise, saltará la excepción. Para esto último, se puede utilizar raise_for_status (doc
  • Añadir testing

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant