Giter Club home page Giter Club logo

flask-peewee's Introduction

This package is in maintenance-only mode!

I'm sorry to announce that flask-peewee will now be in maintenance-only mode. This decision is motivated by a number of factors:

  • Flask-Admin provides a superior admin interface and has support for peewee models.
  • Flask-Security and Flask-Login both provide authentication functionality, and work well with Peewee.
  • Most importantly, though, I do not find myself wanting to work on flask-peewee.

I plan on rewriting the Database and REST API portions of flask-peewee and repackaging them as a new library, but flask-peewee as it stands currently will be in maintenance-only mode.

flask-peewee

provides a layer of integration between the flask web framework and the peewee orm.

batteries included:

  • admin interface
  • authentication
  • rest api

requirements:

check out the documentation.

admin interface

influenced heavily by the django admin, provides easy create/edit/delete functionality for your project's models.

image

rest api

influenced by tastypie, provides a way to expose a RESTful interface for your project's models.

curl localhost:5000/api/user/
{
  "meta": {
    "model": "user",
    "next": "",
    "page": 1,
    "previous": ""
  },
  "objects": [
    {
      "username": "admin",
      "admin": true,
      "email": "",
      "join_date": "2011-09-16 18:34:49",
      "active": true,
      "id": 1
    },
    {
      "username": "coleifer",
      "admin": false,
      "email": "[email protected]",
      "join_date": "2011-09-16 18:35:56",
      "active": true,
      "id": 2
    }
  ]
}

installing

I recommend installing in a virtualenv. to get started:

# create a new virtualenv
virtualenv --no-site-packages project
cd project/
source bin/activate

# install this project (will install dependencies as well)
pip install flask-peewee

example app

the project ships with an example app, which is a silly twitter clone. to start the example app, cd into the "example" directory and execute the run_example.py script:

cd example/
python run_example.py

if you would like to test out the admin area, log in as "admin/admin" and navigate to:

http://127.0.0.1:5000/admin/

you can check out the REST api at the following url:

http://127.0.0.1:5000/api/message/

flask-peewee's People

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.