-
Notifications
You must be signed in to change notification settings - Fork 13
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
Realtime Events not respecting options #27
Comments
Thanks for the report @Kuffs2205 - As this library is modeled off of |
Thanks for taking a look. I'm never quite sure if it's just me with a poor understanding or not. |
Looks like this is a limitation known by the team at realtime - filters on delete events are currently unsupported. I'm going to keep this open to track it! (See the referenced issue) |
So filters do not work at all then as PostgresChangesOptions.ListenType.Updates still gives me Inserts and Deletes too. This is not sustainable. Literally millions of messages being sent and charged that I do not want and my user base is not yet that big. Hope they sort it soon or at least document it better so people don't fall into the trap of paying for unwanted messages. |
@Kuffs2205 unfortunately I'm just a volunteer library maintainer - but I absolutely agree with you. Maybe consider reaching out to supabase support about considering your account status and being charged for extra, unwanted events? |
I wasn't suggesting you were at fault at all. Sorry if it seemed so. |
No worries - just wanted to offer a course of action in the meantime! |
Can I just clarify something as it seems that all the focus was the "eq" filter not working for deletes but there was another issue in that: PostgresChangesOptions.ListenType.Updates was also not being respected and all events were being returned regardless of what was asked for Is this related or a separate issue? |
🤦 I got caught up in the filter thing that I forgot to check the second part of your issue! Let me get back to you on that. |
Okay, so I can confirm that there is a bug in the library's code. It is sending a request to subscribe to all events instead of respecting the options - so good catch there - I'll issue a quick fix for that - Thank you!! However, I can also duplicate the same issue on the javascript library, where a SO! You are correct. The library is not respecting the options (fix coming momentarily). But the websocket server sends events regardless (upstream issue that I also need to make another issue for)! |
Thanks for checking that out. I really appreciate your efforts on this library. I wouldn't be using Supabase without it. |
In my options, I am listening only for Updates.
However, I am also receiving Inserts and Deletes.
Also, the Delete messages received do not correlate to my filter. Every single client gets every single delete even when the delete is for a different parentID.
Reproduction Steps
Click "Insert Subscribed Row" - The Insert event is fired Incorrect as I'm listening only for updates
Click "Insert Random Row" - No event fired Correct
In Supabase studio.
Edit one of the random rows (X=1,Y=1) No event fired Correct
Edit one of the subscribed rows (X=99,Y=99) Update Event fired Correct
Delete one of the subscribed rows Delete Event Fired Incorrect as I'm not listening for deletes
Delete one of the random rows Delete Event Fired Incorrect as I'm not listening for deletes AND I'm not subscribed to those records
https://github.com/Kuffs2205/TestRealtime.git
I'm up to 10,000,000 messages this month. I queried this as it seemed excessive. Now I see the Delete issue, it makes sense.
I wasn't sure if I should post the url and key publicly so I didn't but I can give it you if you want it.
The text was updated successfully, but these errors were encountered: