Releases: ariebovenberg/whenever
Releases · ariebovenberg/whenever
0.4.0
A big release with the main feature being the addition of date/time deltas.
I've also tried to bundle as many small breaking changes as possible into
this release, to avoid having to do them in the future.
For the rationale behind each breaking change, see the full changelog
Breaking changes
LocalDateTime
renamed toLocalSystemDateTime
.LocalSystemDateTime
no longer adjusts automatically to changes in the system timezone. Now,LocalSystemDateTime
reflects the system timezone at the moment of instantiation. It can be updated explicitly.- The
disambiguate=
argument now also determines how non-existent times are handled. from_naive()
removed in favor of methods onNaiveDateTime
. For example,UTCDateTime.from_naive(n)
becomesn.assume_utc()
.- Renamed
ZonedDateTime.disambiguated()
to.is_ambiguous()
. - Replaced
.py
property with.py_datetime()
method. - Removed properties that simply delegated to the underlying
datetime
object:tzinfo
,weekday
, andfold
.date
andtime
now returnwhenever.Date
andwhenever.Time
objects. - Renamed
.canonical_str()
to.canonical_format()
. - Renamed
DoesntExistInZone
toSkippedTime
,Ambiguous
toAmbiguousTime
. - Renamed
min
andmax
toMIN
andMAX
.
Improved
- Added a
disambiguation="compatible"
option that matches the behavior of other languages and the RFC5545 standard. - Shortened the
repr()
of all types, use space separator instead ofT
. - Added
sep="T" or " "
option tocanonical_format()
OffsetDateTime
constructor and methods creating offset datetimes now accept integers as hour offsets.- Added
Date
andTime
classes for working with dates and times separately.
0.3.4
0.3.3
0.3.2
0.3.1
0.3.0
Breaking changes
- 🥒 Change pickle format so that backwards-compatible unpickling is possible in the future.
Added
- 🔨 Added
strptime()
toUTCDateTime
,OffsetDateTime
andNaiveDateTime
. - 📋 Added
rfc2822()
/from_rfc2822()
toUTCDateTime
,OffsetDateTime
andNaiveDateTime
. - ⚙️ Added
rfc3339()
/from_rfc3339()
toUTCDateTime
andOffsetDateTime
0.2.1
- added
days()
timedelta alias - Improvements to README, other docs
0.2.0
Breaking changes
-
📐Disambiguation of local datetimes is now consistent with zoned datetimes, and is also run on
replace()
. -
👌Renamed:
from_str
→from_canonical_str
to_utc/offset/zoned/local
→as_utc/offset/zoned/local
.ZonedDateTime.zone
→ZonedDateTime.tz
Added
- ⚖️ Support comparison between all aware datetimes
- 🧮Support subtraction between all aware datetimes
- 🍩 Convenience methods for converting between aware/naive
- 💪 More robust handling of zoned/local edge cases
Docs
- Cleaned up API reference
- Added high-level overview
0.1.0
The first feature-complete release 🚀
- ✅ Implemented
OffsetDateTime
,ZonedDateTime
andLocalDateTime
- ✨ Clarify documentation (reasoning and datetime pitfalls)
0.0.3
🌐 Implement basic UTC-only DateTime