Skip to content
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

subscribeBlocks and subscribeMempool don't work after 9 hours #2173

Closed
dhwndud408 opened this issue Nov 20, 2024 · 1 comment
Closed

subscribeBlocks and subscribeMempool don't work after 9 hours #2173

dhwndud408 opened this issue Nov 20, 2024 · 1 comment

Comments

@dhwndud408
Copy link

Hi! dev teams.

I am making code with your api.
Here is my computer info.
Mac OS Sonoma14.4
Node 18.19.1
NPM 10.2.4
API version: 8.2.0

Here is the typescript code

import * as stacks from '@stacks/blockchain-api-client';
const socketUrl = "https://api.mainnet.hiro.so";
const socket = new stacks.StacksApiSocketClient({ url: socketUrl });

let client = await stacks.connectWebSocketClient('wss://api.mainnet.hiro.so/');


sub = await socket.subscribeBlocks((event) => {
   console.log(event)
}
sub = await socket.subscribeBlocks((event) => {
console.log(event)
}

After about 6~9 hours, the websocket stops.

I also see the this report.
#1885

The admin said it was resolved on above link, but it seems the issue has resurfaced with the Nakamoto update.

@zone117x
Copy link
Member

Closing as a duplicate of #2146

@github-project-automation github-project-automation bot moved this from 🆕 New to ✅ Done in API Board Nov 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

No branches or pull requests

2 participants