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

Backoffice erreur - Site sans photo #57

Closed
camillemonchicourt opened this issue May 16, 2019 · 1 comment
Closed

Backoffice erreur - Site sans photo #57

camillemonchicourt opened this issue May 16, 2019 · 1 comment
Labels
bug Something isn't working

Comments

@camillemonchicourt
Copy link
Member

Si un site n'a pas de photo, alors le backoffice est en erreur et la liste des sites ne se charge pas. Un site devrait pouvoir ne pas avoir de photo.

Les logs indiquent :

[2019-05-16 18:48:12,120] ERROR in app: Exception on /api/sites [GET]
Traceback (most recent call last):
  File "/home/geopaysages/geopaysages/venv/lib/python3.5/site-packages/flask/app.py", line 2292, in wsgi_app
    response = self.full_dispatch_request()
  File "/home/geopaysages/geopaysages/venv/lib/python3.5/site-packages/flask/app.py", line 1815, in full_dispatch_request
    rv = self.handle_user_exception(e)
  File "/home/geopaysages/geopaysages/venv/lib/python3.5/site-packages/flask_cors/extension.py", line 161, in wrapped_function
    return cors_after_request(app.make_response(f(*args, **kwargs)))
  File "/home/geopaysages/geopaysages/venv/lib/python3.5/site-packages/flask/app.py", line 1718, in handle_user_exception
    reraise(exc_type, exc_value, tb)
  File "/home/geopaysages/geopaysages/venv/lib/python3.5/site-packages/flask/_compat.py", line 35, in reraise
    raise value
  File "/home/geopaysages/geopaysages/venv/lib/python3.5/site-packages/flask/app.py", line 1813, in full_dispatch_request
    rv = self.dispatch_request()
  File "/home/geopaysages/geopaysages/venv/lib/python3.5/site-packages/flask/app.py", line 1799, in dispatch_request
    return self.view_functions[rule.endpoint](**req.view_args)
  File "/home/geopaysages/geopaysages/backend/api.py", line 35, in returnAllSites
    id_photo=site.get('t_photos')[0])
IndexError: list index out of range
@xavyeah39
Copy link
Collaborator

Corrigé en v1.3.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants