Open michaeljguarino opened 4 years ago
hey! I think i have the same issue. I'm using "@absinthe/socket": { "version": "0.2.1" }
I'm following the approach described on the documentation: creating an Observable, calling subscribe
on it and afterwards calling unsubscribe
on the subscription it returns.
I'm doing this on some tests on Jest and unsubscribing on the afterAll
callback, but in the end Jest keeps complaining with: Jest did not exit one second after the test run has completed
and it keeps running, which leds me think the connection wasn't closed correctly
Hello, Does anyone have a solution to this? Apparently, the issue was also discussed here, but the solution did not work for me.
I've been debugging some issues in one of my apps, and drilled down to the most likely cause being apollo subscription cancels not flushing to the absinthe socket. To reproduce, I simply called a subscribeToMore for one of my queries and immediately called the cancel callback function after, and observed no unsubscribe event pushed to the socket.
I'm using a newer version of apollo, so this might be a regression (and i seem to remember seeing this working with older versions of apollo's react client). Here are the versions: