[CWB] Error updating cqpweb
Hardie, Andrew
a.hardie at lancaster.ac.uk
Sun Jan 12 23:06:38 CET 2020
This suggests that you ran an unfinished version of the upgrade script for one version. Sorry – I try to avoid letting this be possible, but sometimes I slip up!
Andrew.
From: Jörg Knappen <j.knappen at mx.uni-saarland.de>
Sent: 10 January 2020 16:00
To: Open source development of the Corpus WorkBench <cwb at sslmit.unibo.it>
Cc: Hardie, Andrew <a.hardie at lancaster.ac.uk>
Subject: Re: [CWB] Error updating cqpweb
Hallo Andrew,
this is rather strange. I examined my production instance of cqpweb 3.20.31 and when my files are consistent (what I sincerely hope! at least, it worked for a full year for us) than the following is the case:
Upgrading the database from an older installation (as we did for the production instance) does not add the column sttr_1kw to the table corpus_info (verfied from looking at the database AND looking at the upgrade-database.php from that version)
BUT
Building the database from scratch (as I did in my test instance) already has the column sttr_1kw to the table corpus_info (verified from looking at the database AND looking into sql-definitions.inc.php at that version).
All other changes in the database are not affected by this difference.
Deleting the line causing the error resulted in a smooth upgrade on my test instance.
Greetings from Saarbrücken,
Jörg Knappen
Am 2020-01-09 21:42, schrieb Hardie, Andrew:
This error message indicates that you were already upgraded past the 3.2.31 point (partly or wholly). You can check this by looking at the commands inn upgrade-database.php lines 750 to 796, comparing them to your existing sql database, and seeing how many of them have already taken effect.
If you delete the lines for database changes that have already happened, the rest of script should run correctly.
BTW upgrade-database shouldn't normally require sudo.
best
Andrew
From: Jörg Knappen <j.knappen at mx.uni-saarland.de<mailto:j.knappen at mx.uni-saarland.de>>
Sent: 09 January 2020 20:26
To: Open source development of the Corpus WorkBench <cwb at sslmit.unibo.it<mailto:cwb at sslmit.unibo.it>>
Cc: Hardie, Andrew <a.hardie at lancaster.ac.uk<mailto:a.hardie at lancaster.ac.uk>>
Subject: Re: [CWB] Error updating cqpweb
OK, that was too risky. I restored the old version of cqpweb on my test server and tried an update within the 3.2-latest branch, leading to the following error:
sudo php upgrade-database.php
Current DB version is 3.2.31 ; target version is 3.2.40 . About to upgrade....
An SQL query did not run successfully!
Original query:
alter table `corpus_info` add column `sttr_1kw` float DEFAULT 0.0 after `size_bytes_freq`
/* from User: ??? | Function: upgrade_3_2_31() | 2020-Jan-09 21:21 */
Error # 1060: Duplicate column name 'sttr_1kw'
Greetings from Saarbrücken,
Jörg Knappen
Am 2020-01-07 22:00, schrieb Hardie, Andrew:
1406 was a commit to the trunk. The trunk is still thoroughly broken until v3.3.0 is finished! The 3.2 branch works.
Andrew.
________________________________
From: cwb-bounces at sslmit.unibo.it<mailto:cwb-bounces at sslmit.unibo.it> <cwb-bounces at sslmit.unibo.it<mailto:cwb-bounces at sslmit.unibo.it>> on behalf of Jörg Knappen <j.knappen at mx.uni-saarland.de<mailto:j.knappen at mx.uni-saarland.de>>
Sent: Tuesday, 7 January 2020, 5:03 pm
To: cwb at sslmit.unibo.it<mailto:cwb at sslmit.unibo.it>
Subject: [CWB] Error updating cqpweb
I tried to update our cqpweb installation to the most recent developer
version (revision 1406) and got the following error:
sudo php bin/upgrade-database.php
PHP Parse error: syntax error, unexpected ']', expecting '-' or
identifier (T_STRING) or variable (T_VARIABLE) or number (T_NUM_STRING)
in /data2/htdocs/cqpweb/bin/upgrade-database.php on line 321
Trying to run it without database upgrade produced a similar runtime
error from a different code location:
[Tue Jan 07 17:47:08.603359 2020] [php7:emerg] [pid 2503] [client
xxx.yyy.zzz.aaa:49958] PHP Parse error: syntax error, unexpected ''
(T_ENCAPSED_AND_WHITESPACE), expecting '-' or identifier (T_STRING) or
variable (T_VARIABLE) or number (T_NUM_STRING) in
/data2/htdocs/cqpweb/lib/sql-lib.php on line 2128
--Jörg Knappen
_______________________________________________
CWB mailing list
CWB at sslmit.unibo.it<mailto:CWB at sslmit.unibo.it>
https://eur02.safelinks.protection.outlook.com/?url=http%3A%2F%2Fliste.sslmit.unibo.it%2Fmailman%2Flistinfo%2Fcwb&data=02%7C01%7Ca.hardie%40lancaster.ac.uk%7C31f839722e0d424c711508d793938773%7C9c9bcd11977a4e9ca9a0bc734090164a%7C1%7C1%7C637140134170197160&sdata=LHgMxQmA3xxLLPI0OUMik1mys8zcPZr646YFbflo8xE%3D&reserved=0<https://eur02.safelinks.protection.outlook.com/?url=http%3A%2F%2Fliste.sslmit.unibo.it%2Fmailman%2Flistinfo%2Fcwb&data=02%7C01%7Ca.hardie%40lancaster.ac.uk%7C5cb6162d8b28477ea4d108d795e61ee2%7C9c9bcd11977a4e9ca9a0bc734090164a%7C1%7C0%7C637142687902520631&sdata=zgfPuIfXu5Aiv8SuVXZcSReUQS2W0yG1trSMoKiDR3I%3D&reserved=0>
_______________________________________________
CWB mailing list
CWB at sslmit.unibo.it<mailto:CWB at sslmit.unibo.it>
http://liste.sslmit.unibo.it/mailman/listinfo/cwb<https://eur02.safelinks.protection.outlook.com/?url=http%3A%2F%2Fliste.sslmit.unibo.it%2Fmailman%2Flistinfo%2Fcwb&data=02%7C01%7Ca.hardie%40lancaster.ac.uk%7C5cb6162d8b28477ea4d108d795e61ee2%7C9c9bcd11977a4e9ca9a0bc734090164a%7C1%7C0%7C637142687902520631&sdata=zgfPuIfXu5Aiv8SuVXZcSReUQS2W0yG1trSMoKiDR3I%3D&reserved=0>
_______________________________________________
CWB mailing list
CWB at sslmit.unibo.it<mailto:CWB at sslmit.unibo.it>
http://liste.sslmit.unibo.it/mailman/listinfo/cwb<https://eur02.safelinks.protection.outlook.com/?url=http%3A%2F%2Fliste.sslmit.unibo.it%2Fmailman%2Flistinfo%2Fcwb&data=02%7C01%7Ca.hardie%40lancaster.ac.uk%7C5cb6162d8b28477ea4d108d795e61ee2%7C9c9bcd11977a4e9ca9a0bc734090164a%7C1%7C0%7C637142687902530638&sdata=JUqIbm0WxPgmrxZJs2a%2Buw0Yl3AWuwJcVyyk1J1Vxfw%3D&reserved=0>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://liste.sslmit.unibo.it/pipermail/cwb/attachments/20200112/75d32024/attachment-0001.html>
More information about the CWB
mailing list