-
-
Notifications
You must be signed in to change notification settings - Fork 12
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
[QUESTION]: Fetch ical events of other users calendar. #133
Comments
As a new version 2.2.1 has been published recently, I decided to look further into this node, As mentioned before my own calendar is working, but my wife's calendar is not
As it has worked before, I decided to install a previous version. As I have no idea in which version this issue has been introduced I decided to install the latest 1.xx version, so that was 1.5.3. The first strange thing I noted, if I tried to connect to my CalDav server with ical configuration that the server returned a 401 "Unauthorized". There is no option to configure username/password. If you change the Type in the Config node from ical to CalDav, you will see two configuration fields for Username, resp. Password. Afterwards you have to change the Type back to ical. And then it works, both for myself and for the calendar of my wife. So beside a somewhat strange way of configuration for username/password it works. [Edit] I tested also version 2.0.2. and it failed with the same error. So obviously version 1.5.3. is working fine and updating to version 2.x.x. introduce this issue. I think this is a bug! |
Sorry for being away such a long time... Work/Life Balance 😉 The username/password will be available again, with v2.2.2. Give me some days to release a new version ... |
Hi, Any news, when a new release will be published? Regards |
Hello @naimo84, As the new version 2.2.2. has been released yesterday, I decided to give it a try.
It looks that the node is not able to log in. Any idea of a possible reason? Any idea? Regards |
Hey, can you provide me some flow details, perhaps? You can send it privately via Mail, of course. Thanks and greets |
Hello @naimo84, Benjamin My apologies for my very late response. I missed your message completely, as I have been on holiday during that period and I had completely forgotten this issue, after my return home. As you might know my application is running fine with version 1.5.3 (the latest of version 1)After testing with version 2 it start failing, so I still use 1.5.3. When I noticed that version 2.2.5 has been published, I decided to test that version. The flow is extremely simple. An Inject node, followed by the Ical node and followed by the Debug node. I use a "Zarafa" server, running on "ClearOS". So no external mailbox, but running in my local LAN However, instead of port 8080, I use 8008., but for the rest I use these URL's If I select "Caldav", I get an authorization error, both for myself and my wife (code 401) Remarkable is, that, if I copy and paste the URL in a browser, the username and password is requested and then an ics file with the correct data is downloaded. I can send you more information as a PM, such as the data in the ics, screenshots of the config or the flow itself. Regards Herman |
Hey Herman, the flow seems to be quite simple, as you said 😁 my email is: [email protected] Thanks for your support. Greets, |
Hello @naimo84, Benjamin. I'll send you a PM. Regards, Herman |
Hello Herman, @FireWizard52 I found the error in your ics files. Thanks for providing. 👍 It has something to do with timezone offsets. DTSTART;TZID=Africa/Tunis:20210723T150000 is working. https://github.com/jkbrzt/rrule#timezone-support I will try to convert "(GMT +01:00)" to any iana timezone, but currently I've no idea, if this has any other side effects ^^ |
Hello Benjamin, @naimo84 Thank you very much for your prompt response. It's good you found something. I have looked to the settings in Zarafa, but I do not see any options to reconfigure timezone formats. What I do not understand, is that I can fetch my calendar en I cannot fetch the calendar of my wife. As far as I can see they use the same timezone format. At least, if I use Ical. If I use Caldav with both, I get the authorization error 401. What I also do not understand, is that everything is working with version 1.5.3 (the latest version 1), but that version 2 is failing. Looking forward to a solution. Regards Herman |
One solution that comes to my mind: a settings in the config dialog where we can override the Timezone from the ics data?
This is because your ics data doesn't contain a (GMT +01:00), your wife's does 😉
The big difference is, that with 1.5.3 I used an old version of the node-ical lib from jens-maus, and with v2 I tried to implement the ical-parsing code from jens lib on my own. Most of the Code is cheeky stolen from his latest version at that time 😉 In the old version, the timezone was not computed: https://github.com/jens-maus/node-ical/blob/3ce830dd86104a7ccc8d880b629c5e9dbce0b60c/ical.js#L382 With the latest version it is: https://github.com/jens-maus/node-ical/blob/master/ical.js#L589 I'm sure I have to compute the timezone, otherwise many other flows will fail, because of an offset. |
Hi Benjamin, @naimo84 I have no clue why the timezone is different between mine and my wife's calendar.
I don't think that it is necessary to guess the time zone, because in the field Dateformat the timezone is already set. Regards Herman |
Hi
Node-RED version v 2.2.2
Ical Node version 2.2.0
I use this node to fetch my own calendar and, with another ical node my wife's calender.
Fetching my own calendar works without any issues, but with exactly the same setting it is not possible to get my wife's calendar.
The node responds with
"Error: ERROR when trying to convert to ISOStringTypeError: Cannot read property 'match' of null"
As it is not possible, that if you have as calendar type "ical", to set the right username/password I did this include in the URL, as follows: http://username:password@IP address:portnumber/ical. It does not matter whether I put the username/password in front of the IP address or not, my own is working and my wife's calendar not.
Logging in in a browser or http request node works fine this way and gives the data.
It has worked before, so it should have changed during an update of either NR or the node.
Setting the calendar type as Caldav with the correct settings does not function either and therefore I use ical.
Using Caldav gives in both cases:
"caldav - get calendar went wrong. Error Message: Error: Response with status code: 401"
Any idea, why
Regards
The text was updated successfully, but these errors were encountered: