This repository was archived by the owner on Oct 22, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 4 files changed +44
-27
lines changed Expand file tree Collapse file tree 4 files changed +44
-27
lines changed Original file line number Diff line number Diff line change 167167 "on-change" : " ^5.0.1" ,
168168 "p-retry" : " ^6.2.1" ,
169169 "zod" : " ^3.25.76" ,
170- "@rivetkit/engine-runner" : " https://pkg.pr.new/rivet-gg/engine/@rivetkit/engine-runner@f8860f3 "
170+ "@rivetkit/engine-runner" : " https://pkg.pr.new/rivet-gg/engine/@rivetkit/engine-runner@4b0f765 "
171171 },
172172 "devDependencies" : {
173173 "@hono/node-server" : " ^1.18.2" ,
Original file line number Diff line number Diff line change @@ -31,7 +31,6 @@ import {
3131 handleRawWebSocketHandler ,
3232 handleWebSocketConnect ,
3333 lookupInRegistry ,
34- noopNext ,
3534 PATH_CONNECT_WEBSOCKET ,
3635 PATH_RAW_WEBSOCKET_PREFIX ,
3736} from "@/mod" ;
@@ -85,7 +84,15 @@ export class EngineActorDriver implements ActorDriver {
8584 totalSlots : config . totalSlots ,
8685 runnerName : config . runnerName ,
8786 runnerKey : config . runnerKey ,
88- prepopulateActorNames : Object . keys ( this . #registryConfig. use ) ,
87+ metadata : {
88+ inspectorToken : this . #runConfig. studio . token ( ) ,
89+ } ,
90+ prepopulateActorNames : Object . fromEntries (
91+ Object . keys ( this . #registryConfig. use ) . map ( ( name ) => [
92+ name ,
93+ { metadata : { } } ,
94+ ] ) ,
95+ ) ,
8996 onConnected : ( ) => {
9097 if ( hasDisconnected ) {
9198 logger ( ) . info ( "runner reconnected" , {
Original file line number Diff line number Diff line change 11import * as cbor from "cbor-x" ;
22import type { Context as HonoContext } from "hono" ;
3- import type { WSContext } from "hono/ws" ;
43import invariant from "invariant" ;
5- import { ActorAlreadyExists , InternalError } from "@/actor/errors" ;
4+ import { ActorAlreadyExists } from "@/actor/errors" ;
65import {
76 HEADER_AUTH_DATA ,
87 HEADER_CONN_PARAMS ,
98 HEADER_ENCODING ,
109 HEADER_EXPOSE_INTERNAL_ERROR ,
1110} from "@/actor/router-endpoints" ;
11+ import { generateRandomString } from "@/actor/utils" ;
1212import { importWebSocket } from "@/common/websocket" ;
1313import type {
1414 ActorOutput ,
@@ -40,6 +40,10 @@ export class EngineManagerDriver implements ManagerDriver {
4040 constructor ( config : Config , runConfig : RunConfig ) {
4141 this . #config = config ;
4242 this . #runConfig = runConfig ;
43+ if ( ! this . #runConfig. studio . token ( ) ) {
44+ const token = generateRandomString ( ) ;
45+ this . #runConfig. studio . token = ( ) => token ;
46+ }
4347 this . #importWebSocketPromise = importWebSocket ( ) ;
4448 }
4549
You can’t perform that action at this time.
0 commit comments