This Python library provides functionalities to convert between the Gregorian (solar) calendar and the Korean lunisolar calendar, adhering to the standards of the Korea Astronomy and Space Science Institute (KASI). It supports a date range from 1000-01-01 to 2050-11-18 for lunar dates and 1000-02-13 to 2050-12-31 for solar dates. The current version is 0.3.1.
pip install korean-lunar-calendarVerified import paths — ran on the pinned version, not inferred.
Initialize the calendar, then use `setSolarDate` or `setLunarDate` to perform conversions and retrieve results using `getLunarCalendar`, `getSolarCalendar`, `getKoreanGapja`, or `getChineseGapja`.
Ensure input dates fall within the supported range (1000 to 2050).
Be aware that results may not align with Chinese lunar calendar calculations. This library is specific to the Korean system.
Always provide the correct `intercalation` boolean parameter when calling `setLunarDate` to ensure accurate conversions.
For production systems, monitor releases for potential breaking changes. Consider pinning exact versions to mitigate unexpected updates.
Ensure the package is installed correctly and import it using underscores: `pip install korean-lunar-calendar` (for installation) and `from korean_lunar_calendar import KoreanLunarCalendar` (for import).
Verify the capitalization of the class name `KoreanLunarCalendar` and ensure it's imported directly from the module as shown in the documentation: `from korean_lunar_calendar import KoreanLunarCalendar`.
Adjust the input date to be within the supported range of the `korean-lunar-calendar` library before calling conversion methods like `setSolarDate()` or `setLunarDate()`.
No dependency data recorded yet.