]> git.ipfire.org Git - thirdparty/psycopg.git/commit
fix: avoid to create reference loops in datetime adapters
authorDaniele Varrazzo <daniele.varrazzo@gmail.com>
Wed, 7 Feb 2024 01:16:06 +0000 (01:16 +0000)
committerDaniele Varrazzo <daniele.varrazzo@gmail.com>
Wed, 7 Feb 2024 01:16:06 +0000 (01:16 +0000)
commit36b0a5506bb4fec70ca7cb9fa38a88c2e73a094d
tree1fee4f449f7a21f4da6669de15c29ceaa348ead8
parent7757d6111ee049d502649cd95bac970df4292c11
fix: avoid to create reference loops in datetime adapters

Setting the reference to a bound method in the state creates a reference
loop.

The issue is minimal because the gc will be able to break these loops
anyway and because it mostly happens with exotic or unsupported
date/interval styles.
psycopg/psycopg/types/datetime.py