Sentinel Result Object for python-dateutil
Project description
Sentinel Datetime
For python-dateutil
Inspired by a stackoverflow question, for when you want to know a little more about the datetime strings you are parsing with python-dateutil
Install
pip install sentinel-datetime
Usage
>>> from dateutil import parser
>>>
>>> from sentinel_datetime import sentinel
>>>
>>> date = parser.parse("Sep-2nd 11:00:00", default=sentinel())
>>> date.has_day
True
>>> date.has_year
False
>>> date.todatetime()
2021-09-02 11:00:00
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for sentinel_datetime-0.0.4-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | b777c3af81f8956967f49da1d70efd68061573ed2e502db13f1e3ba40911e8f6 |
|
MD5 | 0e6f4df433267401a3dc3e31534f936e |
|
BLAKE2b-256 | 8c7bae04e0fb4b3fc847fe507abdc21dab47f9c30d2cbd6f37372b7e9ce1830f |