waschinski / photo-stream

Self-hosted, super simple photo stream
https://github.com/waschinski/photo-stream
MIT License
448 stars 68 forks source link

any file with -original etc in it, breaks #40

Open seanwatkins opened 1 year ago

seanwatkins commented 1 year ago

Anytime a photo is in /photos/original

if it has a filename with original, eg

 BMAB1537-original.jpg

This happens:

W, [2022-09-09T02:32:34.155186 #1]  WARN -- : Badly formed IFD: Infinity
  Liquid Exception: No such file or directory @ rb_sysopen - photos/original/VMAA2435-original-686656.jpg in feed.xml

Renaming the file, and deleting it like this... works

/share/BIG/Pictures/photo-stream/original % convert BMAB1537-original.jpg BMABMAB1537.jpg
/share/BIG/Pictures/photo-stream/original % ls -al BMAB1537-original.jpg BMABMAB1537.jpg
-rw-rw-r-- 1 sean 332348 Sep  8 20:12 BMAB1537-original.jpg
-rw-rw-r-- 1 sean 332319 Sep  8 20:31 BMABMAB1537.jpg
 /share/BIG/Pictures/photo-stream/original % \rm BMAB1537-original.jpg
  Liquid Exception: No such file or directory @ rb_sysopen - /photo-stream/photos/original/VMAA2435-original.jpg in feed.xml
             Error: No such file or directory @ rb_sysopen - /photo-stream/photos/original/VMAA2435-original.jpg
             Error: Run jekyll build --trace for more information.

      Regenerating: 1 file(s) changed at 2022-09-09 02:32:36
                    photos/original/VMAA2435-original.jpg
waschinski commented 1 year ago

convert doesn't rename only. Have you tried using mv instead and does that fix it too? Just to make sure this is not a different problem unrelated to the image name.