Projet

Général

Profil

Bug #65262

KeyError: 'data'

Ajouté par Sentry Io il y a presque 2 ans. Mis à jour il y a presque 2 ans.

Statut:
Fermé
Priorité:
Normal
Assigné à:
Version cible:
-
Début:
14 mai 2022
Echéance:
% réalisé:

0%

Temps estimé:
Patch proposed:
Oui
Planning:
Non

Description

https://sentry.entrouvert.org/entrouvert/publik/issues/58203/

KeyError: 'data'
(12 additional frame(s) were not displayed)
...
  File "combo/public/templatetags/combo.py", line 162, in render_cell
    return cell.render(context)
  File "combo/data/models.py", line 1346, in render
    context.update(self.get_cell_extra_context(context))
  File "combo/apps/wcs/models.py", line 906, in get_cell_extra_context
    extra_context = super().get_cell_extra_context(context)
  File "combo/apps/wcs/models.py", line 367, in get_cell_extra_context
    return {self.variable_name: self.get_data(context)}
  File "combo/apps/wcs/models.py", line 346, in get_data
    wcs_site['data'] = json_response['data']

Fichiers

Révisions associées

Révision e1f6c6e4 (diff)
Ajouté par Lauréline Guérin il y a presque 2 ans

api: fix form/carddata listing with unknown custom view (#65262)

Historique

#1

Mis à jour par Lauréline Guérin il y a presque 2 ans

  • Projet changé de Suivi des traces à Combo
#2

Mis à jour par Lauréline Guérin il y a presque 2 ans

  • Projet changé de Combo à w.c.s.

Je déplace ce ticket dans wcs:
L'url appelée est https://formulaires.tao.thononagglo.fr/api/cards/sun_inventaire_materiel/list/peripherique
mais si on met un truc bidon derrière (genre https://formulaires.tao.thononagglo.fr/api/cards/sun_inventaire_materiel/list/peripheriquefoobar) la réponse est la même: on récupère la fiche d'id 404

Dans ApiFormPageMixin._q_traverse:

                for view in self.get_custom_views(
                    [StrictNotEqual('visibility', 'owner'), Equal('slug', path[1])]
                ):
                    self._view = view
                    break
                else:
                    path = ['404']

#3

Mis à jour par Lauréline Guérin il y a presque 2 ans

#4

Mis à jour par Frédéric Péters il y a presque 2 ans

  • Statut changé de Solution proposée à Solution validée

Très joli.

#5

Mis à jour par Lauréline Guérin il y a presque 2 ans

j'envoie dans cette release ou dans la suivante ?

#6

Mis à jour par Frédéric Péters il y a presque 2 ans

ok pour celle-ci.

#7

Mis à jour par Lauréline Guérin il y a presque 2 ans

  • Statut changé de Solution validée à Résolu (à déployer)
commit e1f6c6e47c5d1a9745f96104c9b0508228e0e07d
Author: Lauréline Guérin <zebuline@entrouvert.com>
Date:   Tue May 17 16:24:18 2022 +0200

    api: fix form/carddata listing with unknown custom view (#65262)
#8

Mis à jour par Transition automatique il y a presque 2 ans

  • Statut changé de Résolu (à déployer) à Solution déployée
#9

Mis à jour par Transition automatique il y a plus d'un an

Automatic expiration

Formats disponibles : Atom PDF