Socket
Socket
Sign inDemoInstall

sriracha

Package Overview
Dependencies
0
Maintainers
1
Alerts
File Explorer

Install Socket

Detect and block malicious and high-risk dependencies

Install

    sriracha

MVC Web Framework


Maintainers
1

Readme

Sriracha

I put that on everything!

Sriracha is an MVC web framework written in Python with the purpose of making big and complex web applications easy to maintain, it serves as the Python equivalent of something like Rails for Ruby, Spring for Java, and could be seen somewhat similar to Angular.

Quick Start

python3 -m pip install sriracha
sri new myproject
cd myproject
./bin/dev-start

FAQ

Why this name? it's difficult to spell

You can think of it as sri-racha

Can I use it?

Sure, go ahead. You can get started with Quick Start

What templating engine does it use?

Liquid, this implementation. If you have experience with Jekyll or Shopify, you might be familiar with its syntax.

Is it fast?

That depends on your WSGI server! (sometimes.)

I chose Gunicorn and did a benchmark using wrk:

$ gunicorn http://0.0.0.0:8000
Running 10s test @ http://0.0.0.0:8000
  2 threads and 10 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     3.21ms  336.15us  12.99ms   92.05%
    Req/Sec     1.55k    62.25     1.65k    75.50%
  30797 requests in 10.00s, 11.06MB read
Requests/sec:   3079.11
Transfer/sec:      1.11MB

Compared to the results of this (which should be much faster as it doesn't have to do any complex routing or messing with views or controllers):

def app(environ, start_response):
        data = b"Hello, World!\n"
        start_response("200 OK", [
            ("Content-Type", "text/plain"),
            ("Content-Length", str(len(data)))
        ])
        return iter([data])
Running 10s test @ http://0.0.0.0:8000
  2 threads and 10 connections
  Thread Stats   Avg      Stdev     Max   +/- Stdev
    Latency     1.34ms  126.20us   5.88ms   97.70%
    Req/Sec     3.66k   234.92     6.84k    97.51%
  73109 requests in 10.10s, 10.67MB read
Requests/sec:   7238.95
Transfer/sec:      1.06MB

FAQs


Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc