Skip to content

Unsolicited ATTACHED on detached channel re-enters attached instead of sending DETACH (RTL5k) #2207

@paddybyers

Description

@paddybyers

Spec requirement

RTL5k: If the channel receives an ATTACHED message while in the DETACHED state, it should send a new DETACH message to the server.

Current behaviour

ably-js re-enters the attached state instead of sending DETACH when an unsolicited ATTACHED is received while the channel is detached.

Reproduction

RUN_DEVIATIONS=1 npx mocha --no-config --require tsx/cjs 'test/uts/realtime/channels/channel_detach.test.ts' --timeout 30000 --grep "RTL5k - ATTACHED while detached sends DETACH"

UTS test

test/uts/realtime/channels/channel_detach.test.ts — asserts detachMessageCount == 2 and channel.state == 'detached'.

┆Issue is synchronized with this Jira Task by Unito

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working. It's clear that this does need to be fixed.uts-issueIssues raised there there is an apparent discrepancy between this library and the UTS tests

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions