Got a question: for fun I did this over about 400 to 500 photos. I partially did it also to stress test it. But the HTML file is empty. Did I do something wrong? The rest of the folders are there.
Here is the output if someone is interested to brainstorm about this problem. I edited the output a bit to make it slightly more readable.
Scanning directories. Populating nav. Reading files........................... ................................ ................................ ............................................
.............................................................. .............................................................. .............................................................. .............................................................. .............................................................. ......................... Building HTML.......................................................... .............................................................. .............................................................. .............................................................. .............................................................. .............................................................. .............................................................. ................................................/Users/my_user _name/Downloads/Expose-master/expose.sh: line 139: /usr/bin/sed: Argument list too long Starting encode fotos0001 fotos0002 fotos0003 ...
... fotos0489 fotos0490 fotos0491
Anyways, I checked the image which was indeed corrupted, so ImageMagick was right on the money on that one. I still don't get it though why there's no HTML in the HTML file.
I do have reasons to believe this is the error. Currently I tested it with 10 photo's (corrupted image removed), 200, 100, 150 and now I'm doing 190 (note: numbers are a ball park estimate).
Interestingly, 200 didn't work, but it also gave the "/Users/mettamage/Downloads/Expose-master/expose.sh: line 139: /usr/bin/sed: Argument list too long" error, while the others did not. Edit: tested out all combinations. Argument list too long is indeed the error. I got this with 188 pictures:
Scanning directories.
Populating nav.
Reading files.........................................................................................................................................................................................
Building HTML........................................................................................................................................................................................
Starting encode
fotos0001
fotos0002
.. etc. And I got this with 189 pictures. Scanning directories.
Populating nav.
Reading files..........................................................................................................................................................................................
Building HTML........................................................................................................................................................................................./Users/mettamage/Downloads/Expose-master/expose.sh: line 139: /usr/bin/sed: Argument list too long Starting encode
fotos0001
fotos0002
... etc. xargs it is!
the templating system is basically just a sed regex. 500 files should be fine though, so my guess is that the imagemagick error was parsed as input to the template, and when the script tried to insert that message into the template it overflowed the pipe.
Do you still get the error if the corrupted image is removed? If the files aren't too big, could you post it somewhere?
Comments (73) 37 threads
Show all comments
Showing thread 7 of 37
Here is the output if someone is interested to brainstorm about this problem. I edited the output a bit to make it slightly more readable.
Scanning directories.
Populating nav.
Reading files...........................
................................
................................
............................................
..............................................................
..............................................................
..............................................................
..............................................................
..............................................................
.........................
Building
HTML..........................................................
..............................................................
..............................................................
..............................................................
..............................................................
..............................................................
..............................................................
................................................/Users/my_user
_name/Downloads/Expose-master/expose.sh: line 139:
/usr/bin/sed: Argument list too long
Starting encode
fotos0001
fotos0002
fotos0003
...
...
fotos0489
fotos0490
fotos0491
Anyways, I checked the image which was indeed corrupted, so ImageMagick was right on the money on that one. I still don't get it though why there's no HTML in the HTML file.
Maybe all of the filenames are passed as a single argument to sed?
Interestingly, 200 didn't work, but it also gave the "/Users/mettamage/Downloads/Expose-master/expose.sh: line 139: /usr/bin/sed: Argument list too long" error, while the others did not.
Edit: tested out all combinations. Argument list too long is indeed the error.
I got this with 188 pictures: Scanning directories. Populating nav. Reading files......................................................................................................................................................................................... Building HTML........................................................................................................................................................................................ Starting encode fotos0001 fotos0002 .. etc.
And I got this with 189 pictures.
Scanning directories. Populating nav. Reading files.......................................................................................................................................................................................... Building HTML........................................................................................................................................................................................./Users/mettamage/Downloads/Expose-master/expose.sh: line 139: /usr/bin/sed: Argument list too long
Starting encode fotos0001 fotos0002 ... etc.
xargs it is!
Do you still get the error if the corrupted image is removed? If the files aren't too big, could you post it somewhere?