@homie-rocks/studio 0.58.4 → 0.58.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +16 -0
- package/lib/template-history.json +42 -0
- package/package.json +1 -1
- package/worker/app-streams.mjs +3 -1
- package/worker/build-id.mjs +1 -1
- package/worker/office.mjs +3 -2
- package/worker/version.mjs +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -17,6 +17,22 @@ To bring a studio up to date, tell Claude: "Upgrade my studio to the newest Homi
|
|
|
17
17
|
`npx -y @homie-rocks/studio@latest upgrade`, which shows what's new since the version your studio pins (from this
|
|
18
18
|
file) and what the upgrade would change, and changes nothing until you agree.
|
|
19
19
|
|
|
20
|
+
## [0.58.5] - 2026-10-18
|
|
21
|
+
|
|
22
|
+
**Plugin 0.58.2**
|
|
23
|
+
|
|
24
|
+
A signed-in app gets its live socket. Leaving that page open no longer wakes the records object.
|
|
25
|
+
|
|
26
|
+
### Fixed
|
|
27
|
+
|
|
28
|
+
- The live upgrade is returned as the records object sent it. Writing the role cookie onto that response threw, so the browser never received the socket and tried again about every two minutes.
|
|
29
|
+
- When the stored role cookie no longer works, the socket closes and the page opens a new one with the cookie it renewed. The page does not give up.
|
|
30
|
+
- Someone who opens the app is counted with the people whose sockets are already asleep.
|
|
31
|
+
|
|
32
|
+
### Upgrade notes
|
|
33
|
+
|
|
34
|
+
- Upgrade the studio to pick this up.
|
|
35
|
+
|
|
20
36
|
## [0.58.4] - 2026-10-18
|
|
21
37
|
|
|
22
38
|
**Plugin 0.58.2**
|
|
@@ -4344,6 +4344,48 @@
|
|
|
4344
4344
|
}
|
|
4345
4345
|
}
|
|
4346
4346
|
}
|
|
4347
|
+
},
|
|
4348
|
+
"0.58.5": {
|
|
4349
|
+
"files": {
|
|
4350
|
+
"CLAUDE.md": "ddf2b2a0376202f6",
|
|
4351
|
+
"README.md": "684b3cca8001673c",
|
|
4352
|
+
"HANDOFF.md": "29337e2ace95b2e7",
|
|
4353
|
+
"games/README.md": "5ad32fe80c61f117",
|
|
4354
|
+
"music/README.md": "a3dc042dadd39df8",
|
|
4355
|
+
"videos/README.md": "16babc3437d5545b",
|
|
4356
|
+
"posts/README.md": "37841aae476bd540",
|
|
4357
|
+
"site/README.md": "1dbdf22c03a1e505",
|
|
4358
|
+
"site/src/worker.mjs": "6cc5c6131eaf6fd0"
|
|
4359
|
+
},
|
|
4360
|
+
"sections": {
|
|
4361
|
+
"AGENTS.md": {
|
|
4362
|
+
"(intro)": "af7f2f732505d379",
|
|
4363
|
+
"## Version-matched authoring guides": "f6261a0e5801b96b",
|
|
4364
|
+
"## Layout": "f3a280b8c96cd068",
|
|
4365
|
+
"## Apps: one screen, roles and parts": "c10aa0441ea89702",
|
|
4366
|
+
"## Commands (all through the pinned CLI in node_modules)": "c20d90de21cde0c7",
|
|
4367
|
+
"## The site": "0cb8dd9a6f8a0096",
|
|
4368
|
+
"## Making games": "bb715272fd1a615b",
|
|
4369
|
+
"## The Game Codex and progress": "0738ef719cef3a4c",
|
|
4370
|
+
"## Art direction and models": "a48fff7bf0a5f2fc",
|
|
4371
|
+
"## Running live games (the back office)": "51ebf2ab756f6e4d",
|
|
4372
|
+
"## Servers and AI seats": "1ccfd549d2369a60",
|
|
4373
|
+
"## Selling things (the shop)": "0df5a5fe1833c624",
|
|
4374
|
+
"## Continuing a build from the Claude app": "0d68081e924ca419",
|
|
4375
|
+
"## Rules": "b2234d80f6cbe71d",
|
|
4376
|
+
"## Telling Homie": "80b46fdd9e578db8",
|
|
4377
|
+
"## Beta": "9d02638207a26e73"
|
|
4378
|
+
}
|
|
4379
|
+
},
|
|
4380
|
+
"named": {
|
|
4381
|
+
"Homie Arcade": {
|
|
4382
|
+
"sections": {
|
|
4383
|
+
"AGENTS.md": {
|
|
4384
|
+
"## Commands (all through the pinned CLI in node_modules)": "8364e05cebefcba4"
|
|
4385
|
+
}
|
|
4386
|
+
}
|
|
4387
|
+
}
|
|
4388
|
+
}
|
|
4347
4389
|
}
|
|
4348
4390
|
}
|
|
4349
4391
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@homie-rocks/studio",
|
|
3
|
-
"version": "0.58.
|
|
3
|
+
"version": "0.58.5",
|
|
4
4
|
"description": "A studio for games, music and video on its own Cloudflare: scaffold, multiplayer starters on the netplay contract, a port toolkit that makes existing single-player web games multiplayer, the site Worker with public rooms (Table/Lobby Durable Objects and D1, all on the free Workers plan, no payment method), a site with the hub's sections (Home, Games, Music, Videos, Rooms, Posts with feeds) in the studio's own look, an epic landing page for every game, big songs and videos in the studio's own R2 once it has storage (uploaded, checked by SHA-256, served at the same addresses), deploy, and the homie.rocks directory.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "Apache-2.0",
|
package/worker/app-streams.mjs
CHANGED
|
@@ -65,6 +65,7 @@ export class AppRecordStreams {
|
|
|
65
65
|
for(const row of await this.revisions(s))s.seen.set(row.collection,row.revision);
|
|
66
66
|
const cookie=headers?.cookie??headers?.Cookie;
|
|
67
67
|
if(this.ctx.storage?.put)await this.ctx.storage.put('app-live:'+s.id,{app:s.app,room:s.room,collections:s.collections,seen:[...s.seen],url:String(s.url),headers:cookie?{cookie}:{},meta});
|
|
68
|
+
await this.attachHibernated();
|
|
68
69
|
const hello=()=>{this.streams.add(s);this.send(s,{collections:s.collections,presence:this.count(s),reset:true});for(const other of this.streams)if(other!==s)this.send(other,{presence:this.count(other)});};
|
|
69
70
|
// A hibernating socket sleeps while the page is open. The browser renews the short role cookie on its own request, not from this object.
|
|
70
71
|
if(typeof WebSocketPair!=='undefined'&&this.ctx.acceptWebSocket){
|
|
@@ -82,7 +83,8 @@ export class AppRecordStreams {
|
|
|
82
83
|
const changed=new Set();
|
|
83
84
|
for(const row of await this.revisions(s)){if(s.seen.get(row.collection)!==row.revision){if(row.collection==='*')for(const c of s.collections)changed.add(c);else if(s.collections.includes(row.collection))changed.add(row.collection);}s.seen.set(row.collection,row.revision);}
|
|
84
85
|
if(!changed.size&&!recheck)return;
|
|
85
|
-
|
|
86
|
+
// 1000, not 4403. The stored handoff expires; the page opens a new socket with the cookie it just renewed.
|
|
87
|
+
if(!await this.authorized(s)){this.close(s);return;}
|
|
86
88
|
this.send(s,{collections:[...changed],presence:this.count(s)});
|
|
87
89
|
}catch{this.close(s);}finally{s.busy=false;if(s.dirty){s.dirty=false;await this.pump(s);}}
|
|
88
90
|
}
|
package/worker/build-id.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
// Generated by lib/build-identity.mjs; identifies the bundled runtime sources.
|
|
2
|
-
export const STUDIO_BUILD = Object.freeze({"version":"0.58.
|
|
2
|
+
export const STUDIO_BUILD = Object.freeze({"version":"0.58.5","sha256":"1af6197dc4435458f1241b39c4cc1d26031baaa88e5258fa6ead03f73f5750fe"});
|
package/worker/office.mjs
CHANGED
|
@@ -1471,8 +1471,9 @@ export async function appRoleSession(response,request,env,meta,launch) {
|
|
|
1471
1471
|
if(ticket) {
|
|
1472
1472
|
const secure=new URL(request.url).protocol==='https:'?'; Secure':'';
|
|
1473
1473
|
const cookie=`studio_app_${meta.id}_${role}=${ticket}; Path=/${meta.id}/; Max-Age=300; HttpOnly${secure}; SameSite=Strict`;
|
|
1474
|
-
//
|
|
1475
|
-
|
|
1474
|
+
// The upgrade response's headers are immutable, and appending throws before the browser receives the socket.
|
|
1475
|
+
// The document and the renew request already set this cookie. Return the socket unchanged.
|
|
1476
|
+
if(response.status===101&&response.webSocket)return response;
|
|
1476
1477
|
response=new Response(response.body,{status:response.status,statusText:response.statusText,headers:response.headers});
|
|
1477
1478
|
response.headers.append('set-cookie',cookie);
|
|
1478
1479
|
}
|
package/worker/version.mjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/** The @homie-rocks/studio version this Worker code is (package.json's; a test keeps them equal). Cache-busts /_homie/site.js. */
|
|
2
|
-
export const STUDIO_VERSION_TAG = '0.58.
|
|
2
|
+
export const STUDIO_VERSION_TAG = '0.58.5';
|