IKermani / jcalendar

Jalali version of python calendar :date:
https://pypi.org/project/jcalendar/
Other
10 stars 1 forks source link

Example of usage? #2

Open anufrievroman opened 2 years ago

anufrievroman commented 2 years ago

Hello, thank you for your work. I'm trying to use this library in my calcure project. However, it does not really work how I'd expect it to. For example, with the regular calendar library, I write something like:

import calendar
my_cal = calendar.Calendar()
print(my_cal.monthdayscalendar(2010, 10))

Now, I expect to do the same but with jcalendar instead:

import jcalendar
my_cal = jcalendar.Calendar()

But already here the error says AttributeError: module 'jcalendar' has no attribute 'Calendar'

I looked at your code and everything seems fine, so I am not sure what I am missing. From your example, I also couldn't really understand why you are writing calendar and not jcalendar. Sorry if it is something obvious.