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

Dart turns URL variables into database models with a decorator.

That means you can do something like this:

@app.route('/user/<user_id>/tracks', methods=['GET'])
@dart.inject(User, 'user', from_var='user_id')
def user_tracks(user=None):
    return jsonify(user.tracks)

If you’re smart, you might have a decorator that checks user authorization, something like @login_required. You can compose Dart with other decorators to simplify logic, while still keeping your code readable and concise:

def login_required(view):
    @dart.inject(User, 'user', from_var='user_id')
    @dart.inject(User, 'current_user', from_val=lambda: session['user_id'])
    def decorated_view(user=None, current_user=None, *args, **kwargs):
        if current_user != user:
            return view(user=user, *args, **kwargs)
    return decorated_view

def view(user=None):
    return '{} did it!'.format(

Of course, Dart isn’t just a Flask. It’s literally just a decorator that takes a keyword arg or lambda expression and queries the model class using it as the primary key. That means you can use the Dart decorator with any function.

For more info, check out the source code – it’s 27 lines.

Release History

Release History


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

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
dart-1.0-py2.py3-none-any.whl (3.4 kB) Copy SHA256 Checksum SHA256 2.7 Wheel Apr 7, 2014
dart-1.0.tar.gz (2.0 kB) Copy SHA256 Checksum SHA256 Source Apr 7, 2014

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