Lancetnik / FastDepends

FastDepends - FastAPI Dependency Injection system extracted from FastAPI and cleared of all HTTP logic. Async and sync modes are both supported.
https://lancetnik.github.io/FastDepends/
MIT License
245 stars 8 forks source link

bug: can't pass whole body to Depends if original function has no args #75

Closed Lancetnik closed 4 months ago

Lancetnik commented 4 months ago

Original Issue: https://github.com/airtai/faststream/issues/1271

Incorrect behavior:

from fast_depends import Depends, inject

def dep(a: str):
    return a

@inject
def func(result: str  = Depends(dep)):
    print(result)

func("test")