Name | emmett55 JSON |
Version |
1.0.1
JSON |
| download |
home_page | None |
Summary | The micro web framework for inventors |
upload_time | 2024-11-15 16:56:32 |
maintainer | None |
docs_url | None |
author | None |
requires_python | >=3.8 |
license | BSD-3-Clause |
keywords |
asyncio
web
|
VCS |
|
bugtrack_url |
|
requirements |
No requirements were recorded.
|
Travis-CI |
No Travis.
|
coveralls test coverage |
No coveralls.
|
# Emmett55
Emmett55 is a Python micro web framework designed with simplicity in mind.
```python
from emmett55 import App, request, response
from emmett55.tools import service, requires
app = App(__name__)
def is_authenticated():
return request.headers.get("api-key") == "foobar"
def not_authorized():
response.status = 401
return {"error": "not authorized"}
@app.route("/", methods='get')
@requires(is_authenticated, otherwise=not_authorized)
@service.json
async def index():
return {"message": "hello world"}
```
## Compared with Emmett
Emmett55 is based on [Emmett](https://emmett.sh) and shares the following features with it:
- [application and modules](https://emmett.sh/docs/latest/app_and_modules)
- [routing](https://emmett.sh/docs/latest/routing)
- [request](https://emmett.sh/docs/latest/request)/[response](https://emmett.sh/docs/latest/response)/[session](https://emmett.sh/docs/latest/sessions)/[websocket](https://emmett.sh/docs/latest/websocket) helpers
- the [pipeline](https://emmett.sh/docs/latest/pipeline)
- [services](https://emmett.sh/docs/latest/services) (JSON only)
- [caching](https://emmett.sh/docs/latest/caching) (except for disk cache)
- [HTML](https://emmett.sh/docs/latest/html) code generation
- [extensions](https://emmett.sh/docs/latest/extensions)
- [testing client](https://emmett.sh/docs/latest/testing)
- CLI (with the `emmett55` command)
Consequentially, Emmett55 doesn't include:
- the [ORM](https://emmett.sh/docs/latest/orm)
- the [authentication system](https://emmett.sh/docs/latest/auth)
- the [templating system](https://emmett.sh/docs/latest/templates)
- the [internationalization system](https://emmett.sh/docs/latest/languages)
- [validations](https://emmett.sh/docs/latest/validations)
- [forms](https://emmett.sh/docs/latest/forms) utilities
- XML services
- disk caching
- the [mailer](https://emmett.sh/docs/latest/mailer)
- the [debugger](https://emmett.sh/docs/latest/debug_and_logging#debugger)
Typical use-cases for picking Emmett55 over Emmett are:
- the lack of need of the upper-mentioned missing features
- the desire to use different libraries in place of the Emmett components, like SQLAlchemy or Jinja
## Documentation
While we're still in the process of developing Emmett55 documentation, the [Emmett one](https://emmett.sh/docs) can be examined – with the caviat to replace `emmett` with `emmett55` when mentioned and keep in mind the upper-mentioned list of non-included features.
## License
Emmett55 is released under the BSD License.
Raw data
{
"_id": null,
"home_page": null,
"name": "emmett55",
"maintainer": null,
"docs_url": null,
"requires_python": ">=3.8",
"maintainer_email": null,
"keywords": "asyncio, web",
"author": null,
"author_email": "Giovanni Barillari <g@baro.dev>",
"download_url": "https://files.pythonhosted.org/packages/c1/ed/0c0976da99a332a9afa4f3a5bb79cc24801b7b04f9be1bc2c136b0e04078/emmett55-1.0.1.tar.gz",
"platform": null,
"description": "# Emmett55\n\nEmmett55 is a Python micro web framework designed with simplicity in mind.\n\n```python\nfrom emmett55 import App, request, response\nfrom emmett55.tools import service, requires\n\napp = App(__name__)\n\ndef is_authenticated():\n return request.headers.get(\"api-key\") == \"foobar\"\n \ndef not_authorized():\n response.status = 401\n return {\"error\": \"not authorized\"}\n\n@app.route(\"/\", methods='get')\n@requires(is_authenticated, otherwise=not_authorized)\n@service.json\nasync def index():\n return {\"message\": \"hello world\"}\n```\n\n## Compared with Emmett\n\nEmmett55 is based on [Emmett](https://emmett.sh) and shares the following features with it:\n\n- [application and modules](https://emmett.sh/docs/latest/app_and_modules)\n- [routing](https://emmett.sh/docs/latest/routing)\n- [request](https://emmett.sh/docs/latest/request)/[response](https://emmett.sh/docs/latest/response)/[session](https://emmett.sh/docs/latest/sessions)/[websocket](https://emmett.sh/docs/latest/websocket) helpers\n- the [pipeline](https://emmett.sh/docs/latest/pipeline)\n- [services](https://emmett.sh/docs/latest/services) (JSON only)\n- [caching](https://emmett.sh/docs/latest/caching) (except for disk cache)\n- [HTML](https://emmett.sh/docs/latest/html) code generation\n- [extensions](https://emmett.sh/docs/latest/extensions)\n- [testing client](https://emmett.sh/docs/latest/testing)\n- CLI (with the `emmett55` command)\n\nConsequentially, Emmett55 doesn't include:\n\n- the [ORM](https://emmett.sh/docs/latest/orm)\n- the [authentication system](https://emmett.sh/docs/latest/auth)\n- the [templating system](https://emmett.sh/docs/latest/templates)\n- the [internationalization system](https://emmett.sh/docs/latest/languages)\n- [validations](https://emmett.sh/docs/latest/validations)\n- [forms](https://emmett.sh/docs/latest/forms) utilities\n- XML services\n- disk caching\n- the [mailer](https://emmett.sh/docs/latest/mailer)\n- the [debugger](https://emmett.sh/docs/latest/debug_and_logging#debugger)\n\nTypical use-cases for picking Emmett55 over Emmett are:\n\n- the lack of need of the upper-mentioned missing features\n- the desire to use different libraries in place of the Emmett components, like SQLAlchemy or Jinja\n\n## Documentation\n\nWhile we're still in the process of developing Emmett55 documentation, the [Emmett one](https://emmett.sh/docs) can be examined \u2013 with the caviat to replace `emmett` with `emmett55` when mentioned and keep in mind the upper-mentioned list of non-included features.\n\n## License\n\nEmmett55 is released under the BSD License.\n",
"bugtrack_url": null,
"license": "BSD-3-Clause",
"summary": "The micro web framework for inventors",
"version": "1.0.1",
"project_urls": {
"Documentation": "https://emmett.sh/docs",
"Funding": "https://github.com/sponsors/gi0baro",
"Homepage": "https://github.com/emmett-framework/emmett55",
"Issues": "https://github.com/emmett-framework/emmett55/issues",
"Source": "https://github.com/emmett-framework/emmett55"
},
"split_keywords": [
"asyncio",
" web"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "15200feb411bc4d3db1007ac9e54d44b45d2c245e01f15705d45b1331e38b75d",
"md5": "00e6a484f37e511849951297777ee850",
"sha256": "6666902157df2a45c415fab19ac37a73119e18a6341f43dd83a074ee352f0cd9"
},
"downloads": -1,
"filename": "emmett55-1.0.1-py3-none-any.whl",
"has_sig": false,
"md5_digest": "00e6a484f37e511849951297777ee850",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": ">=3.8",
"size": 13088,
"upload_time": "2024-11-15T16:56:29",
"upload_time_iso_8601": "2024-11-15T16:56:29.460708Z",
"url": "https://files.pythonhosted.org/packages/15/20/0feb411bc4d3db1007ac9e54d44b45d2c245e01f15705d45b1331e38b75d/emmett55-1.0.1-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "c1ed0c0976da99a332a9afa4f3a5bb79cc24801b7b04f9be1bc2c136b0e04078",
"md5": "4008cf01250be4599c449b78a7a8abcc",
"sha256": "d086dd07a95d64b643b2d0c849757cf2fd848ce9269c8b9c422ded3c5e3dfaae"
},
"downloads": -1,
"filename": "emmett55-1.0.1.tar.gz",
"has_sig": false,
"md5_digest": "4008cf01250be4599c449b78a7a8abcc",
"packagetype": "sdist",
"python_version": "source",
"requires_python": ">=3.8",
"size": 9451,
"upload_time": "2024-11-15T16:56:32",
"upload_time_iso_8601": "2024-11-15T16:56:32.958239Z",
"url": "https://files.pythonhosted.org/packages/c1/ed/0c0976da99a332a9afa4f3a5bb79cc24801b7b04f9be1bc2c136b0e04078/emmett55-1.0.1.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-11-15 16:56:32",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "sponsors",
"github_project": "gi0baro",
"github_not_found": true,
"lcname": "emmett55"
}