Skip to main content

Yet another python web (WSGI) micro-framework

Project description

Bicchiere

Bicchiere Logo

Yet another Python web (WSGI) micro-framework

Following Flask and Bottle footsteps, adding a bit of italian flavor :-)

Install

pip install bicchiere

Project Demo App

Current version: 1.9.5

GitHub tag (latest by date)    

A drop from Bicchiere

from bicchiere import Bicchiere

app = Bicchiere()
or
app = Bicchiere("La mia bella App")

@app.get("/")
def home():
    return "Bon giorno, cosa bevete oggi?"
    
if __name__ == "__main__":
    #This will run default server on http://localhost:8086
    app.run()

... and this is just about the classical WSGI Hello, World, for everything else please refer to Bicchiere Wiki

Well... not really. A bit of rationale is in order here.

So, why Bicchiere?

  • For one thing, reinventing the wheel is not only fun but highly educational, so, by all means, do it!

  • I like Flask and Bottle. A lot. Both have things that I highly appreciate, simplicity in the first place. But it doesn't end there.

  • There's also the single file/no dependencies approach (Bottle), which I intend to mimic with Bicchiere. Although not a mandatory thing, I like it that way.

  • Built-in sessions (Flask). Although the user of the library must be free to choose whatever he likes regarding sessions or any other component of the application for that matter, I think session-handling is one of those must-have things in any web app these days. So, I provided basic session handling mechanism, in 3 flavors: memory, filesystem, and sqlite. This was the most that could be done without falling out of the boundaries of the Python Standard Library. Details on this at the wiki (under construction)

  • Built-in templating mechanism (Bottle). Similar considerations apply. In my opinion, this is also a must have, regardless how micro is the framework/library. Then again, end-user must be free to choose. As a good WSGI compliant middleware, Bicchiere doesn't come in the way of the user if he prefers to use Mako, Jinja2, Genshi or whatever he likes. Details at the wiki (under construction)

  • WebSockets handling: to me, this is the fruit on the cake, for various reasons:

    1. It's been said that it can't be done under WSGI, reason the more to do it.
    2. Real time communication looks like another must have in the current landscape of web app development
    3. Then again, its a lot of fun. A lot of pain, too... In any case, Bicchiere comes bundled with native WebSocket support - just taken out from the oven :-)) Details at the wiki (under construction) . Regretably, the original Demo App won't work with websockets, because Pythonanywhere hasn't yet implemented the feature. As of now, there's a mirror at bicchiere.sytes.net which works fine, test at the home page and all. In any case, these issues are related to reverse proxy configuration and have nothing to see with the app/library itself.
  • And still, there's a lot of stuff to be mentioned. More to come...

Project details


Release history Release notifications | RSS feed

This version

1.9.5

Download files

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

Source Distribution

bicchiere-1.9.5.tar.gz (60.1 kB view details)

Uploaded Source

Built Distribution

bicchiere-1.9.5-py3-none-any.whl (61.3 kB view details)

Uploaded Python 3

File details

Details for the file bicchiere-1.9.5.tar.gz.

File metadata

  • Download URL: bicchiere-1.9.5.tar.gz
  • Upload date:
  • Size: 60.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.8.10

File hashes

Hashes for bicchiere-1.9.5.tar.gz
Algorithm Hash digest
SHA256 36447cf931ebb489c9408d41054e7213498d93d8a6b927d85b7817c912c1d1a6
MD5 f26f2497aab2231961ed5f69840301a7
BLAKE2b-256 87b6da815412e3c9d01821c3b415a3cbe163e9ccdd9fb9b7240bb8def36db138

See more details on using hashes here.

File details

Details for the file bicchiere-1.9.5-py3-none-any.whl.

File metadata

  • Download URL: bicchiere-1.9.5-py3-none-any.whl
  • Upload date:
  • Size: 61.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.8.10

File hashes

Hashes for bicchiere-1.9.5-py3-none-any.whl
Algorithm Hash digest
SHA256 1e033a16b48ff0df5a450046cfdcf0d8b98409f6fd91fc56739ad3ceafac7a58
MD5 ce99739d933bbecd7b0389f4c368667c
BLAKE2b-256 1278e5fe1e0e276de5cb4072dea08cabc21614fe051cbb659e4454c4f9ac2789

See more details on using hashes here.

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