#36598: Django migrations is unable to find remove constraints from non-public
schema for Postgres
-------------------------------------+-------------------------------------
     Reporter:  Salaah Amin          |                    Owner:  (none)
         Type:  Bug                  |                   Status:  new
    Component:  Database layer       |                  Version:  4.2
  (models, ORM)                      |
     Severity:  Normal               |               Resolution:
     Keywords:  postgres, db, orm    |             Triage Stage:
                                     |  Unreviewed
    Has patch:  0                    |      Needs documentation:  0
  Needs tests:  0                    |  Patch needs improvement:  0
Easy pickings:  0                    |                    UI/UX:  0
-------------------------------------+-------------------------------------
Comment (by Salaah Amin):

 I think I found the issue.

 When I run:

 {{{
 select pg_catalog.pg_table_is_visible(<the model oid>)
 }}}

 I get false.

 When I run:
 {{{
 show search_path
 }}}

 I get a few things, but I notice analytics isn't there.

 If I update my search_path using {{{set search_path to ...}}}, and then
 run {{{ select pg_catalog.pg_table_is_visible(<the model oid>) }}} I get
 true.

 Now, I'm not entirely sure if there are any consequences to adding all
 schemas to the search path. But I assume it should be fine to add it
 **just** before running migrations so that it only affects the user's
 session when they are running the actual migration.

 If you agree to this solution, let me know (and mark the ticket
 accordingly), and I'd be happy to apply the fix.
-- 
Ticket URL: <https://code.djangoproject.com/ticket/36598#comment:4>
Django <https://code.djangoproject.com/>
The Web framework for perfectionists with deadlines.

-- 
You received this message because you are subscribed to the Google Groups 
"Django updates" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-updates+unsubscr...@googlegroups.com.
To view this discussion visit 
https://groups.google.com/d/msgid/django-updates/010701993a679517-cab5aa4a-8381-4322-a8ea-b455342fd735-000000%40eu-central-1.amazonses.com.

Reply via email to