Decimal problem

durumdara durumdara at gmail.com
Thu Jun 10 15:45:29 EDT 2010


Hi!

In the prev. week I tested my home Python projects with KinterBasDB
embedded, PsyCOPG, and SQLite.

All of them worked well, and everything was good.

But the database blob table deletion was slow in SQLite, so I thought
I will try this with FireBird and PGSQL.

Today I tried to copy the SQLite DataBase into FireBird, and PGSQL.

Psycopg drop this error:

import psycopg2
pdb = psycopg2.connect("dbname=testx user=postgres password=x")

C:\Python26\lib\site-packages\psycopg2\__init__.py:62: RuntimeWarning:
can't import decimal module probably needed by _psycopg
RuntimeWarning)

I wondered, because this was working before...

Then I tried to start KinterBasDB:

  File "C:\Python26\lib\site-packages\kinterbasdb\__init__.py", line
478, in con
nect
    return Connection(*args, **keywords_args)
  File "C:\Python26\lib\site-packages\kinterbasdb\__init__.py", line
644, in __i
nit__
    self._normalize_type_trans()
  File "C:\Python26\lib\site-packages\kinterbasdb\__init__.py", line
1047, in _n
ormalize_type_trans
    self.set_type_trans_out(_NORMAL_TYPE_TRANS_OUT)
  File "C:\Python26\lib\site-packages\kinterbasdb\__init__.py", line
1073, in se
t_type_trans_out
    return _k.set_Connection_type_trans_out(self._C_con, trans_dict)
  File "C:\Python26\lib\site-packages\kinterbasdb\__init__.py", line
1907, in _m
ake_output_translator_return_type_dict_from_trans_dict
    return_val = translator(sample_arg)
  File "C:\Python26\lib\site-packages\kinterbasdb
\typeconv_fixed_decimal.py", li
ne 91, in fixed_conv_out_precise
    from decimal import Decimal
ImportError: cannot import name Decimal

I deleted my complete Python with all packages, and I reinstalled it.
But the problem also appeared...

What is this? And what the hell happened in this machine that
destroyed my working python apps...?

Thanks:
   dd





More information about the Python-list mailing list