CVs: with contact details off, the holder's name is still in the PDF title, the file name and the DOCX title #512
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#512
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, by reading how a CV's title is built and rendering a CV with its contact block off.Checked again on 2026-10-01 against
mainat0a5cad587: still present. The code is now atdocuments/rendering.py:62-74(document_title),documents/rendering.py:630-653(the snapshot's title and file name),documents/rendering.py:552-560(draft_name),documents/rendering.py:380(the titlecv_outlinegives) anddocuments/models.py:716(RenderedDocument.download_name); the themes,documents/views.py,documents/docx.py:250and the test have not moved.Unticking include contact details takes the name off the page and out of the PDF's
/Author, and the theme says why: "Somebody who left their name off a CV on purpose did not mean 'except in the file's properties'" (templates/documents/themes/base_cv.html:27-28). Butdocument_title()always leads with the holder's full name, and that title is used everywhere a document is named on its way out. The wiki (CVs.md) offers the switch "for an anonymised copy", so a person relying on it sends their name all the same.documents/rendering.py:55-67,document_title:"%(name)s — %(kind)s"fromdocument_holder(), with no regard forshow_contact_details.<title>(base_cv.html:26,base_portfolio.html:24), which the PDF renderer writes as/Title; the snapshot'stitleand file name (rendering.py:656-679,f"{slugify(title) or 'cv'}.pdf"), andRenderedDocument.download_name(documents/models.py:688);draft_name(rendering.py:578-586), used for the draft PDF's name (documents/views.py:135); andcv_outline(...).title(rendering.py:406), used for the.txt/.docxdownload name (documents/views.py:432) and the DOCX<dc:title>(documents/docx.py:250).tests/test_pdf_render.py:201-205,test_a_cv_with_its_contact_block_off_names_nobody_in_the_file, checks only/Author.show_contact_details=Falsefor Alex Morgan, the rendered HTML has no author meta and no name in the body, but<title>is "Alex Morgan — CV",draft_nameis "Alex Morgan — CV (draft)" and the outline title is "Alex Morgan — CV". A recruiter opening the PDF sees the name in the viewer's title bar, and the uploaded file is calledalex-morgan-cv.pdf.document_titlethe CV's choice: whenshow_contact_detailsis off, leave the holder out and title the document by its kind (or by the headline the page prints as itsh1). Every caller above then follows. Related to #223, which moved the title from the variant name to "holder — kind" and did not consider the anonymous case; #308 (open) will widen the contact choice and should keep this rule.Done when
tests/test_pdf_render.pyalso asserts that the holder's name is absent from/Title, fromrendering.draft_name(cv), fromcv_outline(cv).titleand from the snapshot's file name whenshow_contact_detailsis off; it fails today.