diff --git a/autodynatrace/wrappers/psycopg2/wrapper.py b/autodynatrace/wrappers/psycopg2/wrapper.py index 0693fc6..e1d722c 100644 --- a/autodynatrace/wrappers/psycopg2/wrapper.py +++ b/autodynatrace/wrappers/psycopg2/wrapper.py @@ -11,7 +11,7 @@ def instrument(): def parse_dsn(dsn): return {c.split("=")[0]: c.split("=")[1] for c in dsn.split() if "=" in c} - class DynatraceCursor(psycopg2.extensions.cursor): + class DynatraceCursor(psycopg2.extra.DictCursorBase): def __init__(self, *args, **kwargs): self._dynatrace_db_info = kwargs.pop("dynatrace_db_info", None) super(DynatraceCursor, self).__init__(*args, **kwargs)