The simple, quick and easy generative web framework for python
Project description
.. figure:: http://www.pythononwheels.org/static/images/pow_logo_300.png
:alt: Pow logo
Pow logo
This is the new pow 2017. And it's really good.
===============================================
(ok I might be biased ;)
But it's by far the best PoW (concept and implementation) ever! (Ever,ever, ever!!)
I call it *SQUEEZY* => for Simple, Quick and Easy.
Principle
---------
Designed for simplicity, happiness and Quick results!
As simple to use as possible. Everything you always need on board.
Batteries included! (tornado Webserver, SQLite DB, NoSQL DBs: tinyDB,
ElasticSearch, MongoDB following next) Non intrusive! You can always
escape and go RAW.
Strong Foundation:
------------------
- python 3.x
- tornado webserver
- sqlalchemy ORM onboard (sqlite, mysql, postgres, oralce, ms-sql ...)
- DB migrations generated for you (based on alembic)
- cerberus schemas and validation on board
- template engine (tornado templates)
- Many SQL DBs[sqlite, mysql, postgres, ms-sql,orcale ] NoSql DBs: tinyDB, MongoDB and ElasticSearch on board...
- authentication with Twitter, Google on board
Super easy, quick to start and all the basics on board:
-------------------------------------------------------
- super easy relations with decorators @relations.has\_many("comments")
- super easy REST routing with decorators @app.add\_restful\_routes(),
- routing decorator @app.add\_route(route)
- db migrations autogenerated using alembic in the back
- validation on board with cerberus schemas
- use the same schema descrition for all model types (sql, nosql,
elastic..)
- generate\_models script
- generate\_migrations script
- update\_db script
- generate\_handlers
- generate\_app
- automatic scaffolding views (work in progress)
Code examples
-------------
Routes:
~~~~~~~
::
# You can use regex routes
# this will call the myget method on HTTP GET calls and will hand over the re-group as the 1st parameter.
@app.add_route("/index/([0-9]+)*", dispatch={"get" : "myget"})
# Or you can also use Flask/Werkzeug routes
@app.add_route('/index/<int:year>', dispatch={"get" : "myyear"})
class IndexdHandler(BaseHandler):
def myget(self, index=None):
print(" index:" + str(index))
self.render("index.tmpl")
def myyear(self, year=None):
self.write("I got year: " + str(year))
Relations: (SQL Models)
~~~~~~~~~~~~~~~~~~~~~~~
::
@relation.has_many("comments")
class Post(Base):
# a blog Post
schema = {
'text' : {'type': 'string'},
'name' : {'type': 'string', 'maxlength' : 35},
'votes' : {'type': 'integer'},
'status' : {'type': 'string', 'allowed' : ['ready to publish', 'needs review', 'draft'] },
'published' : {'type': 'boolean', 'default' : False },
'tags' : {'type': 'list', 'default' : [] }
}
Check: `The PythonOnWheels Homepage <http://www.pythononwheels.org>`__
----------------------------------------------------------------------
:alt: Pow logo
Pow logo
This is the new pow 2017. And it's really good.
===============================================
(ok I might be biased ;)
But it's by far the best PoW (concept and implementation) ever! (Ever,ever, ever!!)
I call it *SQUEEZY* => for Simple, Quick and Easy.
Principle
---------
Designed for simplicity, happiness and Quick results!
As simple to use as possible. Everything you always need on board.
Batteries included! (tornado Webserver, SQLite DB, NoSQL DBs: tinyDB,
ElasticSearch, MongoDB following next) Non intrusive! You can always
escape and go RAW.
Strong Foundation:
------------------
- python 3.x
- tornado webserver
- sqlalchemy ORM onboard (sqlite, mysql, postgres, oralce, ms-sql ...)
- DB migrations generated for you (based on alembic)
- cerberus schemas and validation on board
- template engine (tornado templates)
- Many SQL DBs[sqlite, mysql, postgres, ms-sql,orcale ] NoSql DBs: tinyDB, MongoDB and ElasticSearch on board...
- authentication with Twitter, Google on board
Super easy, quick to start and all the basics on board:
-------------------------------------------------------
- super easy relations with decorators @relations.has\_many("comments")
- super easy REST routing with decorators @app.add\_restful\_routes(),
- routing decorator @app.add\_route(route)
- db migrations autogenerated using alembic in the back
- validation on board with cerberus schemas
- use the same schema descrition for all model types (sql, nosql,
elastic..)
- generate\_models script
- generate\_migrations script
- update\_db script
- generate\_handlers
- generate\_app
- automatic scaffolding views (work in progress)
Code examples
-------------
Routes:
~~~~~~~
::
# You can use regex routes
# this will call the myget method on HTTP GET calls and will hand over the re-group as the 1st parameter.
@app.add_route("/index/([0-9]+)*", dispatch={"get" : "myget"})
# Or you can also use Flask/Werkzeug routes
@app.add_route('/index/<int:year>', dispatch={"get" : "myyear"})
class IndexdHandler(BaseHandler):
def myget(self, index=None):
print(" index:" + str(index))
self.render("index.tmpl")
def myyear(self, year=None):
self.write("I got year: " + str(year))
Relations: (SQL Models)
~~~~~~~~~~~~~~~~~~~~~~~
::
@relation.has_many("comments")
class Post(Base):
# a blog Post
schema = {
'text' : {'type': 'string'},
'name' : {'type': 'string', 'maxlength' : 35},
'votes' : {'type': 'integer'},
'status' : {'type': 'string', 'allowed' : ['ready to publish', 'needs review', 'draft'] },
'published' : {'type': 'boolean', 'default' : False },
'tags' : {'type': 'list', 'default' : [] }
}
Check: `The PythonOnWheels Homepage <http://www.pythononwheels.org>`__
----------------------------------------------------------------------
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
pythononwheels-0.83b0.tar.gz
(1.7 MB
view hashes)
Built Distribution
Close
Hashes for pythononwheels-0.83b0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | f31dd2e987e5ed9141e9e9150c2d3475507fbad1396e3317382beca54271a96e |
|
MD5 | 45c6c6c53f66baff4a7cf4ed848b946a |
|
BLAKE2b-256 | bd5c8e9fa3dfd9593e0e18b647834b8d2b11efee8d563d5bf47037eb251e0ccb |