Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/zvfvrv/flask-python-arango
python-arango support for Flask applications
https://github.com/zvfvrv/flask-python-arango
arangodb flask python
Last synced: 6 days ago
JSON representation
python-arango support for Flask applications
- Host: GitHub
- URL: https://github.com/zvfvrv/flask-python-arango
- Owner: zvfvrv
- License: apache-2.0
- Created: 2020-05-07T15:47:50.000Z (over 4 years ago)
- Default Branch: master
- Last Pushed: 2020-05-12T09:46:15.000Z (over 4 years ago)
- Last Synced: 2024-09-19T14:37:12.693Z (14 days ago)
- Topics: arangodb, flask, python
- Language: Python
- Size: 16.6 KB
- Stars: 1
- Watchers: 0
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.rst
- License: LICENSE
Awesome Lists containing this project
README
|Upload Python Package|
Flask-Python-Arango
===================**Flask-Python-Arango** is a `python-arango`_ support for Flask applications using ArangoDB_
Installation
------------To install a stable version from PyPi_:
.. code-block:: bash
~$ pip install Flask-Python-Arango
To install the latest version directly from GitHub_:
.. code-block:: bash
~$ pip install -e [email protected]:zvfvrv/flask-python-arango.git@master#egg=flask-python-arango
A Simple Example
----------------.. code-block:: python
from flask import Flask, render_template
from flask_python_arango import FlaskArangoapp = Flask(__name__)
app.config['ARANGODB_HOST'] = 'http://localhost:8529'
app.config['ARANGODB_DB'] = 'test'
app.config['ARANGODB_USERNAME'] = 'root'
app.config['ARANGODB_PSW'] = '12345678'ArangoDB = FlaskArango(app)
@app.route('/')
def home_page():
# Execute an AQL query and iterate through the result cursor.
cursor = ArangoDB.connection.aql.execute('FOR doc IN nodes RETURN doc')
devices = [document for document in cursor]
return render_template('index.html', devices=devices)Contributing
------------Please create an issue on GitHub_.
Links
-----* `python-arango`_
* Flask Documentation: https://flask.palletsprojects.com/
* ArangoDB_.. _`GitHub`: https://github.com/zvfvrv/flask-python-arango
.. _ArangoDB: https://www.arangodb.com
.. _`python-arango`: https://github.com/joowani/python-arango/releases
.. _PyPi: https://pypi.org/project/flask-python-arango/
.. |Upload Python Package| image:: https://github.com/zvfvrv/flask-python-arango/workflows/Upload%20Python%20Package/badge.svg