This is a pre-production deployment of Warehouse, however changes made here WILL affect the production instance of PyPI.
Latest Version Dependencies status unknown Test status unknown Test coverage unknown
Project Description

Bottle-MySQL is a plugin that integrates MySQL with your Bottle application. It automatically connects to a database at the beginning of a request, passes the database handle to the route callback and closes the connection afterwards.

To automatically detect routes that need a database connection, the plugin searches for route callbacks that require a pymydb keyword argument (configurable) and skips routes that do not. This removes any overhead for routes that don’t need a database connection.

Results are returned as dictionaries.

Usage Example:

import bottle
import bottle_pymysql

app = bottle.Bottle()
# dbhost is optional, default is localhost
plugin = bottle_pymysql.Plugin(dbuser='user', dbpass='pass', dbname='db')
app.install(plugin)

@app.route('/show/:<tem>')
def show(item, pymydb):
    pymydb.execute('SELECT * from items where name="%s"', (item,))
    row = pymydb.fetchone()
    if row:
        return template('showitem', page=row)
    return HTTPError(404, "Page not found")
Release History

Release History

0.1.2

This version

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

0.1.1

History Node

TODO: Figure out how to actually get changelog content.

Changelog content for this version goes here.

Donec et mollis dolor. Praesent et diam eget libero egestas mattis sit amet vitae augue. Nam tincidunt congue enim, ut porta lorem lacinia consectetur. Donec ut libero sed arcu vehicula ultricies a non tortor. Lorem ipsum dolor sit amet, consectetur adipiscing elit.

Show More

Download Files

Download Files

TODO: Brief introduction on what you do with files - including link to relevant help section.

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
bottle-pymysql-0.1.2.tar.gz (3.2 kB) Copy SHA256 Checksum SHA256 Source Apr 28, 2016

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS HPE HPE Development Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting