Flask Coralillo
Integrates the Coralillo Redis ORM into flask
Usage
This is an easy application that stores and retrieves cars from redis database.
# app.py
from flask import Flask, request, redirect
from flask_coralillo import Coralillo
from coralillo import Model, fields
app = Flask(__name__)
engine = Coralillo(app)
class Car(Model):
name = fields.Text()
class Meta:
engine = engine
@app.route('/')
def list_cars():
res = '<h1>Cars</h1><ul>'
for car in Car.get_all():
res += '<li>{}</li>'.format(car.name)
res += '</ul><h3>Add car</h3>' + \
'<form method="POST">' + \
'<input name="name">' + \
'<input type="submit" value="Add">' + \
'</form>'
return res
@app.route('/', methods=['POST'])
def add_car():
newcar = Car.validate(**request.form.to_dict()).save()
return redirect('/')
if __name__ == '__main__':
app.run()
Now if you run python app.py and you visit http://localhost:5000 you will be able to intercact with your brand new Flask-Coralillo application.
For more information visit https://getfleety.github.io/coralillo/
Metadata
Release files for Flask-Coralillo 0.1.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| Flask-Coralillo-0.1.3.tar.gz | 2.6 kB | Without provenance | Details for Flask-Coralillo-0.1.3.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| Flask_Coralillo-0.1.3-py3-none-any.whl | Python 3 | none | any | Details for Flask_Coralillo-0.1.3-py3-none-any.whl |
Total release size: 6.8 kB
Release files / Flask-Coralillo-0.1.3.tar.gz
| Download URL | Flask-Coralillo-0.1.3.tar.gz |
|---|---|
| Size | 2.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
56e7dc2591cf9078739926f2e4e488ca5ccb35e13735a73ca1853a2eb29bcd89
|
|
BLAKE2b-256 checksum How to use checksums |
f66e516796adcb4ffd931eefcc0246c8ce5356b21d1d8a22b911f4fbcdd95a95
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Release files / Flask_Coralillo-0.1.3-py3-none-any.whl
| Download URL | Flask_Coralillo-0.1.3-py3-none-any.whl |
|---|---|
| Size | 4.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
e87da003c8c7d5e3e8c3694315d4435282118a17a8dc7f32485038e66442a54d
|
|
BLAKE2b-256 checksum How to use checksums |
bc71de34f4fe64d43aa19171fee0b3637ecd6625d3e7991ff3210f3b6e77154b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for Flask-Coralillo 0.1.3
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.