python_bot_v2/db_logic/collections.py

18 lines
489 B
Python
Raw Normal View History

2024-01-23 12:45:44 +10:00
from global_conf import CONFIG
#### https://docs.python-arango.com/en/main/
from arango import ArangoClient
def get_dicks_collection():
arango_client = ArangoClient(hosts=CONFIG['databaso']['host'] )
pipisa_db = arango_client.db(
CONFIG['databaso']['base'],
username=CONFIG['databaso']['user'],
password=CONFIG['databaso']['pass']
)
dicks_collection = pipisa_db.collection(CONFIG['databaso']['collection'])
return dicks_collection