Bug #47994
ZeroDivisionError sur des coordonnées géographiques foireuses dans l'exif
Statut:
Fermé
Priorité:
Normal
Assigné à:
-
Version cible:
-
Début:
23 octobre 2020
Echéance:
% réalisé:
0%
Temps estimé:
Patch proposed:
Oui
Planning:
Non
Description
i:Quitter -:PgPréc <Space>:PgSuiv v:Voir attach. d:Effacer r:Répondre j:Suivant ?:Aide Exception: type = '<class 'ZeroDivisionError'>', value = 'float division by zero' Stack trace (most recent call first): File "/usr/lib/python3/dist-packages/wcs/wf/geolocate.py", line 206, in geolocate_photo_variable 204 else: 205 # Pillow < 7.2 compat > 206 lat = (1.0*lat[0][0]/lat[0][1] + 1.0*lat[1][0]/lat[1][1]/60 + 1.0*lat[2][0]/lat[2][1]/3600) 207 lon = (1.0*lon[0][0]/lon[0][1] + 1.0*lon[1][0]/lon[1][1]/60 + 1.0*lon[2][0]/lon[2][1]/3600) 208 if lat_ref == 'S': locals: exif_data = {256: 4032, 257: 3024, 34853: {0: b'\x00\x00\x00\x00', 1: '\x00', 2: ((0, 0), (0, 0), (0, 0)), 3: '\x00', 4: ((0, 0), (0, 0), (0, 0)), 5: b'\x00', 6: (0, 0), 7: ((0, 0), (0, 0), (0, 0)), 27: b'\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00', 29: '\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00'}, 296: 2, 34665: 237, 271: 'samsung', 272: 'SM-N960F', 305: 'N960FXXS6ETHE', 274: 6, 531: 1, 306: '2020:10:23 10:21:31', 282: (72, 1), 283: (72, 1), 36864: b'0220', 37377: (691, 100), 37378: (252, 100), 36867: '2020:10:23 10:21:31', 36868: '2020:10:23 10:21:31', 37379: (587, 100), 37380: (0, 10), 37381: (252, 100), 37383: 2, 37385: 0, 40960: b'0100', 37386: (600, 100), 37510: b'\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00', 40961: 1, 37121: b'\x01\x02\x03\x00', 40962: 4032, 37520: '0938', 37521: '0938', 37522: '0938', 40963: 3024, 33434: (1, 120), 40965: 827, 33437: (240, 100), 41729: b'\x01\x00\x00\x00', 42016: 'J13LLKL00SM', 34850: 2, 41985: 0, 34855: 100, 41986: 0, 41987: 0, 41988: (0, 0), 41989: 52, 41990: 0, 41992: 0, 41993: 0, 41994: 0} formdata = <_wcs_Signalement-Frelons-Asiatiques 'Signaler un nid de frelons asiatiques - n°64-875' id:875> gps_info = {0: b'\x00\x00\x00\x00', 1: '\x00', 2: ((0, 0), (0, 0), (0, 0)), 3: '\x00', 4: ((0, 0), (0, 0), (0, 0)), 5: b'\x00', 6: (0, 0), 7: ((0, 0), (0, 0), (0, 0)), 27: b'\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00', 29: '\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00'} image = <PIL.JpegImagePlugin.JpegImageFile image mode=RGB size=4032x3024 at 0x7F3A63F8C7F0> lat = ((0, 0), (0, 0), (0, 0)) lat_ref = '\x00' lon = ((0, 0), (0, 0), (0, 0)) lon_ref = '\x00' self = <GeolocateWorkflowStatusItem 7> value = <PicklableUpload at 7f3a711c4208: ...>
Fichiers
Révisions associées
Historique
Mis à jour par Frédéric Péters il y a plus de 3 ans
- Fichier 0001-misc-ignore-malformed-exif-data-when-geolocating-fro.patch 0001-misc-ignore-malformed-exif-data-when-geolocating-fro.patch ajouté
- Statut changé de Nouveau à Solution proposée
- Patch proposed changé de Non à Oui
Mis à jour par Lauréline Guérin il y a plus de 3 ans
- Statut changé de Solution proposée à Solution validée
Mis à jour par Frédéric Péters il y a plus de 3 ans
- Statut changé de Solution validée à Résolu (à déployer)
commit 0aa4714e71a04491f6d81ac1d7cad584a17546bb Author: Frédéric Péters <fpeters@entrouvert.com> Date: Sun Nov 15 19:42:45 2020 +0100 misc: ignore malformed exif data when geolocating from image (#47994)
Mis à jour par Frédéric Péters il y a plus de 3 ans
- Statut changé de Résolu (à déployer) à Solution déployée
misc: ignore malformed exif data when geolocating from image (#47994)