Parse-opening-hours

Latest version: v0.4.2

Safety actively analyzes 683530 Python packages for vulnerabilities to keep your Python projects secure.

Scan your dependencies

Page 1 of 2

0.4.2

- convert times to military time when printing the string reperesentation of a Times object
- correctly handle strings like "12pm" and "12am" so they correctly parse to "12:00" and "0:00" in military time respectively

0.4.1

- Make the internal `Times` object available for import to allow for parsing a known time string (i.e. "700AM-500PM")

0.4

- support optional prefix of "open" on strings, like "open monday 9am-5pm"
- support shortcuts like "open 24 hours a day" and "24/7"
- package is now imported as `opening_hours` instead of `parse_opening_hours` (see example in README)

0.3.1

The pypi build for v0.3 contained additional information from the local working tree that was not committed to the repository and may have introduced some unintended behavior (all tests still passed though). This re-build and re-release removes this information from the production package.

0.3

- [BREAKING] rename the main class to OpeningHours since its not exclusive to json
- more refactoring and cleanup
- add generated documentation page
- improve robustness of some of the matching patterns
- count the single-letter "H" as "thursday" when used as a day (i.e. "H 9am - 5 pm")
- parse the word "from" as a separator between dates and times (i.e. "Monday from 9:00 - 5:00")
- support dots following abbreviated days of the week (i.e. "Mon.")
- support commas separating days and times (i.e. Monday, 9am - 5pm")
- support times in military style (i.e. "Monday 0900-1700")
- support short/abbreviated AM/PM designations (i.e. "9a - 5p" and "9a. to 5p.")

0.2

Changelog
- support plural day names with appostrophes (i.e. "Monday's 9am to 5 pm")
- support listing specific days (i.e. "Mondays, Tuesdays, Thursdays 9am to 5 pm")
- add support for commonly used shortcuts like "7 days a week" "daily" "weekdays" "business days" "weekends" .etc
- treat no specified days (i.e. "9am to 5pm") the same as "every day"
- made parsing of day names more robust

Page 1 of 2

Links

Releases

© 2024 Safety CLI Cybersecurity Inc. All Rights Reserved.