pywebhooks
pywebhooks copied to clipboard
rethinkdb helper function
Good stuff, but when I tried to run docker-compose up
, stuff like rethink.connect()
or rethink.db_list()
are giving me some troubles. I suspect that we need to initialize rethinkdb object first?
For instance:
r = RethinkDB()
r.connect()
```
```python
import rethinkdb as rethink
from pywebhooks import DEFAULT_DB_NAME, RETHINK_PORT, \
RETHINK_HOST, RETHINK_AUTH_KEY
def get_connection():
return rethink.connect(
host=RETHINK_HOST,
port=RETHINK_PORT,
auth_key=RETHINK_AUTH_KEY,
db=DEFAULT_DB_NAME
)
```
Take a look at the Quick Start on how to init the DB. https://github.com/chadlung/pywebhooks#non-quickstart