Skip to content

DeprecationWarning: The Row.keys() method is deprecated to mimic SQLAlchemy behaviour, use Row._mapping.keys() instead. warnings.warn( #833

Closed

Description

@xykylikuf001
asyncpg version: 0.24.0
PostgreSQL version:
Do you use a PostgreSQL SaaS? If so, which? Can you reproduce
the issue with a local PostgreSQL install?:
Python version: 3.9.7
Platform: fastapi, sqlalchemy, encode/databases
Do you use pgbouncer?:
Did you install asyncpg with pip?: pipenv
If you built asyncpg locally, which version of Cython did you use?:
Can the issue be reproduced under both asyncio and
uvloop?:

When convert Record instance to dict like this:
dict(item)
got deprecation warning:
DeprecationWarning: The Row.keys() method is deprecated to mimic SQLAlchemy behaviour, use Row._mapping.keys() instead
Can you provide convert api for Record instances?

Activity

  1. elprans commented on Nov 7, 2021

    @elprans
    Member

    This doesn't seem related to asyncpg as the DeprecationWarning comes from databases, not from asyncpg.

  2. GeekyShacklebolt commented on May 18, 2022

    @GeekyShacklebolt

    Landed here from google search for the same DeprecationWarning. For future viewers, encode/databases#447 it is expected to be fixed in databases v0.6.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions