|Error using python client||Guy||9/29/12 2:01 PM|
I'm trying out the python client library on CB 2.0 and have run into the following error, from a very simple script. At the moment all it does is just try to instantiate a couchbase connection object but fails.
Here's the code:
from couchbase.client import Couchbase
cb = Couchbase("<server ip>:8091", '<bucket_name>', '<bucket_password>')
The error I get:
Traceback (most recent call last):
File "./testcb.py", line 7, in <module>
cb = Couchbase("10.210.94.180:8091", 'app', 'm1n1wh34t5')
File "/usr/local/lib/python2.6/dist-packages/couchbase/client.py", line 61, in __init__
self.couch_api_base = config["nodes"].get("couchApiBase")
TypeError: 'NoneType' object is unsubscriptable
Does anyone have an idea what the problem is?
|Re: Error using python client||Matt Ingenthron||9/29/12 2:04 PM|
That's not expected. What OS and specific version of Python do you have?
|Re: Error using python client||Guy||10/1/12 9:23 AM|
Oops, guess I need to check the error code for secure details before posting it! Anyway, here's the info you requested:
Ubuntu Lucid (10.04)
|Re: Error using python client||Pavel Paulau||10/2/12 8:55 AM|
I'm not sure that your test code is valid. Couchbase client expects "host:port", "username" and "password" parameters.
See this usage guide for details:
|Re: Error using python client||Roy E.||11/20/12 8:26 AM|
This happens when you try to connect your server behind a proxy and "requests" python library receives 504 Gateway Timeout error, eventually your object "config" on line #61 in couchbase/client.py becomes a None..