Problème sur réservation, puis sur portail connecthys

Plus d'informations
il y a 4 ans 5 mois #23726 par alsh multisite
Bonjour,
Depuis le passage à la version 0.7.8, les parents obtenaient un message d'erreurs lorsqu'ils accédaient à la page réservation :
Traceback (most recent call last):
  File "lib/flask/flask/app.py", line 1817, in wsgi_app
    response = self.full_dispatch_request()
  File "lib/flask/flask/app.py", line 1477, in full_dispatch_request
    rv = self.handle_user_exception(e)
  File "lib/flask/flask/app.py", line 1381, in handle_user_exception
    reraise(exc_type, exc_value, tb)
  File "lib/flask/flask/app.py", line 1475, in full_dispatch_request
    rv = self.dispatch_request()
  File "lib/flask/flask/app.py", line 1461, in dispatch_request
    return self.view_functions[rule.endpoint](**req.view_args)
  File "lib/flask_login.py", line 792, in decorated_view
    return func(*args, **kwargs)
  File "/home/connecthyssshmlb/connecthys/application/views.py", line 1077, in reservations
    models.Reservation_location.action.has(IDfamille=current_user.IDfamille),
  File "lib/flask/flask/templating.py", line 128, in render_template
    context, ctx.app)
  File "lib/flask/flask/templating.py", line 110, in _render
    rv = template.render(context)
  File "lib/jinja2/jinja2/environment.py", line 989, in render
    return self.environment.handle_exception(exc_info, True)
  File "lib/jinja2/jinja2/environment.py", line 754, in handle_exception
    reraise(exc_type, exc_value, tb)
  File "/home/connecthyssshmlb/connecthys/application/templates/reservations.html", line 2, in top-level template code
    {% import "macros_historique.html" as macros_historique with context %}
  File "/home/connecthyssshmlb/connecthys/application/templates/page.html", line 115, in top-level template code
    {% block page_body %}
  File "/home/connecthyssshmlb/connecthys/application/templates/page.html", line 159, in block "page_body"
    {% block content -%}
  File "/home/connecthyssshmlb/connecthys/application/templates/reservations.html", line 42, in block "content"
    {% if GetNbrePeriodesActives(individu.inscriptions_actives) == 0 %}
  File "/home/connecthyssshmlb/connecthys/application/utils.py", line 155, in GetNbrePeriodesActives
    nbre_periodes_actives = 0
UndefinedError: 'application.models.Individu object' has no attribute 'inscriptions_actives'

J'ai tenté de redémarrer le serveur, et là, le portail ne se lance même plus :
ERROR:tornado.access:500 GET /reservations (92.145.204.244) 62.92ms
INFO  [alembic.runtime.migration] Context impl MySQLImpl.
INFO  [alembic.runtime.migration] Will assume non-transactional DDL.
INFO  [alembic.autogenerate.compare] Detected added table 'portail_categories_produits'
INFO  [alembic.autogenerate.compare] Detected added table 'portail_locations'
INFO  [alembic.autogenerate.compare] Detected added index 'ix_portail_locations_IDfamille' on '['IDfamille']'
INFO  [alembic.autogenerate.compare] Detected added table 'portail_produits'
INFO  [alembic.autogenerate.compare] Detected added index 'ix_portail_produits_IDcategorie' on '['IDcategorie']'
INFO  [alembic.autogenerate.compare] Detected added table 'portail_reservations_locations'
INFO  [alembic.autogenerate.compare] Detected type change from MEDIUMTEXT() to String(length=100000) on 'portail_actions.ventilation'
INFO  [alembic.autogenerate.compare] Detected type change from MEDIUMTEXT() to String(length=100000) on 'portail_blocs.parametres'
INFO  [alembic.autogenerate.compare] Detected type change from MEDIUMTEXT() to String(length=100000) on 'portail_elements.parametres'
INFO  [alembic.autogenerate.compare] Detected type change from MEDIUMTEXT() to String(length=100000) on 'portail_elements.texte_html'
INFO  [alembic.autogenerate.compare] Detected type change from MEDIUMTEXT() to String(length=100000) on 'portail_paiements.ventilation'
INFO  [alembic.autogenerate.compare] Detected added column 'portail_users.parametres'
INFO  [alembic.runtime.migration] Context impl MySQLImpl.
INFO  [alembic.runtime.migration] Will assume non-transactional DDL.
INFO  [alembic.runtime.migration] Running upgrade  -> 019ea86f0506, empty message
lib/sqlalchemy/engine/default.py:450: Warning: (1246L, u"Converting column 'ventilation' from VARCHAR to TEXT")
  cursor.execute(statement, parameters)
lib/sqlalchemy/engine/default.py:450: Warning: (1246L, u"Converting column 'parametres' from VARCHAR to TEXT")
  cursor.execute(statement, parameters)
lib/sqlalchemy/engine/default.py:450: Warning: (1246L, u"Converting column 'texte_html' from VARCHAR to TEXT")
  cursor.execute(statement, parameters)

Est ce que quelqu'un à une idée pour réparer ça svp ?
Pour info, serveur ubuntu 18.04.4
SQL : MariaDB 10.1.44
Merci

Connexion ou Créer un compte pour participer à la conversation.

Plus d'informations
il y a 4 ans 5 mois #23727 par alsh multisite
Bon j'ai l'impression que c'est reparti. La mise à jour de connecthys avait remis le fichier run.py comme à l'origine...
Il a fallu que je le remodifie pour ma config (tornado avec certif let's encrypt)
Bonne journée à tous (et bon courage ;) )

Connexion ou Créer un compte pour participer à la conversation.

Temps de génération de la page : 0.280 secondes
Propulsé par Kunena