Projet

Général

Profil

Bug #64336

erreur sur affichage bouton de navigation de page (ValueError: '51' is not in list)

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

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

0%

Temps estimé:
Patch proposed:
Oui
Planning:
Non

Description

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

ValueError: '51' is not in list
(13 additional frame(s) were not displayed)
...
  File "quixote/directory.py", line 88, in _q_traverse
    return obj._q_traverse(path)
  File "quixote/directory.py", line 88, in _q_traverse
    return obj._q_traverse(path)
  File "wcs/admin/fields.py", line 298, in _q_traverse
    return Directory._q_traverse(self, path)
  File "quixote/directory.py", line 92, in _q_traverse
    return obj()
  File "wcs/admin/fields.py", line 337, in _q_index
    previous_page_id = page_ids[page_ids.index(self.page_id) - 1]

[...]
PATH_INFO       '/backoffice/forms/719/fields/pages/51/'

On est sur la page avec l'id 51 mais cet id n'est pas dans page_ids,

Stack trace (most recent call first):
  File "/usr/lib/python3/dist-packages/wcs/admin/fields.py", line 337, in _q_index
   335                     r += htmltext('<a class="pk-button disabled" href=".">%s</a>') % _('Previous page')
   336                 else:
>  337                     previous_page_id = page_ids[page_ids.index(self.page_id) - 1]
   338                     r += htmltext('<a class="pk-button" href="../%s/">%s</a>') % (
   339                         previous_page_id,

  locals:
     page_ids = ['1', '7', '15', '32']

Fichiers

Révisions associées

Révision c36375b5 (diff)
Ajouté par Frédéric Péters il y a environ 2 ans

backoffice: redirect to all fields view when page field is removed (#64336)

Historique

#1

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

  • Projet changé de Suivi des traces à w.c.s.
#2

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

  • Assigné à mis à Frédéric Péters

Ça fait suite à une suppression du champ; avant ça n'était pas possible parce qu'on n'affichait pas sur une la page listant les champs d'une page le champ page lui-même (#61831).

#3

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

Boulet j'ai oublié de poster le patch.

#4

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

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

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

  • Statut changé de Solution validée à Résolu (à déployer)
commit c36375b5684c49bc3798521431292d68ffe170e2
Author: Frédéric Péters <fpeters@entrouvert.com>
Date:   Wed Apr 20 09:56:29 2022 +0200

    backoffice: redirect to all fields view when page field is removed (#64336)
#6

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

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

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

Automatic expiration

Formats disponibles : Atom PDF