::Win10pro64-2004-CHCP 65001
Object: NOT have to resubmit processing tags for every -stay_open submission.
Question: is the -common_args values restricted to only exiftool I/O or Processing arguments?
Question is based on the following test results;
-with "-Description" on -common_args everything works,
except a "No file specified" error is thrown at the end. Without "-Description" error is not thrown.
-tested with multiple submissions, and error is thrown after the last -execute, as if it's on the -stay_open
or false literals.
If I've missed something in the docs let me know.
Thanks in advance
jon
PS D:>cat exiftoolpipe.txt
D:/image.jpg
-execute516
-stay_open
False
PS D:\> exiftool -stay_open true -@ D:/exiftoolpipe.txt -common_args -r -n -json -Description
[{
"SourceFile": "D:/image.jpg",
"Description": "this is image.jpg description"
}]
{ready516}
No file specified
PS D:\> exiftool -stay_open true -@ D:/exiftoolpipe.txt -common_args -r -n -json
[{
"SourceFile": "D:/image.jpg",
"ExifToolVersion": 12.01,
"FileName": "image.jpg",
"Directory": "D:/",
...deleted 16 lines
"BitsPerSample": 8,
"ColorComponents": 1,
"ImageSize": "5105 6792",
"Megapixels": 34.67316
}]
{ready516}
Hi Jon,
If you are only executing one command, then -execute is not necessary. After you say -stay_open false, the command continues with the remaining arguments. In the special case that there are no more arguments, no warning is given, but otherwise a warning is given if the final command has a problem.
If you know that this will be the last file processed, then don't use -execute.
But you raise a good point. If you don't know beforehand that you will be processing the last file, and you are using -common_args, then I can think of no way to terminate ExifTool without a warning if it is waiting in a -stay_open argfile. Hmm... I could maybe introduce a new option like -abort, but it seems like a bit much just to avoid the "No file specified" warning.
What do you think?
- Phil
How would -last, -final or -finalize or something in that nature sound?
Sounds maybe better. Or -exit or -end maybe. But my question was: Do you really think it would be worthwhile to add a new option just to avoid this warning message?
- Phil
Phil:
Is it worth it? Obviously I'm not promoting a breaking change or significant
code change. If the rest of the community has no concerns, then leave it as is.
I'll do a workaround by creating a fake submission before
the "-stay_open/nfalse/n". Maybe you could make a note in step 3
of the "-stay_open FLAG" documentation that the final submission
is not to be followed with an -execute command.
My concerns:
1) throwing an error which has to be handled
2) negates the use of {ready[NUM]}
3) you may not know it's the last submission set.
IE; use case of GUI where the user requires info from last submission to make the
determination of finalization.
I do really appreciate your "retirement time" and consideration.
Thanks again
jon
Hi Jon,
Yes, my biggest concern is the negation of {ready[NUM]} if you want to avoid the warning.
I'll think about this.
- Phil