You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Auto-generated by AI — This issue was automatically created by an AI-based SDK parity analysis tool. It may not be applicable to this SDK or may already be implemented in a different form. Please use your best judgment before accepting or closing this issue.
SDK Parity: C# implementation needed
A change was made in supabase-js that needs to be implemented in this repository for SDK parity.
Previously only presence callbacks were blocked after channel join. Now postgres_changes listeners also throw an error if added after the channel has joined or is in the process of joining.
Code Reference
// Before: only presence was blockedif(this.channelAdapter.isJoined()&&type===REALTIME_LISTEN_TYPES.PRESENCE){thrownewError('cannot add presence callbacks after joining a channel')}// After: both presence AND postgres_changes are blockedconststateCheck=this.channelAdapter.isJoined()||this.channelAdapter.isJoining()if(stateCheck&&(type===REALTIME_LISTEN_TYPES.PRESENCE||type===REALTIME_LISTEN_TYPES.POSTGRES_CHANGES)){thrownewError(`cannot add ${type} callbacks after joining a channel`)}
Implementation Guidance
Expected Behavior (C#)
// Should throw when channel is already subscribedchannel.Register(newPostgresChangesOptions{...});// throws if already subscribed
Key Behaviors to Match
Throws when trying to register PostgresChanges listener after channel joined
Also blocks during "subscribing" state (not just subscribed)
Clear error message indicating the constraint
Presence behavior unchanged (already blocked in most implementations)
Acceptance Criteria
Register(PostgresChangesOptions) throws after channel subscribe
Also throws during subscribing state
Clear InvalidOperationException (or similar) with helpful message
Unit test covering post-subscribe listener registration
No breaking change for properly-ordered usage
Context
supabase-js version: v2.101.0
Parity tracking: This issue was auto-generated by SDK parity analysis
Activity
Tr00d commentedon Sep 10, 2026
Fixed with #385