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

Deal better with time zones and non-specific dates #337

Closed
ietf-svn-bot opened this issue Dec 1, 2017 · 3 comments
Closed

Deal better with time zones and non-specific dates #337

ietf-svn-bot opened this issue Dec 1, 2017 · 3 comments
Labels

Comments

@ietf-svn-bot
Copy link

owner:henrik@levkowetz.com resolution_fixed type_defect | by martin.thomson@gmail.com


When xml2rfc is used through a web service or as part of the datatracker submission tool, the client may be in a different time zone than the server, which can cause trouble with the element when the month shifts:

From the automated draft submission:

Validation Error: {'document_date': [u'Document date must be within 3 days of submission date']}

It's December in this part of the planet, soon to be all of the planet, but clearly it's still November whereever the server is running. The draft contains a date field as so:

<date year="2017" month="December"/>

Arguably the date is correct.


Issue migrated from trac:337 at 2022-02-05 12:43:51 +0000

@ietf-svn-bot
Copy link
Author

@henrik@levkowetz.com changed status from new to closed

@ietf-svn-bot
Copy link
Author

@henrik@levkowetz.com changed resolution from `` to fixed

@ietf-svn-bot
Copy link
Author

@henrik@levkowetz.com commented


Fixed in 573a8bd:

Changed the way defaults are calculated. Previously, today's
date were used to populate missing day if month and year matched, and
to populate month if year matched. However, if today's date lay in an
adjoining month, even if it was within days of that month, the day
would be set to the first of the given month. This commit changes that,
to use the last day of the month instead of the first of the month, if
the month is the previous month to today's date. This will result in
a different derived date than earlier, closer to today's date. This
fixes issue #337.

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

No branches or pull requests

1 participant