We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent d44d6ca commit 9c279a6Copy full SHA for 9c279a6
1 file changed
agent-manager/src/AgentConnection.js
@@ -134,6 +134,11 @@ export class AgentConnection {
134
135
this.ws.onmessage = (event) => {
136
try {
137
+ // Skip binary messages (like position updates from Hyperfy)
138
+ if (typeof event.data !== 'string') {
139
+ return;
140
+ }
141
+
142
const data = JSON.parse(event.data);
143
144
// Handle chat messages
@@ -150,7 +155,10 @@ export class AgentConnection {
150
155
151
156
// Optional: handle other message types (position updates, etc.)
152
157
} catch (err) {
153
- console.error('Invalid WS message:', err);
158
+ // Only log if it was a string message that failed to parse
159
+ if (typeof event.data === 'string') {
160
+ console.error('Invalid WS message:', err.message);
161
154
162
}
163
};
164
0 commit comments