Skip to main content

Async server for userv

Project description

The catch

Simple async webserver

Webserver

First we need to add routes to a router. After this we can add a task to the async loop with:

Example:

from userv.routing import Router
from userv.async_server import run_server
router = Router()

run_server(router)

Now we have added the current app to the event loop and we still have to run the event loop.

Example:

from uasyncio import get_event_loop
loop = get_event_loop()
loop.run_forever()

Now the server will run and serve your data.

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

userv.async_server-0.3.4.tar.gz (1.5 kB view details)

Uploaded Source

File details

Details for the file userv.async_server-0.3.4.tar.gz.

File metadata

  • Download URL: userv.async_server-0.3.4.tar.gz
  • Upload date:
  • Size: 1.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 pkginfo/1.5.0.1 requests/2.21.0 setuptools/28.8.0 requests-toolbelt/0.9.1 tqdm/4.31.1 CPython/3.6.4

File hashes

Hashes for userv.async_server-0.3.4.tar.gz
Algorithm Hash digest
SHA256 f71716e99ffb07c9d3c14c620da01d8571e85d5af8916b36290c6284df3fce73
MD5 57a1bd73c81951b23fced08afa2c19fa
BLAKE2b-256 f4e16328ec782ab619f104713cf6acdc7aa6155b8773bcc39e773c3f5cb540fb

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page