A simple utility for calculating business time aware timedeltas between two datetimes
Project description
businesstime
BusinessTime is a simple utility for calculating business time aware timedeltas between two datetimes. BusinessTime’s understanding of weekends, holidays and business hours can be easily configured in code.
>>> datetime(2013, 12, 26, 5) - datetime(2013, 12, 23, 12)
datetime.timedelta(2, 61200)
>>> bt = businesstime.BusinessTime(holidays=businesstime.USFederalHolidays())
>>> bt.businesstimedelta(datetime(2013, 12, 23, 12), datetime(2013, 12, 26, 5))
datetime.timedelta(1, 18000)
Features
Simple, pythonic, business-time-aware datetime math
A simple declarative format for defining holidays
A number of useful iterators/predicate functions related to holidays/weekends/business hours
0.1.3
Fixed a bug (#3) where the first instant of a business day was not considered part of that day
0.1.2
Fix changelog
0.1.1
Fix pypi package
0.1.0
Public Release
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
businesstime-0.1.3.tar.gz
(4.2 kB
view hashes)
Built Distribution
Close
Hashes for businesstime-0.1.3.macosx-10.8-x86_64.exe
Algorithm | Hash digest | |
---|---|---|
SHA256 | 9fce15aef7cdfca227e45e52cb56d3e4f9752ff0faf3950c278ecf3d2ccbfc8f |
|
MD5 | acb53a0e1a103d2a0ea0d9c0e49aea3b |
|
BLAKE2b-256 | e69c602ec712534996c97c741a6d7de8522ee05327eec2761593339af3c30f41 |