PDA

View Full Version : Is an error supposed to leave no output file?



chrisjj
06-18-2011, 08:54 PM
I would have though so, but e.g.

Error converting to Windows Media Audio 10, 'xxx.flac' to 'xxx.wma'
md5 did not match decoded data, file is corrupt.

leaves an output file, condition unknown.

Spoon
06-19-2011, 07:21 AM
There is no file? if not overwriting then even the corrupt file should be left after conversion.

chrisjj
06-22-2011, 10:56 AM
There is no file?
As I said: it "leaves an output file"


if not overwriting then even the corrupt file should be left after conversion.

Are you saying a corrupt OUTPUT file should be left after failed conversion?

dbfan
06-22-2011, 04:57 PM
Yes

chrisjj
06-24-2011, 05:49 PM
Yes

Thanks. Do you have a workaround? I cannot afford there to be corrupt files.

Spoon
06-25-2011, 04:08 AM
See:

http://forum.dbpoweramp.com/showthread.php?t=24130

chrisjj
06-25-2011, 05:14 PM
See:

http://forum.dbpoweramp.com/showthread.php?t=24130

Thanks, but no workaround seen there.

Corrupt output files are a nightmare in well-managed projects. They wreck build management systems like MAKE and pollute data sets. Compliant command-line tools e.g. compilers leave either good output files or none.

Please do consider remedying this. I suggest CoreConverter.exe simply ensures that in event of error, no output file is left. Even if there was one present previously. Also, from Microsoft Command Line Standard http://technet.microsoft.com/en-us/library/ee156811.aspx


Required:

* Error messages (as well as VERBOSE and DEBUG messages) must be written to STDERR.

* Commands must terminate with an exit code indicating success (0) or failure (non-zero).


This would be a big improvement and make the program much more attractive to developers of production-grade integrations.

Thanks.

chrisjj
06-25-2011, 06:49 PM
* Error messages (as well as VERBOSE and DEBUG messages) must be written to STDERR.

Please ignore that - I see http://www.dbpoweramp.com/developer-cli-encoder.htm says error messaes already optionally go to STDERR.

dbfan
06-26-2011, 02:55 AM
The do, normally nothing would go to stderr

chrisjj
06-26-2011, 06:55 AM
The do, normally nothing would go to stderr

Could you clarify that?

Spoon
06-26-2011, 07:31 AM
STDERR if supplied is the process of getting error messages out of the converter.

chrisjj
06-26-2011, 10:09 PM
STDERR if supplied is the process of getting error messages out of the converter.
What do you mean by "if"? STDERR is always supplied - by the OS, when the process is created.

Spoon
06-27-2011, 03:07 AM
It is not always, a calling program can pass NULL handles.

chrisjj
06-28-2011, 02:59 PM
It is not always, a calling program can pass NULL handles.
Ah, I see. Thanks.

Please do have the return code indicate error! Until then, there is no way one can properly use the converter ins standard tools like MAKE. Thanks.

Spoon
06-29-2011, 04:33 AM
Perhaps for the next version.

chrisjj
07-10-2011, 06:46 AM
Perhaps for the next version.

Thanks. I shall keep my fingers crossed for that.