Пример #1
0
def hello(
        input: HelloInput,
        writer: commands.Writer = Depends(commands.writer),  # TODO: more deps?
) -> t.Dict[str, t.Any]:
    with runtime.handle() as s:
        commands.hello(writer, **input.dict())
        return s.dict()
Пример #2
0
def hello(input: Hello) -> t.Dict[str, t.Any]:
    """
    hello world
    """
    with runtime.handle() as s:
        commands.hello(**input.dict())
        return s.dict()
Пример #3
0
def hello(input: HelloInput) -> t.Dict[str, t.Any]:
    with runtime.handle() as s:
        commands.hello(**input.dict())
        return s.dict()
Пример #4
0
def hello(
    input: HelloInput, db: commands.DB = Depends(db)) -> t.Dict[str, t.Any]:
    with runtime.handle() as s:
        commands.hello(db, **input.dict())
    return s.dict()
Пример #5
0
def hello(
    input: HelloInput, db: commands.DB = Depends(db)) -> t.Dict[str, t.Any]:
    with runtime.handle() as s:
        # TODO: support positional arguments? (DI)
        commands.hello(db, **input.dict())
        return s.dict()
Пример #6
0
def hello() -> t.Dict[str, t.Any]:
    with runtime.handle() as s:
        commands.hello()
    return s.dict()