Opened 4 years ago

Closed 4 years ago

Last modified 4 years ago

#30388 closed Cleanup/optimization (fixed)

inspectdb generates unique ForeignKey instead of OneToOneField.

Reported by: Ville Skyttä Owned by: Ville Skyttä
Component: Database layer (models, ORM) Version: dev
Severity: Normal Keywords:
Cc: Triage Stage: Accepted
Has patch: yes Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description (last modified by Mariusz Felisiak)

inspectdb generates unique ForeignKey instead of OneToOneField that caused raising fields.W342 warnings.

Change History (5)

comment:1 Changed 4 years ago by Ville Skyttä

Has patch: set

comment:2 Changed 4 years ago by Mariusz Felisiak

Description: modified (diff)
Summary: inspectdb generates W342 emitting codeinspectdb generates unique ForeignKey instead of OneToOneField.
Triage Stage: UnreviewedAccepted
Version: 2.2master

comment:3 Changed 4 years ago by Mariusz Felisiak

Owner: changed from nobody to Ville Skyttä
Status: newassigned

comment:4 Changed 4 years ago by Mariusz Felisiak <felisiak.mariusz@…>

Resolution: fixed
Status: assignedclosed

In 0f22671e:

Fixed #30388 -- Made inspectdb generate OneToOneFields rather than ForeignKey(unique/primary_key=True).

comment:5 Changed 4 years ago by Mariusz Felisiak <felisiak.mariusz@…>

In 85676979:

Refs #30388 -- Added release note for 0f22671ecb7e9555300fd2d6cb7bf6dc61735d07.

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