Skip to content

Incorrect keyword argument name 'parameters' for AsyncSession.scalars, AsyncEngine.scalars #230

New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

Closed
mjpieters opened this issue Sep 23, 2022 · 1 comment · Fixed by #238
Closed
Labels
bug Something isn't working

Comments

@mjpieters
Copy link
Contributor

The type hints for the AsyncSession.scalars() method uses the keyword argument parameters, but the actual argument is named params.

The same issue applies to AsyncSession.stream_scalars() and to the async_scoped_session proxies for these.

See:

async def scalars(
self,
statement: Executable,
parameters: Optional[_ExecuteParams] = ...,
execution_options: Optional[_ExecuteOptions] = ...,
) -> ScalarResult: ...
async def stream_scalars(
self,
statement: Executable,
parameters: Optional[_ExecuteParams] = ...,
execution_options: Optional[_ExecuteOptions] = ...,
) -> AsyncScalarResult: ...

async def scalars(
self,
statement: Executable,
parameters: Optional[_ExecuteParams] = ...,
execution_options: Optional[_ExecuteOptions] = ...,
) -> ScalarResult: ...
async def stream_scalars(
self,
statement: Executable,
parameters: Optional[_ExecuteParams] = ...,
execution_options: Optional[_ExecuteOptions] = ...,
) -> AsyncScalarResult: ...

@mjpieters mjpieters added the requires triage New issue that requires categorization label Sep 23, 2022
@CaselIT CaselIT added bug Something isn't working and removed requires triage New issue that requires categorization labels Sep 23, 2022
@CaselIT
Copy link
Member

CaselIT commented Sep 23, 2022

Thanks for reporting.

If you could provide a PR it would be great

# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants