-
Notifications
You must be signed in to change notification settings - Fork 39
chore(example-raw-websocket-handler-proxy): use correct url and mount registry #1149
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
base: main
Are you sure you want to change the base?
chore(example-raw-websocket-handler-proxy): use correct url and mount registry #1149
Conversation
Claude encountered an error —— View job I'll analyze this and get back to you. |
How to use the Graphite Merge QueueAdd either label to this PR to merge it via the merge queue:
You must have a Graphite account in order to use the merge queue. Sign up using this link. An organization admin has enabled the Graphite Merge Queue in this repository. Please do not merge from GitHub as this will restart CI on PRs being processed by the merge queue. This stack of pull requests is managed by Graphite. Learn more about stacking. |
@rivetkit/actor
@rivetkit/core
@rivetkit/db
rivetkit
@rivetkit/cloudflare-workers
@rivetkit/redis
@rivetkit/framework-base
@rivetkit/react
commit: |
0a9bfea
to
093eef4
Compare
Claude encountered an error —— View job I'll analyze this and get back to you. |
const { client, hono } = registry.createServer({ | ||
getUpgradeWebSocket: () => upgradeWebSocket, | ||
}); | ||
|
||
const app = new Hono(); | ||
const { injectWebSocket, upgradeWebSocket } = createNodeWebSocket({ app }); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There appears to be a circular dependency in this code. The upgradeWebSocket
function is being passed to registry.createServer()
before it's actually defined on line 11.
To resolve this issue, please move the registry creation code:
const { client, hono } = registry.createServer({
getUpgradeWebSocket: () => upgradeWebSocket,
});
to after line 11 where upgradeWebSocket
is defined. This will ensure the function exists before it's referenced.
const { client, hono } = registry.createServer({ | |
getUpgradeWebSocket: () => upgradeWebSocket, | |
}); | |
const app = new Hono(); | |
const { injectWebSocket, upgradeWebSocket } = createNodeWebSocket({ app }); | |
const app = new Hono(); | |
const { injectWebSocket, upgradeWebSocket } = createNodeWebSocket({ app }); | |
const { client, hono } = registry.createServer({ | |
getUpgradeWebSocket: () => upgradeWebSocket, | |
}); | |
Spotted by Diamond
Is this helpful? React 👍 or 👎 to let us know.
No description provided.