issork / gift

Godot IRC For Twitch addon
MIT License
150 stars 23 forks source link

Invalid type in function 'connect_to_eventsub' in base 'Node ()'. Cannot convert argument 1 from Nil to String. #19

Closed FromCollin closed 1 year ago

FromCollin commented 1 year ago

I am getting some odd errors after previously it was all working great.

Invalid type in function 'connect_to_eventsub' in base 'Node ()'. Cannot convert argument 1 from Nil to String.

I am using godot 4.0 RC6, previous versions seemed to work so I suspect something was broken in the update. I am also using Linux which doesn't default to 127.0.0.1 with localhost either.

issork commented 1 year ago

Does this happen immediately or only after letting it run for a while? I'm suspecting that the reconnect URL isn't being set properly when Twitch demands a reconnect to a different URL.

FromCollin commented 1 year ago

Hey, thanks for the quick reply - this happens after a bit, not immediately. It seems to successfully connect but then stalls out when an event happens (moobot joins in this instance or trying to send a message) i'm using the default setup you've included just to make sure it's all working before tweaking anything.

issork commented 1 year ago

What version are you using exactly? This issue should've already been fixed by the changes I made to fix #18.

I've not been able to reproduce this issue so far in the latest version.

FromCollin commented 1 year ago

The fault appears to be mine, I was using an old version. My fault there. I loaded it fresh and I can send messages and receive them. It's working save for one print statement failing and saying: Invalid get index 'data' (on base: 'Dictionary'). On line 454 in the gift_node.gd file. If I comment it out, the rest of the code appears to work.

issork commented 1 year ago

Oh yes, that's because Twitch changed the API of the channel.follow event, will update that on the coming weekend, thanks!