Opened 5 years ago

Closed 5 years ago

#30346 closed Bug (duplicate)

InspectDB doesn't test for UUID (at least) on PostgreSQL

Reported by: Gui Pedreira Owned by: nobody
Component: Database layer (models, ORM) Version: 2.2
Severity: Normal Keywords: inspectdb, postgresql, uuid
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description (last modified by Gui Pedreira)

I was trying to do some reverse stuff...
Importing models from a "Legacy" Database,
as it turns out, inspectdb doesn't seem to go nicely with UUIDs,
At least on PostgreSQL.

\d resource

------------+--------------------------+-----------+----------+---------
 id         | uuid                     |           | not null | 
 name       | character varying(255)   |           | not null | 
 code       | character varying(255)   |           | not null | 

I've tried adding djago.contrib.postgres to installed apps, without luck.

Am I missing something? Already tried --include-views and --include-partitions too.

The error:

# The error was: sequence index must be integer, not 'slice'

Change History (3)

comment:1 by Gui Pedreira, 5 years ago

Description: modified (diff)

comment:2 by Gui Pedreira, 5 years ago

Description: modified (diff)

comment:3 by Mariusz Felisiak, 5 years ago

Easy pickings: unset
Resolution: duplicate
Status: newclosed

This issue is not related with an UUID field. Django 2.2 doesn't support psycopg 2.8+, it will be fixed in 2.2.1 release.

Duplicate of #30331.

Note: See TracTickets for help on using tickets.
Back to Top