Skip to main content

MySQL db models

Project description

silver-surfer-db-models

This package provides a reusable abstraction to connect to the silver surfer database.

Commands

List commands

inv -l

Usage

Configure the database in your app

from silver_surfer_models.database import get_db_session

db_uri = 'mysql+pymysql://%s:%s@%s/%s?charset=utf8mb4' % (
    'root',
    'password',
    'host',
    'db',
)
engine, db_session, Base = database.get_db_session(db_uri)

How to release a new version?

Update the version in setup.py

setuptools.setup(
    ...
    version='0.0.9',
    ...
)

Build the wheel

inv build

Upload the wheel to PyPi repository

inv push

Project details


Release history Release notifications | RSS feed

Download files

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

Source Distribution

silver-surfer-models-0.0.26.dev0.tar.gz (48.6 kB view hashes)

Uploaded Source

Built Distribution

silver_surfer_models-0.0.26.dev0-py3-none-any.whl (113.3 kB view hashes)

Uploaded Python 3

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