/funfetch

executing a function as a session

Primary LanguagePythonMIT LicenseMIT

FunFetch

PyPI PyPI - License Code style: black

Remote execution of a simple function on the server

All types of Python support objects.

Installation

pip install funfetch

Examples

Server

from funfetch import Server

server = Server()

@server.use()
async def test(game: str, test):
    return f"play {game}! just {test}"

server.run()

Client

from funfetch import Client
import asyncio

client = Client()

async def req():
    print(await client.test(game="testuser", test="test"))

asyncio.run(req())