Sounds promising.
When would you expect will your enhancements to the plugin touch the streamline?
Do you have an idea on the issue concerning the induvidually deleted calendar entry which still is reported by the plugin?
Created the pull request right now
Hi,
I refreshed gcal binding to use oauth. Please help me with testing:
here is insrtuction how to enable bindings:
Hello,
A new problem has appeared in the last couple of days.
The binding was working just fine and started doing this
I have not changed any settings.
[ERROR] [o.caldav.internal.job.EventJob] - error executing event job
org.quartz.JobExecutionException: cannot get event-container for config: openhabcalendar and eventId: sr2chel3fdgaq4rt05kif9os0o_R20161006T060000@google.com
at org.openhab.io.caldav.internal.job.EventJob.execute(EventJob.java:45) ~[na:na]
at org.quartz.core.JobRunShell.run(JobRunShell.java:213) [quartz-all-2.1.7.jar:na]
at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:557) [quartz-all-2.1.7.jar:na]
Any ideas?
Thanks
Vincent
I feel like weāre so close to having the GCal service in good working order again!
Please others:
Test it out and provide feedback, recommend changes to the wiki page to make it clear how to proceed. Thank you!
I will have a look on this problem next week. Are you using the pr build?
Is this problem solved? I found this thread fits to my issue. I installed yesterday the CalDav Binding in order to have my garbage calendar in openhab. I already have defined items and the sitemap to display the next event - everything works perfect so far. Today I have checked the logs in /var/log/openhab2 and I noticed that a bunch of logfiles are generated.
In the log I see similar error as mentioned in this thread:
2016-12-31 11:25:37.071 [ERROR] [caldav.internal.job.EventReloaderJob] - error reading ics file: AWIDO-PM-20170814T000000
com.github.sardine.impl.SardineException: Unexpected response (401 Unauthorized)
at com.github.sardine.impl.handler.ValidatingResponseHandler.validateResponse(ValidatingResponseHandler.java:48)[213:org.openhab.io.caldav:1.9.0.201612300210]
at com.github.sardine.impl.handler.VoidResponseHandler.handleResponse(VoidResponseHandler.java:34)[213:org.openhab.io.caldav:1.9.0.201612300210]
at com.github.sardine.impl.SardineImpl.get(SardineImpl.java:756)[213:org.openhab.io.caldav:1.9.0.201612300210]
at com.github.sardine.impl.SardineImpl.get(SardineImpl.java:741)[213:org.openhab.io.caldav:1.9.0.201612300210]
at com.github.sardine.impl.SardineImpl.get(SardineImpl.java:732)[213:org.openhab.io.caldav:1.9.0.201612300210]
at com.github.sardine.impl.SardineImpl.get(SardineImpl.java:145)[213:org.openhab.io.caldav:1.9.0.201612300210]
at org.openhab.io.caldav.internal.job.EventReloaderJob.loadEvents(EventReloaderJob.java:313)[213:org.openhab.io.caldav:1.9.0.201612300210]
at org.openhab.io.caldav.internal.job.EventReloaderJob.execute(EventReloaderJob.java:134)[213:org.openhab.io.caldav:1.9.0.201612300210]
at org.quartz.core.JobRunShell.run(JobRunShell.java:202)[102:org.eclipse.smarthome.core.scheduler:0.9.0.201612202037]
at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:573)[102:org.eclipse.smarthome.core.scheduler:0.9.0.201612202037]
My configuration is:
caldavio:Muellkalender:url=https://www.google.com/calendar/dav/<calender ID>@group.calendar.google.com/events
caldavio:Muellkalender:username=<user name>
caldavio:Muellkalender:password=<app password>
caldavio:Muellkalender:reloadInterval=1440
caldavio:Muellkalender:preloadTime=20000
caldavio:Muellkalender:disableCertificateVerification=true
I can login via browser and the download of the events.ics starts immediately.
Iām using the openhab2 snapshot 2.0.0.201612212344.
Best Regards,
Marcel
I have now further investigated the issue - unfortunately I donāt understand the problem at all. But I want to share my findings.
I have set the log level to debug in order to get more details.
2016-12-31 20:13:06.433 [DEBUG] [caldav.internal.job.EventReloaderJob] - loading resource: /calendar/dav/gpfek6vhpd2kflplhvs3qtaids@group.calendar.google.com/events/AWIDO-Gla-20170307T000000.ics (FSchangedTS not valid)
2016-12-31 20:13:06.546 [DEBUG] [.io.caldav.internal.CalDavLoaderImpl] - event is already in event map and newer -> delete the old one, reschedule timer
2016-12-31 20:13:06.547 [DEBUG] [.io.caldav.internal.CalDavLoaderImpl] - begin timer scheduled for event 'AWIDO-Gla-20170307T000000(Glas in Grünstadt@07.03.2017/00:00-08.03.2017/00:00)' @ Tue Mar 07 00:00:00 CET 2017
2016-12-31 20:13:06.547 [DEBUG] [.io.caldav.internal.CalDavLoaderImpl] - end timer scheduled for event 'AWIDO-Gla-20170307T000000(Glas in Grünstadt@07.03.2017/00:00-08.03.2017/00:00)' @ Wed Mar 08 00:00:00 CET 2017
2016-12-31 20:13:06.547 [DEBUG] [caldav.internal.job.EventReloaderJob] - loading resource: /calendar/dav/gpfek6vhpd2kflplhvs3qtaids@group.calendar.google.com/events/AWIDO-Gla-20170321T000000.ics (FSchangedTS not valid)
2016-12-31 20:13:06.717 [DEBUG] [.io.caldav.internal.CalDavLoaderImpl] - event is already in event map and newer -> delete the old one, reschedule timer
2016-12-31 20:13:06.717 [DEBUG] [.io.caldav.internal.CalDavLoaderImpl] - begin timer scheduled for event 'AWIDO-Gla-20170321T000000(Glas in Grünstadt@21.03.2017/00:00-22.03.2017/00:00)' @ Tue Mar 21 00:00:00 CET 2017
2016-12-31 20:13:06.717 [DEBUG] [.io.caldav.internal.CalDavLoaderImpl] - end timer scheduled for event 'AWIDO-Gla-20170321T000000(Glas in Grünstadt@21.03.2017/00:00-22.03.2017/00:00)' @ Wed Mar 22 00:00:00 CET 2017
2016-12-31 20:13:06.718 [DEBUG] [caldav.internal.job.EventReloaderJob] - loading resource: /calendar/dav/gpfek6vhpd2kflplhvs3qtaids@group.calendar.google.com/events/AWIDO-Pap-20171030T000000.ics (FSchangedTS not valid)
2016-12-31 20:13:06.853 [DEBUG] [.io.caldav.internal.CalDavLoaderImpl] - event is already in event map and newer -> delete the old one, reschedule timer
2016-12-31 20:13:06.853 [DEBUG] [.io.caldav.internal.CalDavLoaderImpl] - begin timer scheduled for event 'AWIDO-Pap-20171030T000000(Papier in Grünstadt@30.10.2017/00:00-31.10.2017/00:00)' @ Mon Oct 30 00:00:00 CET 2017
2016-12-31 20:13:06.853 [DEBUG] [.io.caldav.internal.CalDavLoaderImpl] - end timer scheduled for event 'AWIDO-Pap-20171030T000000(Papier in Grünstadt@30.10.2017/00:00-31.10.2017/00:00)' @ Tue Oct 31 00:00:00 CET 2017
2016-12-31 20:13:06.854 [DEBUG] [caldav.internal.job.EventReloaderJob] - loading resource: /calendar/dav/gpfek6vhpd2kflplhvs3qtaids@group.calendar.google.com/events/AWIDO-LVP-20170214T000000.ics (FSchangedTS not valid)
2016-12-31 20:13:07.055 [DEBUG] [.io.caldav.internal.CalDavLoaderImpl] - event is already in event map and newer -> delete the old one, reschedule timer
2016-12-31 20:13:07.055 [DEBUG] [.io.caldav.internal.CalDavLoaderImpl] - begin timer scheduled for event 'AWIDO-LVP-20170214T000000(Gelber Sack in Grünstadt@14.02.2017/00:00-15.02.2017/00:00)' @ Tue Feb 14 00:00:00 CET 2017
2016-12-31 20:13:07.056 [DEBUG] [.io.caldav.internal.CalDavLoaderImpl] - end timer scheduled for event 'AWIDO-LVP-20170214T000000(Gelber Sack in Grünstadt@14.02.2017/00:00-15.02.2017/00:00)' @ Wed Feb 15 00:00:00 CET 2017
2016-12-31 20:13:07.056 [DEBUG] [caldav.internal.job.EventReloaderJob] - loading resource: /calendar/dav/gpfek6vhpd2kflplhvs3qtaids@group.calendar.google.com/events/AWIDO-RM-20170103T000000.ics (FSchangedTS not valid)
2016-12-31 20:13:07.168 [ERROR] [caldav.internal.job.EventReloaderJob] - error reading ics file: AWIDO-RM-20170103T000000
com.github.sardine.impl.SardineException: Unexpected response (401 Unauthorized)
at com.github.sardine.impl.handler.ValidatingResponseHandler.validateResponse(ValidatingResponseHandler.java:48)[223:org.openhab.io.caldav:1.9.0.201612300210]
at com.github.sardine.impl.handler.VoidResponseHandler.handleResponse(VoidResponseHandler.java:34)[223:org.openhab.io.caldav:1.9.0.201612300210]
at com.github.sardine.impl.SardineImpl.get(SardineImpl.java:756)[223:org.openhab.io.caldav:1.9.0.201612300210]
at com.github.sardine.impl.SardineImpl.get(SardineImpl.java:741)[223:org.openhab.io.caldav:1.9.0.201612300210]
at com.github.sardine.impl.SardineImpl.get(SardineImpl.java:732)[223:org.openhab.io.caldav:1.9.0.201612300210]
at com.github.sardine.impl.SardineImpl.get(SardineImpl.java:145)[223:org.openhab.io.caldav:1.9.0.201612300210]
at org.openhab.io.caldav.internal.job.EventReloaderJob.loadEvents(EventReloaderJob.java:313)[223:org.openhab.io.caldav:1.9.0.201612300210]
at org.openhab.io.caldav.internal.job.EventReloaderJob.execute(EventReloaderJob.java:134)[223:org.openhab.io.caldav:1.9.0.201612300210]
at org.quartz.core.JobRunShell.run(JobRunShell.java:202)[102:org.eclipse.smarthome.core.scheduler:0.9.0.201612221226]
at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:573)[102:org.eclipse.smarthome.core.scheduler:0.9.0.201612221226]
2016-12-31 20:13:07.168 [DEBUG] [caldav.internal.job.EventReloaderJob] - loading resource: /calendar/dav/gpfek6vhpd2kflplhvs3qtaids@group.calendar.google.com/events/AWIDO-RM-20170411T000000.ics (FSchangedTS not valid)
2016-12-31 20:13:07.249 [ERROR] [caldav.internal.job.EventReloaderJob] - error reading ics file: AWIDO-RM-20170411T000000
com.github.sardine.impl.SardineException: Unexpected response (401 Unauthorized)
at com.github.sardine.impl.handler.ValidatingResponseHandler.validateResponse(ValidatingResponseHandler.java:48)[223:org.openhab.io.caldav:1.9.0.201612300210]
at com.github.sardine.impl.handler.VoidResponseHandler.handleResponse(VoidResponseHandler.java:34)[223:org.openhab.io.caldav:1.9.0.201612300210]
at com.github.sardine.impl.SardineImpl.get(SardineImpl.java:756)[223:org.openhab.io.caldav:1.9.0.201612300210]
at com.github.sardine.impl.SardineImpl.get(SardineImpl.java:741)[223:org.openhab.io.caldav:1.9.0.201612300210]
at com.github.sardine.impl.SardineImpl.get(SardineImpl.java:732)[223:org.openhab.io.caldav:1.9.0.201612300210]
at com.github.sardine.impl.SardineImpl.get(SardineImpl.java:145)[223:org.openhab.io.caldav:1.9.0.201612300210]
at org.openhab.io.caldav.internal.job.EventReloaderJob.loadEvents(EventReloaderJob.java:313)[223:org.openhab.io.caldav:1.9.0.201612300210]
at org.openhab.io.caldav.internal.job.EventReloaderJob.execute(EventReloaderJob.java:134)[223:org.openhab.io.caldav:1.9.0.201612300210]
at org.quartz.core.JobRunShell.run(JobRunShell.java:202)[102:org.eclipse.smarthome.core.scheduler:0.9.0.201612221226]
at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:573)[102:org.eclipse.smarthome.core.scheduler:0.9.0.201612221226]
2016-12-31 20:13:07.250 [DEBUG] [caldav.internal.job.EventReloaderJob] - loading resource: /calendar/dav/gpfek6vhpd2kflplhvs3qtaids@group.calendar.google.com/events/AWIDO-Gla-20171128T000000.ics (FSchangedTS not valid)
2016-12-31 20:13:07.326 [ERROR] [caldav.internal.job.EventReloaderJob] - error reading ics file: AWIDO-Gla-20171128T000000
com.github.sardine.impl.SardineException: Unexpected response (401 Unauthorized)
at com.github.sardine.impl.handler.ValidatingResponseHandler.validateResponse(ValidatingResponseHandler.java:48)[223:org.openhab.io.caldav:1.9.0.201612300210]
at com.github.sardine.impl.handler.VoidResponseHandler.handleResponse(VoidResponseHandler.java:34)[223:org.openhab.io.caldav:1.9.0.201612300210]
at com.github.sardine.impl.SardineImpl.get(SardineImpl.java:756)[223:org.openhab.io.caldav:1.9.0.201612300210]
at com.github.sardine.impl.SardineImpl.get(SardineImpl.java:741)[223:org.openhab.io.caldav:1.9.0.201612300210]
at com.github.sardine.impl.SardineImpl.get(SardineImpl.java:732)[223:org.openhab.io.caldav:1.9.0.201612300210]
at com.github.sardine.impl.SardineImpl.get(SardineImpl.java:145)[223:org.openhab.io.caldav:1.9.0.201612300210]
at org.openhab.io.caldav.internal.job.EventReloaderJob.loadEvents(EventReloaderJob.java:313)[223:org.openhab.io.caldav:1.9.0.201612300210]
at org.openhab.io.caldav.internal.job.EventReloaderJob.execute(EventReloaderJob.java:134)[223:org.openhab.io.caldav:1.9.0.201612300210]
at org.quartz.core.JobRunShell.run(JobRunShell.java:202)[102:org.eclipse.smarthome.core.scheduler:0.9.0.201612221226]
at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:573)[102:org.eclipse.smarthome.core.scheduler:0.9.0.201612221226]
This looks for me that sometimes the access works and sometimes not.
I have also checked the caldav directory in /var/lib/openhab2/etc/caldav/Muellkalender and there I can find a bunch of *.ics files that are updated frequently.
I have also tried to download a ics file that can not be accessed according to the log. However, this is possible with the browser.
For now I will uninstall the extension. Please let me know if I can investigate something else in order to support you experts.
Best Reagrds,
Marcel
I am not using the google calendar. Are there any special chars in the urls, for which the download is not working in oh?
I have checked an event which cause an error in the log. The URL seems ok for me
https://www.google.com/calendar/dav/<calendar id>@group.calendar.google.com/events/AWIDO-RM-20170103T000000.ics
I have downloaded it in the browser and also checked the content of the file.
I donāt see anything strange here.
Hello @querdenker2k !
Iām trying to use Caldav binding with Google calendar, but, whatever Iāve tried, Iām always getting same error message in the openhab.log - url must be set.
This is that part of the log file:
2017-01-13 15:21:16.884 [ERROR] [org.apache.felix.configadmin ] - [org.osgi.service.cm.ManagedService, org.openhab.io.caldav.CalDavLoader, id=119, bundle=218/mvn:org.openhab.io/org.openhab.io.caldav/1.9.0-SNAPSHOT]: Updating property url of configuration org.openhab.caldavio caused a problem: url must be set
org.osgi.service.cm.ConfigurationException: url : url must be set
at org.openhab.io.caldav.internal.CalDavLoaderImpl.updated(CalDavLoaderImpl.java:207)[218:org.openhab.io.caldav:1.9.0.201701130210]
at org.apache.felix.cm.impl.helper.ManagedServiceTracker.updated(ManagedServiceTracker.java:189)[3:org.apache.felix.configadmin:1.8.12]
at org.apache.felix.cm.impl.helper.ManagedServiceTracker.updateService(ManagedServiceTracker.java:152)[3:org.apache.felix.configadmin:1.8.12]
at org.apache.felix.cm.impl.helper.ManagedServiceTracker.provideConfiguration(ManagedServiceTracker.java:85)[3:org.apache.felix.configadmin:1.8.12]
at org.apache.felix.cm.impl.ConfigurationManager$ManagedServiceUpdate.provide(ConfigurationManager.java:1461)[3:org.apache.felix.configadmin:1.8.12]
at org.apache.felix.cm.impl.ConfigurationManager$ManagedServiceUpdate.run(ConfigurationManager.java:1417)[3:org.apache.felix.configadmin:1.8.12]
at org.apache.felix.cm.impl.UpdateThread.run0(UpdateThread.java:141)[3:org.apache.felix.configadmin:1.8.12]
at org.apache.felix.cm.impl.UpdateThread.run(UpdateThread.java:109)[3:org.apache.felix.configadmin:1.8.12]
at java.lang.Thread.run(Unknown Source)[:1.8.0_111]
Iām using OpenHAB 2.0 nighly and Iāve installed Caldav-personal via Paper UI. Iāve tried using both, old and new URL format, setting OAuth to true in caldavio.cfg, used both, e-mail address as the calendar name and specific calendar ID from Google calendar setting, but every time Iām getting this error. Any help would be greatly appreciated.
Best regards,
Davor
Have you typed the prefix of the binding in the config file:
caldavio:
Hello!
Yes I did, caldavio: in caldavio.cfg and caldavPersonal: in caldav personal.cfg
Best regards,
Davor
Hello!
I forgot to mention that Iāve created OAuth client credentials and even allowed less secure clients to connect to my Google account.
Best regards,
Davor
Von you post the caldavio config?
Hello @querdenker2k
These are some of the configs Iāve tried, but were not working:
caldavio:home:url=https://apidata.googleusercontent.com/caldav/v2/xxxxxxxx@group.calendar.google.com/events
caldavio:home:oauth=true
caldavio:home:username=Client ID from google OAuth API
caldavio:home:password=Client secret from google OAuth API
caldavio:home:reloadInterval=10
caldavio:home:preloadTime=7200
caldavio:home:disableCertificateVerification=true
This is the second format of the configuration Iāve tried:
caldavio:home:url=https://www.google.com/calendar/dav/xxxxxxxx@group.calendar.google.com/events
caldavio:home:username=my e-mail username part (part before @)
caldavio:home:password=my e-mail password
caldavio:home:reloadInterval=10
caldavio:home:preloadTime=7200
caldavio:home:disableCertificateVerification=true
xxxxxxxx is Calendar ID from the specific calendar settings in Google Calendar web interface.
Iāve tried both settings with and without caldavio:home:disableCertificateVerification=true
part. Iāve also tried using my e-mail address (email@gmail.com) instead of xxxxxxxx@group.calendar.google.com, so it would use my default calendar, but with the same result.
Best regards,
Davor
Hello @querdenker2k
Do you think my config file is OK? Iāve tried everything I could think of, but Iām still unable to make it work. Thank you for your help.
Best regards,
Davor
The config file looks good, but i am currently Not using the caldav Binding. Ist does not really work with beta5
Hello!
So, it could be problem with a snapshot Iām using (itās pretty recent, so, I guess it could be the same problem beta 5 has)? Anyway, thank you for your help.
Best regards,
Davor
Hello @querdenker2k
Are you the maintainer of CalDAV binding? Do you know if there are any plans on fixing it?
Best regards,
Davor