studioego / cjklib

Automatically exported from code.google.com/p/cjklib
Other
0 stars 0 forks source link

SqlAlchemy changed exceptions to exc #15

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
When I tried to install CEDICT using the installcjkdict command, I ran into an 
error, that says that the module exceptions (sqlalchemy) could not be found. I 
made sure that SQLAlchemy was installed and went to check if the module was 
there. It turns out SQL Alchemy has changed their exceptions.py into exc.py - 
changing the two instances where exceptions were imported (init.py and build.py 
in the build directory of cjklib) into exc solved the problem.

I used this on a Macbook Pro using Lion. I wonder if this is a problem with me, 
or just code that has to be changed, because according to SQLAlchemy 
(http://www.sqlalchemy.org/CHANGES) the module can be called with both names. 
It did not work that way for me.

The installation worked in the end. I'm just bringing this issue to the front.

Original issue reported on code.google.com by niel...@gmail.com on 16 Sep 2011 at 11:54

GoogleCodeExporter commented 9 years ago
I made the same changes, and it installs fine, but when I run a simple command 
like:

cjknife -i 周

it gives me a whole slew of error messages, ending with:

sqlalchemy.exc.OperationalError: (OperationalError) unknown database "cedict_0" 
'PRAGMA "cedict_0".table_info("CFDICT")' ()

What am I doing wrong?  Thanks in advance.

Original comment by victor....@gmail.com on 1 Oct 2011 at 3:37

GoogleCodeExporter commented 9 years ago
I'm having the same experience as victor.  'installcjkdict' wouldn't work, so I 
made the changes niel suggested and 'installcjkdict' successfully installed 
CEDICT.  Any attempt to use CEDICT portions of cjklib through cjknife or code 
result int the error victor mentions above.

I'm running Ubuntu 11.10 / Python 2.7.2.

Original comment by Jivan%ji...@gtempaccount.com on 13 Nov 2011 at 11:48

GoogleCodeExporter commented 9 years ago
After installation, as you guys have done, I still can't get the program to 
work.

Let's hope for an update from the creator.

Original comment by niel...@gmail.com on 15 Nov 2011 at 2:53

GoogleCodeExporter commented 9 years ago
Sorry, I'm pretty busy the next days. I'll try to catch up with this, but I 
can't vouch for anything for now. If this is because of a version change in 
sqlalchemy, try installing an older version for now if that is possible.

Original comment by christop...@gmail.com on 15 Nov 2011 at 3:01

GoogleCodeExporter commented 9 years ago
If you're using pip (sudo apt-get install python-pip)

Downgrade to sqlalchemy 0.6.8

sudo pip install -U sqlalchemy=0.6.8

installcjkdict --local cedict
installcjkdict --download CFDICT

http://www.chinaboard.de/cfdict.php?mode=dl (gives this error there 
Template->loadfile(): No files found for handle body)

Cannot read download page

Original comment by fellow.l...@gmail.com on 19 Dec 2011 at 10:41

GoogleCodeExporter commented 9 years ago
Pardon me, it's sudo pip install -U sqlalchemy==0.6.8

With 2 ='s

Original comment by fellow.l...@gmail.com on 21 Dec 2011 at 11:59

GoogleCodeExporter commented 9 years ago
Created ticket for sqlalchemy for this: 
http://www.sqlalchemy.org/trac/ticket/2433

Original comment by javier.r...@gmail.com on 13 Mar 2012 at 11:00

GoogleCodeExporter commented 9 years ago
It's not a problem with sqlalchemy.  Just change all references to 
sqlalchemy.exceptions to sqlarchemy.exc, in cjklib/build/*.py; 
sqlalchemy.exceptions has been deprecated for some time, it seems.

Original comment by julian.s...@gmail.com on 14 Mar 2012 at 12:54

GoogleCodeExporter commented 9 years ago
I created the ticket because they provide an alias that doesn't work.
Of course, I know how to patch it but it is no solution.

Original comment by javier.r...@gmail.com on 14 Mar 2012 at 1:36

GoogleCodeExporter commented 9 years ago
With the new release of cjklib (0.3.2) this should be fixed.

Thanks all for contributing and sorry for the long delay.

Original comment by christop...@gmail.com on 23 May 2012 at 7:58

GoogleCodeExporter commented 9 years ago
@fellow.linguist your issue with CFDICT should have also been fixed. CFDICT 
moved to a new website.

@victor.kam your issue seems to be an incompatibility with SQLAlchemy >= 0.7. 
For now cjklib needs to be installed with something below that.

Original comment by christop...@gmail.com on 23 May 2012 at 8:01