webpy/webpy — Issue #135: oracle pooling error
Author: xiangel
Created: 2012-02-01 05:37:30+00:00
State: open

I using oracle db with webpy. also i installed DBUtils.
# oracle doesn't support pooling
keywords.pop('pooling', None)
and in class DB default set pooling to true
self.has_pooling = self.keywords.pop('pooling', True) and self.has_pooling
so raise error:
Traceback (most recent call last):
File "D:\Python26\Lib\site-packages\pythonwin\pywin\framework\scriptutils.py", line 322, in RunScript
debugger.run(codeObject, __main__.__dict__, start_stepping=0)
File "D:\Python26\Lib\site-packages\pythonwin\pywin\debugger\__init__.py", line 60, in run
_GetCurrentDebugger().run(cmd, globals,locals, start_stepping)
File "D:\Python26\Lib\site-packages\pythonwin\pywin\debugger\debugger.py", line 655, in run
exec cmd in globals, locals
File "E:\study\python\study\test\test_webdb_oracle.py", line 5, in
result = db.query("select * from dual")
File "d:\python26\lib\site-packages\web.py-0.34-py2.6.egg\web\db.py", line 610, in query
db_cursor = self._db_cursor()
File "d:\python26\lib\site-packages\web.py-0.34-py2.6.egg\web\db.py", line 541, in _db_cursor
return self.ctx.db.cursor()
File "d:\python26\lib\site-packages\web.py-0.34-py2.6.egg\web\db.py", line 482, in _getctx
self._load_context(self._ctx)
File "d:\python26\lib\site-packages\web.py-0.34-py2.6.egg\web\db.py", line 491, in _load_context
ctx.db = self._connect_with_pooling(self.keywords)
File "d:\python26\lib\site-packages\web.py-0.34-py2.6.egg\web\db.py", line 538, in _connect_with_pooling
return self._pooleddb.connection()
File "d:\python26\lib\site-packages\DBUtils-1.0-py2.6.egg\DBUtils\PooledDB.py", line 293, in connection
con = self.steady_connection()
File "d:\python26\lib\site-packages\DBUtils-1.0-py2.6.egg\DBUtils\PooledDB.py", line 250, in steady_connection
*self._args, **self._kwargs)
File "d:\python26\lib\site-packages\DBUtils-1.0-py2.6.egg\DBUtils\SteadyDB.py", line 128, in connect
closeable, *args, **kwargs)
File "d:\python26\lib\site-packages\DBUtils-1.0-py2.6.egg\DBUtils\SteadyDB.py", line 179, in __init__
self._store(self._create())
File "d:\python26\lib\site-packages\DBUtils-1.0-py2.6.egg\DBUtils\SteadyDB.py", line 183, in _create
con = self._creator(*self._args, **self._kwargs)
InterfaceError: Unable to acquire Oracle environment handle

PS: my english is pool, so i'm not sure explain issures clearly.