Europass import: every added entry gets order 0 and lands under the first one, not where its date puts it #618
Labels
No labels
accessibility
authentication
breaking change
bug
documentation
enhancement
interface
internationalisation
observability
performance
security
tier
1
tier
2
tier
3
tier/4
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
Postulo/postulo#618
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Found on 2026-09-29 in a read-only review of postulo at
95348908d, comparing how each writer of career entries setsorder, and settled by importing into a career that already had entries.Checked again on 2026-10-01 against
mainat0a5cad587: still present. The code is where it was; the wiki paragraph is now atYour-career-record.md:509-512(postulo.wiki at9aefad9b6), in the same words.Since #203 each career section's order is dense and belongs to the person: a new dated entry is placed by its date and anything else goes last. The create view does this through
ordering.place_new, and the candidate-file importer throughcandidate._place. The Europass writer does neither.importing.applycreates every experience, education, language, skill group, skill and project withobjects.create()and never setsorder, so each one keeps the default 0. Sections sort on("order", "pk"), so every imported row lands straight after the existing entry at 0 and before the one at 1, in file order, whatever its date.resume/importing.py:189-254(apply; no call intoorderinganywhere in the module); the rule it skips isresume/ordering.py:81-98(place_new), used byresume/views.py:278and mirrored byresume/candidate.py:1334-1375(_place). The wiki pageYour-career-record.md:502-505promises that a new experience, education or certification "lands where its date would put it" and anything else goes at the end.place_new, then an import of jobs starting in 2022 and 2010. The section readsr2024 (0),r2022 (0),r2010 (0),r2020 (1),r2016 (2): the 2010 job sits above two newer ones. Imported languages, projects and skill groups likewise land second rather than last, and the numbers are no longer dense until an arrow is pressed.importing.applycreates ascandidate._placedoes: byordering.DATE_FIELDSwhere the section has a date, last otherwise, then renumber densely. Moving that placement intoresume/ordering.pyand calling it from both importers would keep them from drifting.Done when
tests/test_career_ordering.pyimports a Europass record into a career that already has dated experience and undated projects, and asserts that the experience reads newest first with dense numbers and that the projects come last.