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

Rebase of #423 to add docs, hopefully ready for merge #1099

Merged
merged 2 commits into from
Sep 13, 2018

Conversation

sirosen
Copy link
Contributor

@sirosen sirosen commented Aug 27, 2018

#423 is pending on a documentation addition.
As with many other old PRs, I don't think we should necessarily expect the original author to come back to things. Trying to cleanup the backlog.

I considered pushing to the #423 branch, but I wanted to drop the commit which makes things py2.6 compatible (since it's no longer relevant) and dropping a commit from someone else's PR is bad form.

So, to restate:

  • adds click.DateTime type with a couple of tests
  • adds documentation for the above on the param types page
  • adds another ISO 8601 format string to the defaults: %Y-%m-%d %H:%M:%S, which is pretty commonly used in my experience
  • add a note to the changelog containing this new type

closes #423

@sirosen sirosen requested a review from dsully August 27, 2018 23:06
@sirosen sirosen force-pushed the type-datetime branch 3 times, most recently from bf934ef to 2d12764 Compare August 28, 2018 15:12
santiagobasulto and others added 2 commits September 13, 2018 07:27
Add a docstring which defines the behaviors of the class, including
default formats supported, usage of ``datetime.strptime`` and "first
successful parse wins" behavior.

Also add '%Y-%m-%d %H:%M:%S' to the default formats, as it is at least
as commonly seen as '%Y-%m-%dT%H:%M:%S'.
Minor test fix to handle the new format.

Add ``click.DateTime`` to changelog.
@davidism davidism added this to the 7.0 milestone Sep 13, 2018
@davidism davidism merged commit 2c622ee into pallets:master Sep 13, 2018
@enricobarzetti enricobarzetti mentioned this pull request Aug 20, 2020
6 tasks
@pallets pallets locked as resolved and limited conversation to collaborators Aug 25, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants