Opened 7 years ago

Last modified 3 years ago

#11929 assigned Cleanup/optimization dumpdata outputs YAML in unhelpful order

Reported by: sampablokuper Owned by: AeroNotix
Component: Core (Serialization) Version: 1.1
Severity: Normal Keywords:
Cc: sam.kuper@… Triage Stage: Accepted
Has patch: yes Needs documentation: no
Needs tests: yes Patch needs improvement: no
Easy pickings: no UI/UX: no


The docs suggest providing initial YAML data in the following format:

- model: myapp.person
  pk: 1
    first_name: John
    last_name: Lennon

but the dumpdata outputs YAML in the following form:

-   fields: {first_name: John, last_name: Lennon}
    model: myapp.person
    pk: 1

The fact that this is flow rather than block style YAML is the subject of #11927, but there's another problem, which is that rather than putting the model and PK first (which is most human-readable), dumpdata outputs the fields first.

Change History (8)

comment:1 Changed 7 years ago by sampablokuper

  • Needs documentation unset
  • Needs tests unset
  • Patch needs improvement unset

This might be helpful for generating a patch.

comment:2 Changed 7 years ago by russellm

  • Triage Stage changed from Unreviewed to Accepted

comment:3 Changed 5 years ago by julien

  • Severity set to Normal
  • Type set to Bug

comment:4 Changed 5 years ago by aaugustin

  • UI/UX unset

Change UI/UX from NULL to False.

comment:5 Changed 5 years ago by aaugustin

  • Easy pickings unset

Change Easy pickings from NULL to False.

comment:6 Changed 4 years ago by ladyrassilon

  • Owner changed from nobody to ladyrassilon

comment:7 Changed 3 years ago by AeroNotix

  • Owner changed from ladyrassilon to AeroNotix
  • Status changed from new to assigned

comment:8 Changed 3 years ago by timo

  • Has patch set
  • Needs tests set
  • Type changed from Bug to Cleanup/optimization

The current PR needs a test.

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