Skip to main content

Rho AI Database Helpers

Project description

# RhoDB

Core Database-related classes that typical Rho AI Applications will need. ‘Typical’ meaning using flask, sqlalchemy/postgres, and redis.

## Examples

Example code include db initialization, helper functions, and base classes for models.

## Testing

To run the tests we need to install pyenv and tox.

Follow the instructions for [pyenv](https://github.com/pyenv/pyenv#installation) and [pyenv-virtualenv](https://github.com/pyenv/pyenv-virtualenv#installation) to install pyenv.

After pyenv is intalled, then install tox

$ pip install tox

Then install the different python versions in pyenv

$ pyenv install 2.7.13 3.6.7

Ensure testable databases are running. Remove -d if you want to run in foreground…

  • Redis * docker run –name rhodb-redis -d -p 6379:6379 redis:4

  • MySQL == 5.7 * docker run –name rhodb-mysql -d -p 3306:3306 -e MYSQL_ALLOW_EMPTY_PASSWORD=yes mysql:5.7

  • Postgres * docker run –name rhodb-postgres -d -p 5432:5432 -e POSTGRES_DB=rhodb_test -e POSTGRES_HOST_AUTH_METHOD=trust postgres:10

  • Elasticsearch * docker run –name rhodb-elasticsearch -d -p 9200:9200 -p 9300:9300 -e “discovery.type=single-node” docker.elastic.co/elasticsearch/elasticsearch:6.5.4

Now, run the tests:

$ tox

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

rhodb-6.0.0.tar.gz (20.7 kB view details)

Uploaded Source

File details

Details for the file rhodb-6.0.0.tar.gz.

File metadata

  • Download URL: rhodb-6.0.0.tar.gz
  • Upload date:
  • Size: 20.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.2 CPython/3.9.16

File hashes

Hashes for rhodb-6.0.0.tar.gz
Algorithm Hash digest
SHA256 187f9ef0f00ee3b0880ac98a09a26b4f7ebd300c45427936d350082f9e8558fb
MD5 33cbb3ff656b00cf856cd7213e45424c
BLAKE2b-256 1eb9b50a868f0d9d6f37b01b2c89c5d684d47852f4ef38f4ea55cb9863984629

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page