Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

v2.4.2: Select February 30th of the lunar year causes Unexpected Application Error! #194

Open
LucasJi opened this issue Jun 20, 2024 · 1 comment
Assignees
Labels
漏洞|bug Something isn't working

Comments

@LucasJi
Copy link

LucasJi commented Jun 20, 2024

描述(Description)

Just as the title says, when selecting Feb 30, the online astrolabe shows an error page.
image

I would appreciate it if the author could add exception handling. This would make not only this library but also the React hook iztro-hook more flexible for other developers in resolving exceptions.

版本(Version)

重现(Reproduce)

  • 调用的方法(funciton name)

lunar2solar

  • 参数(parameters)

1997-2-30(Lunar)

  • 返回值(returns)
Unexpected Application Error!
only 29 days in lunar year 1997 month 2
Error: only 29 days in lunar year 1997 month 2
    at zr.fromYmdHms (https://ziwei.pub/assets/main-9b6d5ef5.js:531:433671)
    at zr.fromYmd (https://ziwei.pub/assets/main-9b6d5ef5.js:531:433418)
    at a (https://ziwei.pub/assets/main-9b6d5ef5.js:531:471599)
    at S (https://ziwei.pub/assets/main-9b6d5ef5.js:531:490662)
    at Object.w (https://ziwei.pub/assets/main-9b6d5ef5.js:531:490919)
    at https://ziwei.pub/assets/main-9b6d5ef5.js:531:545457
    at Ax (https://ziwei.pub/assets/main-9b6d5ef5.js:40:24296)
    at ih (https://ziwei.pub/assets/main-9b6d5ef5.js:40:42448)
    at JV (https://ziwei.pub/assets/main-9b6d5ef5.js:40:34557)
    at E (https://ziwei.pub/assets/main-9b6d5ef5.js:25:1540)
@LucasJi LucasJi added the 漏洞|bug Something isn't working label Jun 20, 2024
@LucasJi LucasJi changed the title [version]: Select February 30th of the lunar year causes Unexpected Application Error! v2.4.2: Select February 30th of the lunar year causes Unexpected Application Error! Jun 20, 2024
@SylarLong
Copy link
Owner

@LucasJi thank you for reporting. I'll catch the exception soon.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
漏洞|bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants