Projet

Général

Profil

Development #36720

exception while calling hook <bound method AppConfig.a2_hook_api_modify_view_before_get_object of <AppConfig: authentic2_idp_oidc>>

Ajouté par Frédéric Péters il y a plus de 4 ans. Mis à jour il y a plus de 4 ans.

Statut:
Fermé
Priorité:
Normal
Assigné à:
Catégorie:
-
Version cible:
-
Début:
07 octobre 2019
Echéance:
% réalisé:

0%

Temps estimé:
Patch proposed:
Oui
Planning:
Non

Description

exception while calling hook <bound method AppConfig.a2_hook_api_modify_view_before_get_object of <AppConfig: authentic2_idp_oidc>>

AttributeError
'NoneType' object has no attribute 'identifier_policy'

Django Version: 1.11.20
Python Executable: /usr/bin/python
Python Version: 2.7.13
Python Path: ['/', '/usr/bin', '/usr/lib/python2.7', '/usr/lib/python2.7/plat-x86_64-linux-gnu', '/usr/lib/python2.7/lib-tk',
'/usr/lib/python2.7/lib-old', '/usr/lib/python2.7/lib-dynload', '/usr/local/lib/python2.7/dist-packages', '/usr/lib/python2.7/dist-packages',
'/usr/lib/python2.7/dist-packages/PILcompat', '/usr/lib/pymodules/python2.7']
Server time: lun, 7 Oct 2019 09:44:19 +0200
Installed Applications:
''
Installed Middleware:
''

Traceback:

File "/usr/lib/python2.7/dist-packages/authentic2/hooks.py" in call_hooks
  55.             yield hook(*args, **kwargs)

File "/usr/lib/python2.7/dist-packages/authentic2_idp_oidc/apps.py" in a2_hook_api_modify_view_before_get_object
  53.             if client.identifier_policy != client.POLICY_PAIRWISE_REVERSIBLE:

Exception Type: AttributeError
Exception Value: 'NoneType' object has no attribute 'identifier_policy'
Request data not supplied

C'est client qui est None; dans un appel là qui ne semble pas issu d'une requête.


Fichiers

Révisions associées

Révision cdc2cf56 (diff)
Ajouté par Benjamin Dauvergne il y a plus de 4 ans

idp_oidc: check client is not None (#36720)

Historique

#1

Mis à jour par Frédéric Péters il y a plus de 4 ans

(les traces sont peu nombreuses et groupées comme si un restart arrangeait les choses ?, la première saas test 3 octobre à 14h37).

#2

Mis à jour par Benjamin Dauvergne il y a plus de 4 ans

  • Assigné à mis à Benjamin Dauvergne
#3

Mis à jour par Benjamin Dauvergne il y a plus de 4 ans

#4

Mis à jour par Frédéric Péters il y a plus de 4 ans

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

Ok mais une idée de la situation / pourquoi ça arrive maintenant ?

#5

Mis à jour par Benjamin Dauvergne il y a plus de 4 ans

  • Statut changé de Solution validée à Résolu (à déployer)

Frédéric Péters a écrit :

Ok mais une idée de la situation / pourquoi ça arrive maintenant ?

Oui. Ce commit en factorisant du code, a modifié le comportement de cette fonction (avant on faisait un return si pas de oidc_client, ça s'est perdu).

commit d9918e3467b5adaba5cb519658b0e0d8a9fece4c
Author: Benjamin Dauvergne <bdauvergne@entrouvert.com>
Date:   Tue Sep 10 10:47:53 2019 +0200

    api: filter users based on OIDC client authorized roles (#35191)

#6

Mis à jour par Benjamin Dauvergne il y a plus de 4 ans

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

Mis à jour par Benjamin Dauvergne il y a plus de 4 ans

  • Statut changé de Solution validée à Résolu (à déployer)
commit cdc2cf567c090304f8006bcc332a11b26397229e
Author: Benjamin Dauvergne <bdauvergne@entrouvert.com>
Date:   Mon Oct 7 11:37:45 2019 +0200

    idp_oidc: check client is not None (#36720)
#8

Mis à jour par Frédéric Péters il y a plus de 4 ans

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

Formats disponibles : Atom PDF