summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFrédéric Péters <fpeters@entrouvert.com>2019-04-18 09:24:20 (GMT)
committerFrédéric Péters <fpeters@entrouvert.com>2019-05-09 08:13:38 (GMT)
commit90e5050dec4e347d41cb05bb0d610f82be256d78 (patch)
tree9bf5226a66c3b3c0097cc4b32069c0d19ce22c05
parentc281c34b7dbc5e22be41315fbb3c3bda4fcc366d (diff)
downloadpasserelle-grandlyon-cartads-cs-90e5050dec4e347d41cb05bb0d610f82be256d78.zip
passerelle-grandlyon-cartads-cs-90e5050dec4e347d41cb05bb0d610f82be256d78.tar.gz
passerelle-grandlyon-cartads-cs-90e5050dec4e347d41cb05bb0d610f82be256d78.tar.bz2
handle errors from zip upload webservicev0.1
-rw-r--r--grandlyon_cartads_cs/models.py3
1 files changed, 3 insertions, 0 deletions
diff --git a/grandlyon_cartads_cs/models.py b/grandlyon_cartads_cs/models.py
index a029318..34e24bd 100644
--- a/grandlyon_cartads_cs/models.py
+++ b/grandlyon_cartads_cs/models.py
@@ -89,3 +89,6 @@ class GLCartaDSCS(AbstractCartaDSCS):
}
)
resp.raise_for_status()
+ if resp.content:
+ # error messages are put in content, valid responses are empty.
+ raise Exception(resp.content)