Project

General

Profile

Bug #22745

templates: erreur lors du calcul du type mime d'un fichier supprimé sur le disque

Added by Serghei Mihai over 1 year ago. Updated over 1 year ago.

Status:
Fermé
Priority:
Normal
Assignee:
-
Target version:
Start date:
22 Mar 2018
Due date:
% Done:

100%

Patch proposed:
Yes
Planning:
No

Description

Detecté dans les templates.
La classe pour afficher l'icone du type de document est: mime-cannot open `test.pdf' (No such file or directory) mime-cannot open `test-pdf' (No such file or directory)

0001-models-handle-ENOENT-from-file-magic-22745.patch View (2.35 KB) Benjamin Dauvergne, 23 Mar 2018 02:21 PM

Associated revisions

Revision a102c7d7 (diff)
Added by Benjamin Dauvergne over 1 year ago

models: handle ENOENT from file-magic (fixes #22745)

magic.Magic.file() does not return None or raise an exception on a
missing file, it just return the string "cannot open ...".

History

#2 Updated by Benjamin Dauvergne over 1 year ago

Un fichier supprimé sur le disque ça ne doit pas arriver.

#3 Updated by Serghei Mihai over 1 year ago

Je suis d'accord. Mais quand ça arrive, ça ne devrait pas casser un nom de classe css :)

#4 Updated by Benjamin Dauvergne over 1 year ago

#5 Updated by Serghei Mihai over 1 year ago

Le raise est en trop dans:

        raise Exception
        return None

#6 Updated by Benjamin Dauvergne over 1 year ago

  • Status changed from Nouveau to Résolu (à déployer)
  • % Done changed from 0 to 100

#7 Updated by Benjamin Dauvergne over 1 year ago

  • Target version set to 0.25

#8 Updated by Frédéric Péters over 1 year ago

  • Status changed from Résolu (à déployer) to Fermé

Also available in: Atom PDF