[CWB] [ cwb-Bugs-1685850 ] Inconsistency in CQP exit codes

SourceForge.net noreply at sourceforge.net
Fri Feb 10 04:51:41 CET 2012


Bugs item #1685850, was opened at 2007-03-22 02:40
Message generated for change (Comment added) made by andrewhardie
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=722303&aid=1685850&group_id=131809

Please note that this message will contain a full copy of the comment thread,
including the initial issue submission, for this request,
not just the latest update.
Category: CQP engine
Group: TODO-4.0
Status: Open
Resolution: None
Priority: 3
Private: No
Submitted By: Peter Adolphs (futzilogik)
Assigned to: Stefan Evert (schtepf)
>Summary: Inconsistency in CQP exit codes

Initial Comment:
cqpcl always returns 0 as the exit code, also if an error occured. In case of error, it should return a non-zero exit code instead.

----------------------------------------------------------------------

>Comment By: Andrew Hardie (andrewhardie)
Date: 2012-02-09 19:51

Message:
Renamed bug, as cqpcl is depracated and therefore a wont-fix, but the same
consideration applies to the main CQP (and cqpserver?). 

I have now added in (between v 3.4.3 and 3.4.4) a global error variable
that can be used for this purpose; CQP tests this value to determine its
exit code. Fro 4.0 we need to make sure the error variable is set at any
point where an error happens that does not lead to an immediate abort. see
cqp/cqp.c, cqp/cqp.h

----------------------------------------------------------------------

Comment By: Stefan Evert (schtepf)
Date: 2009-08-17 12:08

Message:
A reasonable request, but unfortunately it didn't occur to the CWB
developer that CQP might want to keep track of its internal error status
(except by printing an error message on screen).  So there seems to be no
easy way for the cqpcl main loop to detect an error condition and signal it
to the calling program (except a syntax error in the command parser, which
should return an exit code of 1).

Current recommendation: use Perl's interactive CQP interface instead, which
catches the CQP error message.

----------------------------------------------------------------------

You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=722303&aid=1685850&group_id=131809


More information about the CWB mailing list