Skip to main content

Kobin is a small and statically-typed web framework.

Project description

https://travis-ci.org/c-bata/kobin.svg?branch=master https://badge.fury.io/py/kobin.svg https://coveralls.io/repos/github/c-bata/kobin/badge.svg?branch=coveralls Code Climate

Kobin is a small and statically-typed WSGI micro web framework for Python. This library is a pre-release. Expect missing docs and breaking API changes. Kobin has following features.

  • Statically-typed web framework with PEP 0484(Type Hints).

  • Lightweight implementations for solving your problems easily.

  • Kobin provides Routing, WSGI request and response wrapper, Jinja2 template adapter and several useful utilities.

  • Convert URL variables types using Type Hints.

Hello World

$ pip install kobin
from kobin import Kobin
app = Kobin()

@app.route('/')
def hello() -> str:
    return "Hello World"

@app.route('/users/{user_id}')
def hello(user_id: int) -> str:
    return "Hello {}!!".format(user_id)

if __name__ == '__main__':
    app.run()

Requirements

Kobin requires the following:

  • Python 3.5

  • Jinja2

Resources

License

This software is licensed under the MIT License.

CHANGES

0.0.5 (2016-11-28)

  • Replace regex router with new style router.

  • Correspond reverse routing.

  • Remove serving static file. Please use wsgi-static-middleware.

  • Remove server adapter.

  • Support only Jinja2.

  • Refactoring.

0.0.4 (2016-02-28)

  • Expect the types of routing arguments from type hints.

  • Implement template adapter for jinja2.

  • Server for static files such as css, images, and so on.

  • Manage configuration class.

  • Support gunicorn.

  • Error handling.

  • Fix several bugs.

0.0.3 (2016-02-08)

  • Request and Response object.

  • tox and Travis-CI Integration.

0.0.2 (2015-12-03)

  • Publish on PyPI.

0.0.0 (2015-09-14)

  • Create this project.

Project details


Download files

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

Source Distribution

kobin-0.0.5.tar.gz (8.8 kB view hashes)

Uploaded Source

Built Distribution

kobin-0.0.5-py3-none-any.whl (11.0 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