[CWB] Problems exporting

Andrés Chandía andres.chandia at upf.edu
Thu Apr 20 19:24:24 CEST 2023


I've seen this:

lib/concordance.inc.php: $cqp->execute("show +word
+{$Corpus->visualise_gloss_annotation} ");
lib/context.inc.php: $cqp->execute("show +word
+{$Corpus->visualise_gloss_annotation} ");
lib/concordance-ui.php: $cqp->execute("show +word
+{$Corpus->visualise_gloss_annotation} ");
lib/context-ui.php: $cqp->execute("show +word
+{$Corpus->visualise_gloss_annotation} ");

*... Andrés Chandía*


Missatge de Hardie, Andrew <a.hardie at lancaster.ac.uk> del dia dj., 20
d’abr. 2023 a les 19:18:

> The error is here:
>
>
>
>       string(13) "show +word + "
>
>
>
> It’s an invalid CQP command which looks like it’s down to a badly sety
> primary annotation value. I’ll investigate.
>
>
>
> best
>
>
>
> Andrew.
>
>
>
> *From:* cwb-bounces at sslmit.unibo.it <cwb-bounces at sslmit.unibo.it> *On
> Behalf Of *Andrés Chandía
> *Sent:* Thursday, April 20, 2023 5:18 PM
> *To:* Open source development of the Corpus WorkBench <cwb at sslmit.unibo.it
> >
> *Subject:* Re: [CWB] Problems exporting
>
>
>
> About the mail I've just sent, I'm definitely wrong because queries are
> working with other corpus...
>
>
> *... Andrés Chandía*
>
>
>
>
>
> Missatge de Andrés Chandía <andres.chandia at upf.edu> del dia dj., 20
> d’abr. 2023 a les 18:14:
>
> Hi Andrew, error seems to be generated on the sql query:
>
>
>
> About to run SQL:
>
>       SELECT * from saved_queries
>
>                                                                    where corpus     = 'bnc'
>
>                                                                    and query_mode   = 'sq_nocase'
>
>                                                                    and cqp_query    = '[word=\"word\"%c]'
>
>                                                                    and query_scope  = ''
>
>                                                                    and postprocess  = ''
>
>                                                                    and saved = 0
>
>                                                                    limit 1
>
>       /* from User: admin | Function: load_from_params() | 2023-Apr-20 18:01 */
>
>
>
> cqp_query goes  '[word=\"word\"%c]' where the characters *%c* are added
> generating the error (at least that seems to me) so, if this is the cause
> of the error, any idea on how to clean that or fix it,
>
> I see that %c characters in many files, so there is probably a typo in one
> of those files, which one? how could I get the file generating the problem?
>
> Again, I'm probably wrong... so I better add the complete php debugging...
>
>
>
> array(6) {
>
>   [1]=>
>
>   array(4) {
>
>     ["file"]=>
>
>     string(55) "/mnt/vmdata/corptedig-glif/cqpweb/lib/exiterror-lib.php"
>
>     ["line"]=>
>
>     int(380)
>
>     ["function"]=>
>
>     string(9) "exiterror"
>
>     ["args"]=>
>
>     array(1) {
>
>       [0]=>
>
>       array(7) {
>
>         [0]=>
>
>         string(69) "CQP reports an error! The CQP program sent back these error messages:"
>
>         [1]=>
>
>         string(19) "**** CQP ERROR ****"
>
>         [2]=>
>
>         string(10) "CQP Error:"
>
>         [3]=>
>
>         string(60) "CQP Syntax Error: syntax error, unexpected ';', expecting ID"
>
>         [4]=>
>
>         string(18) "show +word + ; <--"
>
>         [5]=>
>
>         string(43) "Ignoring subsequent input until next ';'..."
>
>         [6]=>
>
>         string(11) "PARSE ERROR"
>
>       }
>
>     }
>
>   }
>
>   [2]=>
>
>   array(4) {
>
>     ["file"]=>
>
>     string(45) "/mnt/vmdata/corptedig-glif/cqpweb/lib/cqp.php"
>
>     ["line"]=>
>
>     int(1798)
>
>     ["function"]=>
>
>     string(13) "exiterror_cqp"
>
>     ["args"]=>
>
>     array(1) {
>
>       [0]=>
>
>       array(6) {
>
>         [0]=>
>
>         string(19) "**** CQP ERROR ****"
>
>         [1]=>
>
>         string(10) "CQP Error:"
>
>         [2]=>
>
>         string(60) "CQP Syntax Error: syntax error, unexpected ';', expecting ID"
>
>         [3]=>
>
>         string(18) "show +word + ; <--"
>
>         [4]=>
>
>         string(43) "Ignoring subsequent input until next ';'..."
>
>         [5]=>
>
>         string(11) "PARSE ERROR"
>
>       }
>
>     }
>
>   }
>
>   [3]=>
>
>   array(7) {
>
>     ["file"]=>
>
>     string(45) "/mnt/vmdata/corptedig-glif/cqpweb/lib/cqp.php"
>
>     ["line"]=>
>
>     int(1850)
>
>     ["function"]=>
>
>     string(11) "shout_error"
>
>     ["class"]=>
>
>     string(3) "CQP"
>
>     ["object"]=>
>
>     object(CQP)#84 (21) {
>
>       ["has_been_disconnected":"CQP":private]=>
>
>       bool(false)
>
>       ["process":"CQP":private]=>
>
>       resource(5) of type (process)
>
>       ["pipe":"CQP":private]=>
>
>       array(3) {
>
>         [0]=>
>
>         resource(2) of type (stream)
>
>         [1]=>
>
>         resource(3) of type (stream)
>
>         [2]=>
>
>         resource(4) of type (stream)
>
>       }
>
>       ["last_registry_invoked":"CQP":private]=>
>
>       string(48) "/mnt/vmdata/corptedig-glif/corpora/cqp/registry/"
>
>       ["major_version"]=>
>
>       int(3)
>
>       ["minor_version"]=>
>
>       int(5)
>
>       ["revision_version"]=>
>
>       int(0)
>
>       ["revision_version_flagged_beta":"CQP":private]=>
>
>       bool(false)
>
>       ["compile_date"]=>
>
>       NULL
>
>       ["version_string"]=>
>
>       string(17) "CQP version 3.5.0"
>
>       ["status":"CQP":private]=>
>
>       int(1)
>
>       ["error_handler":"CQP":private]=>
>
>       string(13) "exiterror_cqp"
>
>       ["error_message":"CQP":private]=>
>
>       array(6) {
>
>         [0]=>
>
>         string(19) "**** CQP ERROR ****"
>
>         [1]=>
>
>         string(10) "CQP Error:"
>
>         [2]=>
>
>         string(60) "CQP Syntax Error: syntax error, unexpected ';', expecting ID"
>
>         [3]=>
>
>         string(18) "show +word + ; <--"
>
>         [4]=>
>
>         string(43) "Ignoring subsequent input until next ';'..."
>
>         [5]=>
>
>         string(11) "PARSE ERROR"
>
>       }
>
>       ["EOL":"CQP":private]=>
>
>       string(1) "
>
> "
>
>       ["progress_handler":"CQP":private]=>
>
>       bool(false)
>
>       ["gzip_path":"CQP":private]=>
>
>       string(0) ""
>
>       ["debug_mode":"CQP":private]=>
>
>       bool(true)
>
>       ["unbuffered_output_pending":"CQP":private]=>
>
>       bool(false)
>
>       ["pretty_suspended":"CQP":private]=>
>
>       bool(false)
>
>       ["corpus_charset":"CQP":private]=>
>
>       int(1)
>
>       ["last_set_corpus":"CQP":private]=>
>
>       string(3) "BNC"
>
>     }
>
>     ["type"]=>
>
>     string(2) "->"
>
>     ["args"]=>
>
>     array(0) {
>
>     }
>
>   }
>
>   [4]=>
>
>   array(7) {
>
>     ["file"]=>
>
>     string(45) "/mnt/vmdata/corptedig-glif/cqpweb/lib/cqp.php"
>
>     ["line"]=>
>
>     int(1101)
>
>     ["function"]=>
>
>     string(20) "check_pipe_for_error"
>
>     ["class"]=>
>
>     string(3) "CQP"
>
>     ["object"]=>
>
>     object(CQP)#84 (21) {
>
>       ["has_been_disconnected":"CQP":private]=>
>
>       bool(false)
>
>       ["process":"CQP":private]=>
>
>       resource(5) of type (process)
>
>       ["pipe":"CQP":private]=>
>
>       array(3) {
>
>         [0]=>
>
>         resource(2) of type (stream)
>
>         [1]=>
>
>         resource(3) of type (stream)
>
>         [2]=>
>
>         resource(4) of type (stream)
>
>       }
>
>       ["last_registry_invoked":"CQP":private]=>
>
>       string(48) "/mnt/vmdata/corptedig-glif/corpora/cqp/registry/"
>
>       ["major_version"]=>
>
>       int(3)
>
>       ["minor_version"]=>
>
>       int(5)
>
>       ["revision_version"]=>
>
>       int(0)
>
>       ["revision_version_flagged_beta":"CQP":private]=>
>
>       bool(false)
>
>       ["compile_date"]=>
>
>       NULL
>
>       ["version_string"]=>
>
>       string(17) "CQP version 3.5.0"
>
>       ["status":"CQP":private]=>
>
>       int(1)
>
>       ["error_handler":"CQP":private]=>
>
>       string(13) "exiterror_cqp"
>
>       ["error_message":"CQP":private]=>
>
>       array(6) {
>
>         [0]=>
>
>         string(19) "**** CQP ERROR ****"
>
>         [1]=>
>
>         string(10) "CQP Error:"
>
>         [2]=>
>
>         string(60) "CQP Syntax Error: syntax error, unexpected ';', expecting ID"
>
>         [3]=>
>
>         string(18) "show +word + ; <--"
>
>         [4]=>
>
>         string(43) "Ignoring subsequent input until next ';'..."
>
>         [5]=>
>
>         string(11) "PARSE ERROR"
>
>       }
>
>       ["EOL":"CQP":private]=>
>
>       string(1) "
>
> "
>
>       ["progress_handler":"CQP":private]=>
>
>       bool(false)
>
>       ["gzip_path":"CQP":private]=>
>
>       string(0) ""
>
>       ["debug_mode":"CQP":private]=>
>
>       bool(true)
>
>       ["unbuffered_output_pending":"CQP":private]=>
>
>       bool(false)
>
>       ["pretty_suspended":"CQP":private]=>
>
>       bool(false)
>
>       ["corpus_charset":"CQP":private]=>
>
>       int(1)
>
>       ["last_set_corpus":"CQP":private]=>
>
>       string(3) "BNC"
>
>     }
>
>     ["type"]=>
>
>     string(2) "->"
>
>     ["args"]=>
>
>     array(0) {
>
>     }
>
>   }
>
>   [5]=>
>
>   array(7) {
>
>     ["file"]=>
>
>     string(56) "/mnt/vmdata/corptedig-glif/cqpweb/lib/concordance-ui.php"
>
>     ["line"]=>
>
>     int(770)
>
>     ["function"]=>
>
>     string(7) "execute"
>
>     ["class"]=>
>
>     string(3) "CQP"
>
>     ["object"]=>
>
>     object(CQP)#84 (21) {
>
>       ["has_been_disconnected":"CQP":private]=>
>
>       bool(false)
>
>       ["process":"CQP":private]=>
>
>       resource(5) of type (process)
>
>       ["pipe":"CQP":private]=>
>
>       array(3) {
>
>         [0]=>
>
>         resource(2) of type (stream)
>
>         [1]=>
>
>         resource(3) of type (stream)
>
>         [2]=>
>
>         resource(4) of type (stream)
>
>       }
>
>       ["last_registry_invoked":"CQP":private]=>
>
>       string(48) "/mnt/vmdata/corptedig-glif/corpora/cqp/registry/"
>
>       ["major_version"]=>
>
>       int(3)
>
>       ["minor_version"]=>
>
>       int(5)
>
>       ["revision_version"]=>
>
>       int(0)
>
>       ["revision_version_flagged_beta":"CQP":private]=>
>
>       bool(false)
>
>       ["compile_date"]=>
>
>       NULL
>
>       ["version_string"]=>
>
>       string(17) "CQP version 3.5.0"
>
>       ["status":"CQP":private]=>
>
>       int(1)
>
>       ["error_handler":"CQP":private]=>
>
>       string(13) "exiterror_cqp"
>
>       ["error_message":"CQP":private]=>
>
>       array(6) {
>
>         [0]=>
>
>         string(19) "**** CQP ERROR ****"
>
>         [1]=>
>
>         string(10) "CQP Error:"
>
>         [2]=>
>
>         string(60) "CQP Syntax Error: syntax error, unexpected ';', expecting ID"
>
>         [3]=>
>
>         string(18) "show +word + ; <--"
>
>         [4]=>
>
>         string(43) "Ignoring subsequent input until next ';'..."
>
>         [5]=>
>
>         string(11) "PARSE ERROR"
>
>       }
>
>       ["EOL":"CQP":private]=>
>
>       string(1) "
>
> "
>
>       ["progress_handler":"CQP":private]=>
>
>       bool(false)
>
>       ["gzip_path":"CQP":private]=>
>
>       string(0) ""
>
>       ["debug_mode":"CQP":private]=>
>
>       bool(true)
>
>       ["unbuffered_output_pending":"CQP":private]=>
>
>       bool(false)
>
>       ["pretty_suspended":"CQP":private]=>
>
>       bool(false)
>
>       ["corpus_charset":"CQP":private]=>
>
>       int(1)
>
>       ["last_set_corpus":"CQP":private]=>
>
>       string(3) "BNC"
>
>     }
>
>     ["type"]=>
>
>     string(2) "->"
>
>     ["args"]=>
>
>     array(1) {
>
>       [0]=>
>
>       string(13) "show +word + "
>
>     }
>
>   }
>
>   [6]=>
>
>   array(4) {
>
>     ["file"]=>
>
>     string(53) "/mnt/vmdata/corptedig-glif/cqpweb/exe/concordance.php"
>
>     ["line"]=>
>
>     int(1)
>
>     ["args"]=>
>
>     array(1) {
>
>       [0]=>
>
>       string(56) "/mnt/vmdata/corptedig-glif/cqpweb/lib/concordance-ui.php"
>
>     }
>
>     ["function"]=>
>
>     string(7) "require"
>
>   }
>
> }
>
>
>
>
>
> Missatge de Andrés Chandía <andres.chandia at upf.edu> del dia dj., 20
> d’abr. 2023 a les 14:57:
>
> Sorry Josep, maybe Andrew is asking about cqpweb, if so....
>
> CQPweb v3.2.43 © 2008-2020
>
>
> *... Andrés Chandía*
>
>
>
>
>
> Missatge de Josep M. Fontana <josepm.fontana at upf.edu> del dia dj., 20
> d’abr. 2023 a les 14:55:
>
> OK. In the error message I see a reference to version 3.50 of CQP. I'm not
> sure whether that also corresponds to the version of CQPWeb.
>
> ```
> NULL
>
>       ["version_string"]=>
>
>       string(17) "CQP version 3.5.0"
>
>       ["status":"CQP":private]=>
>
>       int(1)
>
> ```
>
> JM
>
> On 20/4/23 14:38, Hardie, Andrew wrote:
>
> Hi Josep,
>
>
>
> what version are you running?
>
>
>
> best
>
>
>
> Andrew.
>
>
>
> *From:* cwb-bounces at sslmit.unibo.it <cwb-bounces at sslmit.unibo.it>
> <cwb-bounces at sslmit.unibo.it> *On Behalf Of *Josep M. Fontana
> *Sent:* Thursday, April 20, 2023 1:28 PM
> *To:* cwb at sslmit.unibo.it
> *Subject:* [CWB] Problems exporting
>
>
>
> Hi there,
>
> I'm having problems using the 'Export corpus' functionality in cqpWeb.
>
> When I try:
>
> Corpus queries > Export corpus > Choose an export format: > Word-and-tag
> format (joined with forward-slash)
>
> or
>
> Corpus queries > Export corpus > Choose an export format: > Columnar with
> all tags (CWB input format)
>
> Whether it is as a 'single text file' or as 'zip file with separate files
> for each corpus text' , I always get a pop-up window with the message
> 'CQPweb is processing your request. Please wait.'
>
> This never goes away, though. Nothing seems to be exported. I don't know
> whether there is a connection, but in one of the attempts to export a
> corpus, the particular corpus I tried to export ceased to work and now I'm
> get this error message when I try to do a search:
>
> ```
>
> CQP reports an error! The CQP program sent back these error messages:
>
> **** CQP ERROR ****
>
> CQP Error:
>
> CQP Syntax Error: syntax error, unexpected ';', expecting ID
>
> show +word + ; <--
>
> Ignoring subsequent input until next ';'...
>
> PARSE ERROR
>
>
> ```
>
> This didn't happen before I try to export this corpus.
>
> I also don't know whether this is related but, whatever of our corpora I'm
> using, I often get this error message:
>
>
> ERROR: Redirect type unrecognised.
>
>             Please reload CQPweb.
>
> The problem gets solved by clicking on the link to reload CQPweb but it
> looks like this is a sign that something is wrong with our installation.
>
> I'm aware that there are a few different issues here and I will appreciate
> any help you can provide to solve them. My most pressing issue, though, is
> that I need to urgently export one of our corpora. We are working on a
> project where we need to process the tagged corpus outside CQPweb. The
> problem is that we cannot find the files with the tagged texts that were
> the basis for the CQPWeb installation of the corpus.
>
> I have browsed through the different folders connected to the CQPWeb
> installation in our server and I haven't been able to find any text files
> that would contain the word and the tag whether it is in the columnar 'CWB
> input format' or 'joined with forward-slash'.
>
> So, any help with being able to export the corpus via the CQPWeb interface
> or with identifying the relevant text files in the folder structure
> associated with the CQPWeb installation (would these files, if they do
> exist, have a specific extension that would help identifying them?) would
> be especially appreciated.
>
> Josep M.
>
>
>
>
> _______________________________________________
>
> CWB mailing list
>
> CWB at sslmit.unibo.it
>
> http://liste.sslmit.unibo.it/mailman/listinfo/cwb
>
> _______________________________________________
> CWB mailing list
> CWB at sslmit.unibo.it
> http://liste.sslmit.unibo.it/mailman/listinfo/cwb
>
> _______________________________________________
> CWB mailing list
> CWB at sslmit.unibo.it
> http://liste.sslmit.unibo.it/mailman/listinfo/cwb
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://liste.sslmit.unibo.it/pipermail/cwb/attachments/20230420/546889af/attachment-0001.html>


More information about the CWB mailing list