python-lunardate icon indicating copy to clipboard operation
python-lunardate copied to clipboard

a better error than IndexError

Open lidaobing opened this issue 5 years ago • 0 comments

>>> a = lunardate.LunarDate(1,2,3)
>>> a.toSolarDate()
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/local/lib/python3.7/site-packages/lunardate.py", line 190, in toSolarDate
    offset += _calcDays(yearInfos[yearIdx], self.month, self.day, self.isLeapMonth)
IndexError: list index out of range

lidaobing avatar Mar 29 '19 01:03 lidaobing