Changes between Initial Version and Version 1 of Ticket #35699, comment 2


Ignore:
Timestamp:
Aug 22, 2024, 11:17:47 AM (4 weeks ago)
Author:
Simon Charette

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #35699, comment 2

    initial v1  
    33Are you running into this issue by importing the `django.db.backends.postgresql.psycopg_any.Inet` alias directly or through of of Django's?
    44
    5 [https://github.com/django/django/blob/7adb6dd98d50a238f3eca8c15b16b5aec12575fd/django/db/models/fields/__init__.py#L2277-L2280 The only internal usage] of the `Inet` alias is through `GenericIPAddressField` which only supports [https://docs.djangoproject.com/en/5.1/ref/models/fields/#django.db.models.GenericIPAddressField an IPv4 or IPv6 address]. In other words, `GenericIPAddressField` was never meant to support IP ranges such as `192.168.1/24` in the first place from my understanding.
     5[https://github.com/django/django/blob/7adb6dd98d50a238f3eca8c15b16b5aec12575fd/django/db/models/fields/__init__.py#L2277-L2280 The only internal usage] of the `Inet` alias is through `GenericIPAddressField` which only supports [https://docs.djangoproject.com/en/5.1/ref/models/fields/#django.db.models.GenericIPAddressField an IPv4 or IPv6 address]. In other words, `GenericIPAddressField` was never meant to support IP ranges such as `192.168.1/24` in the first place from my understanding and it just happened to work by chance on Postgres previously because `inet` was used as the column type.
Back to Top