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

khal adding new issue doesnt work with weekly flag #1231

Open
Iss-in opened this issue Apr 6, 2023 · 0 comments
Open

khal adding new issue doesnt work with weekly flag #1231

Iss-in opened this issue Apr 6, 2023 · 0 comments

Comments

@Iss-in
Copy link

Iss-in commented Apr 6, 2023

Im am trying to create a weekly recurring task for khal, but its crashing due to some timezone issue

command used

khal new -a private 06/04/2023 sample task -r weekly

log

Traceback (most recent call last):
  File "/usr/bin/khal", line 5, in <module>
    main_khal()
  File "/usr/lib/python3.10/site-packages/click/core.py", line 1130, in __call__
    return self.main(*args, **kwargs)
  File "/usr/lib/python3.10/site-packages/click/core.py", line 1055, in main
    rv = self.invoke(ctx)
  File "/usr/lib/python3.10/site-packages/click/core.py", line 1657, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/usr/lib/python3.10/site-packages/click/core.py", line 1404, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/usr/lib/python3.10/site-packages/click/core.py", line 760, in invoke
    return __callback(*args, **kwargs)
  File "/usr/lib/python3.10/site-packages/click/decorators.py", line 26, in new_func
    return f(get_current_context(), *args, **kwargs)
  File "/usr/lib/python3.10/site-packages/khal/cli.py", line 394, in new
    new_func(
  File "/usr/lib/python3.10/site-packages/khal/controllers.py", line 378, in new_from_string
    new_from_args(
  File "/usr/lib/python3.10/site-packages/khal/controllers.py", line 393, in new_from_args
    event = new_vevent(
  File "/usr/lib/python3.10/site-packages/khal/icalendar.py", line 132, in new_event
    rrule = rrulefstr(repeat, until, locale, dtstart.tzinfo)
AttributeError: 'datetime.date' object has no attribute 'tzinfo'

khal config

[calendars]

[[private]]
path = /home/kushy/.local/share/khal/calendars/private
type = calendar


[locale]
timeformat = %I:%M %p
dateformat = %d/%m/%Y
longdateformat = %d/%m/%Y
datetimeformat = %d/%m/%Y %I:%M %p
longdatetimeformat = %d/%m/%Y %I:%M %p



[default]
default_calendar = private

command works, if i remove -r weekly , or give it a time
khal new -a private 06/04/2023 08:00 AM sample task -r weekly

shouldnt it be picking up my local time ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants