zhdate
A pachage to convert Chinese Lunar Calendar to datetime
Decision gist · record as of 2026-08-14
No, unless you are on macOS ARM64 and specifically need lunar calendar conversion. The high install friction (platform-specific wheel, dormant maintenance, unspecified Python version support) and copyleft license (GPLv3+) make it unsuitable for most projects. If you need lunar calendar support on other platforms, verify that the package builds from source or consider alternatives.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- The package distributes a macOS ARM64 wheel; installation on other platforms (Linux, Windows, or non-ARM macOS) may fail or require building from source.
- Python version requirements are unspecified.
- High install friction: the package distributes a pre-built macOS ARM64 wheel as its primary artifact, which will not install on other platforms.
License · maintenance · safety
copyleft license (copyleft) — Licensed under GPLv3+, a copyleft license requiring that any derivative work or distribution also be licensed under GPL. This restricts use in proprietary or closed-source projects.
last release 2023-01-21 (1301 days) · last repo commit 2024-02-11 · 115 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 109,316 downloads/mo, #12,519 on PyPI
Alternatives
Verify before relying
from zhdate import ZhDate
from datetime import datetime
# Create lunar date for 2010 lunar year, month 1, day 1
date1 = ZhDate(2010, 1, 1)
print(date1) # Prints lunar date string
# Convert lunar to gregorian
dt_date1 = date1.to_datetime()
# Convert gregorian to lunar
dt_date2 = datetime(2010, 2, 6)
date2 = ZhDate.from_datetime(dt_date2)- Whether the package builds successfully on Linux, Windows, or Intel macOS without the prebuilt wheel
- Minimum and maximum Python versions supported (requires_python is empty in metadata)
- Whether the lunar calendar calculations are accurate for dates outside the 2010–2023 range
What it is and what it does
ZhDate is a Python library for working with Chinese lunar calendar dates. It performs bidirectional conversion between lunar dates and Gregorian datetime objects entirely through local computation, without calling external APIs. The library represents lunar dates as objects with year, month, and day fields, and supports leap months—a feature of the lunar calendar where an extra month is inserted periodically. It also implements arithmetic operations: you can add or subtract days from a lunar date, or subtract two lunar dates to find the number of days between them.
The package is intended for applications that need to work with traditional Chinese dates—such as calendar systems, holiday calculators, or cultural event scheduling. It has no runtime dependencies and operates as a standalone date-conversion utility. However, the package is dormant (last release January 2023, last commit February 2024) and distributes primarily as a macOS ARM64 wheel, creating significant installation friction on other platforms.
Use it for
- Convert Chinese lunar calendar dates to Gregorian dates for scheduling or calendar applications.
- Calculate the number of days between two lunar dates or between a lunar and gregorian date.
- Generate lunar calendar displays or holiday calendars that recognize traditional Chinese festivals by lunar date.
- Parse or validate lunar date input in applications serving Chinese-speaking users.
- Perform date arithmetic on lunar dates (e.g., 'what lunar date is 30 days from now').
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
No, unless you are on macOS ARM64 and specifically need lunar calendar conversion.
The high install friction (platform-specific wheel, dormant maintenance, unspecified Python version support) and copyleft license (GPLv3+) make it unsuitable for most projects. If you need lunar calendar support on other platforms, verify that the package builds from source or consider alternatives.
Install
zhdate on PyPI
Before you install
High install friction: the package distributes a pre-built macOS ARM64 wheel as its primary artifact, which will not install on other platforms. Last commit was 2024-02-11 and the project is marked dormant, with no releases since 2023-01-21.
The package distributes a macOS ARM64 wheel; installation on other platforms (Linux, Windows, or non-ARM macOS) may fail or require building from source. Python version requirements are unspecified.
License in practice
Licensed under GPLv3+, a copyleft license requiring that any derivative work or distribution also be licensed under GPL. This restricts use in proprietary or closed-source projects.
Quickstart
from zhdate import ZhDate
from datetime import datetime
# Create lunar date for 2010 lunar year, month 1, day 1
date1 = ZhDate(2010, 1, 1)
print(date1) # Prints lunar date string
# Convert lunar to gregorian
dt_date1 = date1.to_datetime()
# Convert gregorian to lunar
dt_date2 = datetime(2010, 2, 6)
date2 = ZhDate.from_datetime(dt_date2)
Verify before relying
- Whether the package builds successfully on Linux, Windows, or Intel macOS without the prebuilt wheel
- Minimum and maximum Python versions supported (requires_python is empty in metadata)
- Whether the lunar calendar calculations are accurate for dates outside the 2010–2023 range
Package facts
| License | copyleft license copyleft |
| Python support | Not specified |
| Install friction | High. Source build required |
| Runtime dependencies | None |
| Maintenance | Dormant 1,301 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 109,316 / month, #12,519 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
| Classifiers | License :: OSI Approved :: GNU General Public License v3 or later (GPLv3+)Operating System :: OS IndependentProgramming Language :: Python :: 3 |
Evidence: zhdate-1.0.macosx-11.0-arm64.tar.gz
Tags
Let your AI agent find packages like this
Example. Real query, live index.
You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.
wish › “zhdate lunar calendar”
- zhdateConverts between Chinese lunar calendar dates and Gregorian datetime…
- lunardateConverts between Gregorian (solar) and Chinese (lunar) calendar…
- korean-lunar-calendarConverts dates between the Korean lunar calendar and Gregorian solar…
Give your agent the search over MCP, or paste the wish link into any chat.
More Utilities packages
Converts domain names between Unicode and ASCII-compatible encoding (Punycode) according to IDNA 2008 and Unicode Technical Standard 46, with security validation and broader script coverage than the standard library.
Install it if you work with internationalized domain names, need to validate domains, or use HTTP clients that depend on it transitively.
Detects and normalizes text encoding from unknown or ambiguous sources, supporting all IANA character sets that Python's core library provides codecs for, with the ability to register custom codecs.
Setuptools is a Python build backend and package management tool that handles building, distributing, and installing Python packages, including support for C/C++ extension modules.
Pluggy provides a plugin system that lets you define hook specifications and register implementations to be called in sequence, enabling extensible Python applications without tight coupling.
Install it if you're building an extensible application or framework.
Pygments is a syntax highlighter that colorizes source code and text in over 500 languages and formats, outputting to HTML, LaTeX, RTF, SVG, images, or ANSI terminal sequences.
Install it if you need to display or transform source code.
Six provides utility functions to write Python code that runs on both Python 2.7 and Python 3.3+, smoothing over language differences between the two versions.
See also lunardate · jdcal · LunarCalendar · korean-lunar-calendar · lunar_python · sxtwl · convertdate · ntplib · jdatetime · chinese-calendar