It seems there is a comparison issue with the variable nextEvent, however, the variable content appears like a date (Wed Dec 27 12:00:00 2023). I don't know about LUA scripts, but I can give some useful information from the debug.Reader.lua attempt to compare nil with number
It is currently May 9th, 2024, 10:20 pm
Enigma Google Calendar LUA script issue
-
- Posts: 14
- Joined: January 26th, 2020, 3:02 pm
- Location: France
Enigma Google Calendar LUA script issue
Hello everybody, I use the Google Calendar skin with the adapted LUA script updated on the 2023-06-21. Since a few days, the script return on the line 1,235 (for my script) the error:
-
- Rainmeter Sage
- Posts: 7212
- Joined: February 27th, 2015, 2:38 pm
- Location: Terra Yincognita
Re: Enigma Google Calendar LUA script issue
I think you might want to ask this in that skin's thread, to the guys that wrote the script, as they are in the best position to advise, being familiar with how it works and all:Jean-Michel wrote: ↑December 31st, 2023, 8:50 am Hello everybody, I use the Google Calendar skin with the adapted LUA script updated on the 2023-06-21. Since a few days, the script return on the line 1,235 (for my script) the error:
It seems there is a comparison issue with the variable nextEvent, however, the variable content appears like a date (Wed Dec 27 12:00:00 2023). I don't know about LUA scripts, but I can give some useful information from the debug.
https://forum.rainmeter.net/viewtopic.php?t=27623&start=100
In any case, generally the error you mentioned ("attempt to compare nil with number") is because one of the variables in the comparison on that line isn't initialized with a value or doesn't exist. Either an edge case in the script, or something that isn't retrieved properly by it or the related code. You might be able to do some limited debugging on this, by inserting some print(ComparisonVariable1, ComparisonVariable2); just before the comparison and watch the log for their values, then further trace how the problematic variable is changed or initialized in a similar fashion for earlier execution stages. At least you may find where exactly in the script is the cause of the issue (i.e. where the variable "should" be provided with a value and it's not)...
-
- Posts: 14
- Joined: January 26th, 2020, 3:02 pm
- Location: France
Re: Enigma Google Calendar LUA script issue
@Yincognito Hello and thank you for the link. I knew that a thread was already open, but I don't found it. I will insert a print() function on the line where the issue is. New post is here.Yincognito wrote: ↑December 31st, 2023, 1:07 pm I think you might want to ask this in that skin's thread, to the guys that wrote the script, as they are in the best position to advise, being familiar with how it works and all:
https://forum.rainmeter.net/viewtopic.php?t=27623&start=100
In any case, generally the error you mentioned ("attempt to compare nil with number") is because one of the variables in the comparison on that line isn't initialized with a value or doesn't exist. Either an edge case in the script, or something that isn't retrieved properly by it or the related code. You might be able to do some limited debugging on this, by inserting some print(ComparisonVariable1, ComparisonVariable2); just before the comparison and watch the log for their values, then further trace how the problematic variable is changed or initialized in a similar fashion for earlier execution stages. At least you may find where exactly in the script is the cause of the issue (i.e. where the variable "should" be provided with a value and it's not)...
-
- Rainmeter Sage
- Posts: 7212
- Joined: February 27th, 2015, 2:38 pm
- Location: Terra Yincognita
Re: Enigma Google Calendar LUA script issue
Excellent! Hopefully you won't have to wait too long until someone there comes up with some instructions to solve the issue.Jean-Michel wrote: ↑December 31st, 2023, 3:29 pm @Yincognito Hello and thank you for the link. I knew that a thread was already open, but I don't found it. I will insert a print() function on the line where the issue is. New post is here.