← Back to team overview

phatch-dev team mailing list archive

[Bug 532194] Re: Test suite should not try to perform jpeg actions on other file types

 

** Tags added: test

-- 
Test suite should not try to perform jpeg actions on other file types
https://bugs.launchpad.net/bugs/532194
You received this bug notification because you are a member of Phatch
Developers, which is subscribed to Phatch.

Status in Phatch = Photo & Batch!: Confirmed

Bug description:
This is spamming the test logs.

actionlist: /home/stani/Desktop/repo/lucid/tests/output/actionlists/delete_tags_Method=One.phatch
Error 0:Can not apply action Delete Tags on image 'bee.png' in folder:
/home/stani/Desktop/repo/lucid/tests/input

Format PNG does not support overwriting "Exif_Image_ImageDescription".

Action:{'fields': {'Method': u'One',
            'Tag': 'Exif_Image_ImageDescription',
            '__enabled__': 'yes'},
 'label': 'Delete Tags'}

Traceback (most recent call last):
  File "/home/stani/Desktop/repo/lucid/phatch/core/api.py", line 617, in apply_action_to_photo
    photo = action.apply(photo, read_only_settings, cache)
  File "/home/stani/Desktop/repo/lucid/phatch/actions/delete_tags.py", line 46, in apply
    del info[tag]
  File "/home/stani/Desktop/repo/lucid/phatch/core/pil.py", line 317, in __delitem__
    self.assert_writable(tag)
  File "/home/stani/Desktop/repo/lucid/phatch/core/pil.py", line 426, in assert_writable
    % {'format': self['format'], 'tag': tag})
NotWritableTagError: Format PNG does not support overwriting "Exif_Image_ImageDescription".

actionlist: /home/stani/Desktop/repo/lucid/tests/output/actionlists/lossless_jpeg_UpdateJPEG=1_UpdateOriTag=1_ShowAdvancedOps=1_Trafo=Automatic_UpdateExifThumb=0_Util=Exiftran.phatch
Error 0:Can not apply action Lossless JPEG on image 'bee.png' in folder:
/home/stani/Desktop/repo/lucid/tests/input

Lossless JPEG transformation does not work on a PNG image::
/home/stani/Desktop/repo/lucid/tests/input/bee.png

Action:{'fields': {'All': '30%',
            'Angle': u'180 degrees',
            'Angle ': u'270 degrees',
            'Bottom': '0px',
            'Copy': u'All',
            'Direction': u'Vertical',
            'Direction ': u'Vertical',
            'File Name': u'<filename>_lossless_jpeg_UpdateJPEG=1_UpdateOriTag=1_ShowAdvancedOps=1_Trafo=Automatic_UpdateExifThumb=0_Util=Exiftran',
            'In': u'/home/stani/Desktop/repo/lucid/tests/output/images',
            'Left': '0px',
            'Mode': u'Custom',
            'Preserve Timestamp': 'no',
            'Right': '0px',
            'Show Advanced Options': 'yes',
            'Top': '0px',
            'Transformation': u'Automatic (use exif orientation)',
            'Transformation ': u'Transverse',
            'Update Exif Thumbnail': 'no',
            'Update JPEG': 'yes',
            'Update Orientation Tag': 'yes',
            'Utility': u'Exiftran (with exif support)',
            '__enabled__': 'yes'},
 'label': 'Lossless JPEG'}

Traceback (most recent call last):
  File "/home/stani/Desktop/repo/lucid/phatch/core/api.py", line 617, in apply_action_to_photo
    photo = action.apply(photo, read_only_settings, cache)
  File "/home/stani/Desktop/repo/lucid/phatch/actions/lossless_jpeg.py", line 252, in apply
    self.call(photo, info, utility)
  File "/home/stani/Desktop/repo/lucid/phatch/actions/lossless_jpeg.py", line 273, in call
    % (LOSSLESS_JPEG_FORMAT_ERROR % format, info['path']))
Exception: Lossless JPEG transformation does not work on a PNG image::
/home/stani/Desktop/repo/lucid/tests/input/bee.png
*







References