Projet

Général

Profil

Bug #41149

strasbourg, notifications, ValueError: No JSON object could be decoded

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

Statut:
Fermé
Priorité:
Normal
Assigné à:
Version cible:
-
Début:
30 mars 2020
Echéance:
% réalisé:

0%

Temps estimé:
Patch proposed:
Oui
Planning:
Non

Description

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

ValueError: No JSON object could be decoded
(2 additional frame(s) were not displayed)
...
  File "passerelle/contrib/strasbourg_eu/models.py", line 83, in notifications
    notifications = self.requests.post(url, data={'userId': name_id}).json()
  File "requests/models.py", line 850, in json
    return complexjson.loads(self.text, **kwargs)
  File "__init__.py", line 339, in loads
    return _default_decoder.decode(s)
  File "json/decoder.py", line 364, in decode
    obj, end = self.raw_decode(s, idx=_w(s, 0).end())
  File "json/decoder.py", line 382, in raw_decode
    raise ValueError("No JSON object could be decoded")

Error occurred while processing request

Fichiers


Demandes liées

Lié à Passerelle - Bug #41150: strasbourg, favoris, ValueError: No JSON object could be decodedRejeté30 mars 2020

Actions

Révisions associées

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

strasbourg eu: protect against service errors (#41149)

Historique

#1

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

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

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

  • Sujet changé de ValueError: No JSON object could be decoded à strasbourg, notifications, ValueError: No JSON object could be decoded
  • Assigné à mis à Frédéric Péters
#3

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

  • Lié à Bug #41150: strasbourg, favoris, ValueError: No JSON object could be decoded ajouté
#4

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

try/except pour tous les .json, pour gérer les moments où l'API foire.

#5

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

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

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 0d3a98adf9efb6d67955841c19dfa5f6a9a979db
Author: Frédéric Péters <fpeters@entrouvert.com>
Date:   Mon Mar 30 10:08:52 2020 +0200

    strasbourg eu: protect against service errors (#41149)
#7

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