Projet

Général

Profil

Bug #39863

paiement, bis, Unicode-objects must be encoded before hashing

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

Statut:
Fermé
Priorité:
Normal
Assigné à:
Catégorie:
-
Version cible:
-
Début:
14 février 2020
Echéance:
% réalisé:

0%

Temps estimé:
Patch proposed:
Oui
Planning:
Non

Description

Exception:
  type = '<class 'TypeError'>', value = 'Unicode-objects must be encoded before hashing'

Stack trace (most recent call first):
  File "/usr/lib/python3/dist-packages/auquotidien/modules/payments.py", line 106, in get_new_id
   104                 ''.join([r.choice(string.digits) for x in range(5)])
   105                 ])
>  106             crc = '%0.2d' % (ord(hashlib.md5(id).digest()[0]) % 100)
   107             id = id + '-' + crc
   108             if not self.has_key(id):

  locals:
     create = False
     id = '20200214-r1-f121-07258'
     r = <random.SystemRandom object at 0x55f7729eaf78>
     self = <Invoice id:None>


Fichiers

Révisions associées

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

update invoice CRC checks for Python 3 (#39863)

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

update invoice CRC checks for Python 3 (#39863)

Historique

#1

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

#2

Mis à jour par Nicolas Roche il y a environ 4 ans

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

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

  • Statut changé de Solution validée à Résolu (à déployer)
commit cc7dbb17d11bff3a8e3d14b800c3de8c674f3d37
Author: Frédéric Péters <fpeters@entrouvert.com>
Date:   Fri Feb 14 10:52:43 2020 +0100

    update invoice CRC checks for Python 3 (#39863)
#4

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

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

Formats disponibles : Atom PDF