Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow {start|end}_date to be less precise than a specific day #4

Closed
jpgoldberg opened this issue Nov 3, 2023 · 3 comments
Closed
Assignees
Labels
enhancement New feature or request

Comments

@jpgoldberg
Copy link
Contributor

I would like to specify start and end dates in terms of months. For example

 education:
    - institution: University of California, Santa Cruz
        url: https://ucsc.edu
        area: Linguistics
        study_type: BA
        location: Santa Cruz, Calinfornia, USA
        start_date: "1979-09"
        end_date: "1984-06"

As you might imagine, I am disinclined to dig through 40 year old records to determine the precise day of the month for those events, and anyone reading the CV isn't going to care.

Describe the solution you'd like
start_date and end_date should allow YYYY-MM and YYYY forms of RFC3339 dates.

Additional context

I suspect that "1979-09" is a valid RFC3339 date, in which case my feature request may be considered a bug report.

I haven't looked at the source code (yet) to see if I can produce a useful pull request.

@jpgoldberg jpgoldberg added the enhancement New feature or request label Nov 3, 2023
@jpgoldberg
Copy link
Contributor Author

I now see that this constraint is coming from the python standard datetime library.

>>> from datetime import date
>>> date.fromisoformat('1979-09')
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
ValueError: Invalid isoformat string: '1979-09'

Oh well. I guess this is a difficult feature request instead of a quick fix.

sinaatalay added a commit that referenced this issue Nov 3, 2023
@sinaatalay
Copy link
Owner

It was indeed a feature request but a necessary one. If the date data is not there with month and day precision, it should be totally fine with RenderCV.

I coded a custom date parser. I didn't write tests for it yet, but it seemed fine with a few manual runs. I will release RenderCV with this new feature in ~20 minutes.

Thank you!

@jpgoldberg
Copy link
Contributor Author

I don't see a way to reopen this issue, so I will create a new one pointing out that the fix ran in a problem.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants