Skip to content

tarsil/tarsil

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 

Repository files navigation

Who is tarsil?

tarsil is also known as Tiago Silva, not the football player but a Software Engineer.

Passionate to his core, tarsil is also the creator of Ravyn, Lilya, Edgy, AsyncMQ, Mongoz, Asyncz and many open source tools out there.

I do have a discord channel if you want to ask me anything about what I do and my tools.

Hello from tarsil

Nothing like using Lilya to say hi.

$ pip install lilya
$ pip install palfrey

Then, inside an app.py, add this.

import palfrey

from lilya.apps import Lilya
from lilya.requests import Request
from lilya.responses import Ok
from lilya.routing import Path


async def welcome():
    return Ok({"message": "Welcome to Lilya"})


async def user(user: str):
    return Ok({"message": f"Welcome to Lilya, {user}"})


async def user_in_request(request: Request):
    user = request.path_params["user"]
    return Ok({"message": f"Welcome to Lilya, {user}"})


app = Lilya(
    routes=[
        Path("/normal/{user}", user),
        Path("/in-request/{user}", user_in_request),
        Path("/", welcome),
    ]
)


if __name__ == "__main__":
    palfrey.run(app, port=8000)

In the end, run the ./app.py and access your localhost in the endpoints. Have fun!

About

The tarsil repo

Resources

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Releases

Packages

Contributors