Portfolio: a current role or course prints only its start year, as if it had ended that year #515
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#515
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, reading the portfolio theme and the plain-text rendering of the same sections.Checked again on 2026-10-01 against
mainat0a5cad587: still present. The code is now atdocuments/rendering.py:259-260(_period(..., years_only=True)), called from_section_blocksatdocuments/rendering.py:345; the two theme templates andresume/models.py:77-79have not moved.A portfolio sets experience and education one line each, with years only. When an entry has no end date, which the form asks for a current role ("Leave empty if this is your current role.",
resume/models.py:77-79), the line prints the start year alone: no dash and no "present". The same template's project entries (base_portfolio.html:66-69) and the CV theme (base_cv.html:115) both print "– present" for an open end, and so does_periodwhen it is not asked for years only.templates/documents/themes/base_portfolio.html:135-139(thebackgroundlist; theclassicandplainportfolios extend it and do not override it), anddocuments/rendering.py:285-286(_period(..., years_only=True), used by_section_blocksatdocuments/rendering.py:371for the portfolio's text and DOCX).base_portfolio.html, add the open-ended branch the project entries already have:{% if entry.item.end_date %}…{% elif entry.item.start_date %} – {% translate "present" %}{% endif %}. In_period, whenyears_onlyand there is a start but no end, returnf"{start.year} – {gettext('present')}", so that the text and the page still say the same line.Done when
tests/test_page_rendering.pyrenders a portfolio with an experience that has a start date and no end date, and asserts that both the rendered HTML and the portfolio's text outline contain the start year followed by "present".