From 5a559cd221de3ac8de4e72d793e1e25401bb40ab Mon Sep 17 00:00:00 2001 From: BL Date: Tue, 13 Oct 2026 06:46:46 +0000 Subject: [PATCH 1/4] Port the SDKs to Effect 4.0.3 and sui-effect 0.3.0 Moves musicos, partyos, platform, streaming and transcoding from effect 4.0.0-rc.112 to stable 4.0.3 (and @effect/platform-node to 4.0.3), and the sui-effect extensions to @unconfirmed/sui-effect 0.3.0. - peers: effect >=4.0.3 <4.1, sui-effect >=0.3.0 <0.4.0, @mysten/sui ^2.29.0 (was exactly 2.29.0; musicos keeps ^2.28), @mysten/bcs a peer ^2.1.1 in partyos and platform (was a dependency) - source: Config.nonEmptyString -> Config.NonEmptyString in the three layerConfig definitions; no other API change, the built .d.ts files are identical to the previous release - versions: musicos/partyos 0.8.0, platform 0.46.0, streaming 0.4.0, transcoding 0.5.0, with the workspace dependencies moved to match - @misofm/effect is deprecated and stays frozen on rc.112; the consumer fixture and check-consumer no longer include it, and the fixture installs @effect/platform-node 4.0.3 explicitly so npm does not resolve a newer 4.0.x whose effect peer is newer than the pinned effect - tests: dependency contracts follow the new ranges; the consumer fixture asserts a single @mysten/bcs Co-Authored-By: Claude Sonnet 5.5 --- bun.lock | 96 +++++++++++-------- packages/musicos/package.json | 11 ++- packages/musicos/src/Musicos.ts | 2 +- packages/partyos/package.json | 18 ++-- packages/partyos/src/Partyos.ts | 2 +- packages/platform/package.json | 22 +++-- packages/platform/src/Miso.ts | 2 +- .../tests/dependency-contract.test.ts | 41 +++++--- .../fixtures/isolated-consumer/imports.ts | 12 +-- .../fixtures/isolated-consumer/package.json | 6 +- .../fixtures/isolated-consumer/verify.mjs | 15 +-- packages/streaming/package.json | 7 +- packages/transcoding/package.json | 13 +-- .../test/dependency-contract.test.ts | 8 +- .../transcoding/test/isolated-consumer.mjs | 8 +- scripts/check-consumer.ts | 8 +- 16 files changed, 150 insertions(+), 121 deletions(-) diff --git a/bun.lock b/bun.lock index a8ca58d..635248f 100644 --- a/bun.lock +++ b/bun.lock @@ -30,14 +30,14 @@ }, "packages/musicos": { "name": "@misofm/musicos", - "version": "0.7.1", + "version": "0.8.0", "devDependencies": { "@effect/language-service": "0.87.2", "@mysten/bcs": "2.1.1", "@mysten/sui": "2.29.0", "@types/bun": "^1.4.0", - "@unconfirmed/sui-effect": "0.2.0", - "effect": "4.0.0-rc.112", + "@unconfirmed/sui-effect": "0.3.0", + "effect": "4.0.3", "typedoc": "^0.28.20", "typedoc-plugin-markdown": "^4.13.0", "typescript": "^7.0.2", @@ -45,69 +45,69 @@ "peerDependencies": { "@mysten/bcs": "^2.1.1", "@mysten/sui": "^2.28", - "@unconfirmed/sui-effect": ">=0.1.0 <0.3.0", - "effect": ">=4.0.0-rc.112 <4.1", + "@unconfirmed/sui-effect": ">=0.3.0 <0.4.0", + "effect": ">=4.0.3 <4.1", "typescript": "^5.7 || ^6 || ^7", }, }, "packages/partyos": { "name": "@misofm/partyos", - "version": "0.7.1", - "dependencies": { - "@mysten/bcs": "^2.1.1", - }, + "version": "0.8.0", "devDependencies": { + "@mysten/bcs": "2.1.1", "@mysten/sui": "2.29.0", "@types/bun": "^1.4.0", - "@unconfirmed/sui-effect": "0.2.0", - "effect": "4.0.0-rc.112", + "@unconfirmed/sui-effect": "0.3.0", + "effect": "4.0.3", "typedoc": "^0.28.20", "typedoc-plugin-markdown": "^4.13.0", "typescript": "^7.0.2", }, "peerDependencies": { - "@mysten/sui": "2.29.0", - "@unconfirmed/sui-effect": ">=0.1.0 <0.3.0", - "effect": "4.0.0-rc.112", + "@mysten/bcs": "^2.1.1", + "@mysten/sui": "^2.29.0", + "@unconfirmed/sui-effect": ">=0.3.0 <0.4.0", + "effect": ">=4.0.3 <4.1", "typescript": "^5.7 || ^6 || ^7", }, }, "packages/platform": { "name": "@misofm/platform", - "version": "0.45.0", + "version": "0.46.0", "dependencies": { - "@misofm/musicos": "0.7.1", - "@misofm/partyos": "0.7.1", - "@misofm/streaming": "0.3.0", - "@mysten/bcs": "^2.1.1", + "@misofm/musicos": "0.8.0", + "@misofm/partyos": "0.8.0", + "@misofm/streaming": "0.4.0", }, "devDependencies": { + "@mysten/bcs": "2.1.1", "@mysten/move-bytecode-template": "^0.4.0", "@mysten/sui": "2.29.0", "@types/bun": "^1.3.14", - "@unconfirmed/sui-effect": "0.2.0", - "effect": "4.0.0-rc.112", + "@unconfirmed/sui-effect": "0.3.0", + "effect": "4.0.3", "typescript": "^7.0.2", }, "peerDependencies": { + "@mysten/bcs": "^2.1.1", "@mysten/move-bytecode-template": "^0.4.0", - "@mysten/sui": "2.29.0", - "@unconfirmed/sui-effect": ">=0.1.0 <0.3.0", - "effect": "4.0.0-rc.112", + "@mysten/sui": "^2.29.0", + "@unconfirmed/sui-effect": ">=0.3.0 <0.4.0", + "effect": ">=4.0.3 <4.1", "typescript": "^5.7 || ^6 || ^7", }, }, "packages/streaming": { "name": "@misofm/streaming", - "version": "0.3.0", + "version": "0.4.0", "devDependencies": { "@types/bun": "^1.4.0", - "effect": "4.0.0-rc.112", + "effect": "4.0.3", "hls.js": "1.6.13", "typescript": "^7.0.2", }, "peerDependencies": { - "effect": "4.0.0-rc.112", + "effect": ">=4.0.3 <4.1", "hls.js": "^1.6", }, "optionalPeers": [ @@ -116,24 +116,24 @@ }, "packages/transcoding": { "name": "@misofm/transcoding", - "version": "0.4.0", + "version": "0.5.0", "dependencies": { - "@misofm/streaming": "0.3.0", + "@misofm/streaming": "0.4.0", "m3u8-parser": "7.2.0", }, "devDependencies": { - "@effect/platform-node": "4.0.0-rc.112", + "@effect/platform-node": "4.0.3", "@types/bun": "1.2.22", "@types/node": "24.10.1", - "effect": "4.0.0-rc.112", + "effect": "4.0.3", "hls.js": "1.6.13", "playwright": "1.55.0", "prettier": "3.6.2", "typescript": "5.9.3", }, "peerDependencies": { - "@effect/platform-node": "4.0.0-rc.112", - "effect": "4.0.0-rc.112", + "@effect/platform-node": ">=4.0.3 <4.1", + "effect": ">=4.0.3 <4.1", }, }, }, @@ -146,9 +146,9 @@ "@effect/language-service": ["@effect/language-service@0.87.2", "", { "bin": { "effect-language-service": "cli.js" } }, "sha512-CfiSoaVQO8pZgaMZGw5VvMvRGybsJ2LaSDoLYaqiVGvo/YYPYVR2GzUKY0h1NtIweq/+SQ5XLrvtzPIttWQ0GQ=="], - "@effect/platform-node": ["@effect/platform-node@4.0.0-rc.112", "", { "dependencies": { "@effect/platform-node-shared": "^4.0.0-rc.112", "mime": "^4.1.0", "undici": "^8.10.0" }, "peerDependencies": { "effect": "^4.0.0-rc.112", "redis": ">=5.0.0 <7.0.0" } }, "sha512-/BMAcdNGQQskLmI0Zoa95KfTZkr9HV9N4NSxaSrusG6GeW6Ulp9KvZ+Rlaiw8lnOt43CXjFLdfll5/k5rxL4hQ=="], + "@effect/platform-node": ["@effect/platform-node@4.0.3", "", { "dependencies": { "@effect/platform-node-shared": "^4.0.3", "undici": "^8.11.2" }, "peerDependencies": { "effect": "^4.0.3", "redis": ">=5.0.0 <7.0.0" } }, "sha512-ctvREpC1EzRVsOm0JyIzYHajAQScFaec6Gl+M7TEIpEqdmmx6Ju11Um92EA/CE2KBfY5Fp1QWlqTkK6lOL7tqg=="], - "@effect/platform-node-shared": ["@effect/platform-node-shared@4.0.0-rc.112", "", { "dependencies": { "@types/ws": "^8.18.1", "ws": "^8.21.3" }, "peerDependencies": { "effect": "^4.0.0-rc.112" } }, "sha512-ttjz0xKamFN7vL8pNDYVwddJLjZvqKePc05djlz2VcdaKbLsnYbtMnL1rbOfHgEnIUSHGh7FkjaN4DM1Ov81sQ=="], + "@effect/platform-node-shared": ["@effect/platform-node-shared@4.0.4", "", { "dependencies": { "@types/ws": "^8.18.2", "ws": "^8.22.0" }, "peerDependencies": { "effect": "^4.0.4" } }, "sha512-gh2KRmqGWrJ0FVL8GqnI1GpB+fCfCUI7sGiUZkxxBHyHj1t94rm6VDJffCfuVZWe6GpvYXtizifVczUrgOce8A=="], "@gerrit0/mini-shiki": ["@gerrit0/mini-shiki@3.23.0", "", { "dependencies": { "@shikijs/engine-oniguruma": "^3.23.0", "@shikijs/langs": "^3.23.0", "@shikijs/themes": "^3.23.0", "@shikijs/types": "^3.23.0", "@shikijs/vscode-textmate": "^10.0.2" } }, "sha512-bEMORlG0cqdjVyCEuU0cDQbORWX+kYCeo0kV1lbxF5bt4r7SID2l9bqsxJEM0zndaxpOUT7riCyIVEuqq/Ynxg=="], @@ -242,7 +242,7 @@ "@types/unist": ["@types/unist@3.0.3", "", {}, "sha512-ko/gIFJRv177XgZsZcBwnqJN5x/Gien8qNOn0D5bQU/zAzVf9Zt3BlcUiLqhV9y4ARk0GbT3tnUiPNgnTXzc/Q=="], - "@types/ws": ["@types/ws@8.18.1", "", { "dependencies": { "@types/node": "*" } }, "sha512-ThVF6DCVhA8kUGy+aazFQ4kXQ7E1Ty7A3ypFOe0IcJV8O/M511G99AW24irKrW56Wt44yG9+ij8FaqoBGkuBXg=="], + "@types/ws": ["@types/ws@8.18.2", "", { "dependencies": { "@types/node": "*" } }, "sha512-67MQl+fpWKVTT1NYdnmo3U4sc/xPo/zQBncVnI74qmQa0z/b+1g6iYqNmGCPbxO+zz2aklb08a0oHfegiVd0/w=="], "@typescript/old": ["typescript@6.0.3", "", { "bin": { "tsc": "bin/tsc", "tsserver": "bin/tsserver" } }, "sha512-y2TvuxSZPDyQakkFRPZHKFm+KKVqIisdg9/CZwm9ftvKXLP8NRWj38/ODjNbr43SsoXqNuAisEf1GdCxqWcdBw=="], @@ -286,7 +286,7 @@ "@typescript/typescript-win32-x64": ["@typescript/typescript-win32-x64@7.0.2", "", { "os": "win32", "cpu": "x64" }, "sha512-0BQ3HkAHHlKLSp1qRvf3SUhGpGsDuhB/jgFw75guyqbxJqEaS0Cw/VFO8i2nHglJUzQCRtMMR/IBAKE3ETMC4g=="], - "@unconfirmed/sui-effect": ["@unconfirmed/sui-effect@0.2.0", "", { "peerDependencies": { "@mysten/bcs": "^2.1.1", "@mysten/sui": "^2.28", "effect": "4.0.0-rc.112" } }, "sha512-a/xg00GiJE83NjDLc90DCPuS1fT8tLRI/3gElLMQUm5twiW4vfZW0e5Jbv4xJIxyDU8+tgA/w1BeC2+GCNYbMQ=="], + "@unconfirmed/sui-effect": ["@unconfirmed/sui-effect@0.3.0", "", { "peerDependencies": { "@mysten/bcs": "^2.1.1", "@mysten/sui": "^2.28", "effect": ">=4.0.3 <4.1" } }, "sha512-080t9NcUlOAbrPWv4mJXh7GRi9VBYdDTpszLZMEj623vep0YnASdtDJjrJS8vYC+OoK2gsjQua7lx0vLLvIu8g=="], "@videojs/vhs-utils": ["@videojs/vhs-utils@4.1.2", "", { "dependencies": { "@babel/runtime": "^7.12.5", "global": "^4.4.0" } }, "sha512-1Dsv5dtWOq0LP1G37O46FQFA2tKAZON5UMe6dFPxT7JvPhEx8QIXcFQxan8+hHI3fX6aomFRFrUBJNgRYQDSXA=="], @@ -338,8 +338,6 @@ "mdurl": ["mdurl@2.1.0", "", {}, "sha512-1+HBaOx0zi/dQWht8rNv9MYf9qqpqL/kxI0hXImU6Y547zM6Sni8BQibt7ifgMcYtQg41ao3Ivd6cnSM86inpg=="], - "mime": ["mime@4.1.0", "", { "bin": { "mime": "bin/cli.js" } }, "sha512-X5ju04+cAzsojXKes0B/S4tcYtFAJ6tTMuSPBEn9CPGlrWr8Fiw7qYeLT0XyH80HSoAoqWCaz+MWKh22P7G1cw=="], - "min-document": ["min-document@2.19.2", "", { "dependencies": { "dom-walk": "^0.1.0" } }, "sha512-8S5I8db/uZN8r9HSLFVWPdJCvYOejMcEC82VIzNUc6Zkklf/d1gg2psfE79/vyhWOj4+J8MtwmoOz3TmvaGu5A=="], "minimatch": ["minimatch@10.2.6", "", { "dependencies": { "brace-expansion": "^5.0.8" } }, "sha512-vpLQEs+VLCr1nU0BXS07maYoFwlDAH0gngQuuttxIwutDFEMHq2blX+8vpgxDdK3J1PwjCJiep77OitTZ4Ll1A=="], @@ -376,20 +374,34 @@ "uc.micro": ["uc.micro@2.1.0", "", {}, "sha512-ARDJmphmdvUk6Glw7y9DQ2bFkKBHwQHLi2lsaH6PPmz/Ka9sFOBsBluozhDltWmnv9u/cF6Rt87znRTPV+yp/A=="], - "undici": ["undici@8.10.2", "", {}, "sha512-/y4/bH9YNU5hi9NIrpOuvGXFcxrj3CMrV+/AYpowAYTpHn8gX/XPFjNy766FPoYY0miQhdW977JFWKGNhBdwyQ=="], + "undici": ["undici@8.11.2", "", {}, "sha512-u4UB2/IrKdU6lFxumHmmo1a3fCQO5tzQllRorfoRS63txhrB7xTpSn1PftwC4qEHkOaqP95fCWW4lJzwErwzhQ=="], "undici-types": ["undici-types@7.16.0", "", {}, "sha512-Zz+aZWSj8LE6zoxD+xrjh4VfkIG8Ya6LvYkZqtUQGJPZjYl53ypCaUwWqo7eI0x66KBGeRo+mlBEkMSeSZ38Nw=="], "valibot": ["valibot@1.4.2", "", { "peerDependencies": { "typescript": ">=5" }, "optionalPeers": ["typescript"] }, "sha512-gjdCvJ6d3RyHAneqxMYMW9QMCwYMb3jpOO0IyHZV1bnRHFBHrX3VkIILt5XYR0WhwHiH7Mty8ovuPZ/O3gamrg=="], - "ws": ["ws@8.21.3", "", { "peerDependencies": { "bufferutil": "^4.0.1", "utf-8-validate": ">=5.0.2" }, "optionalPeers": ["bufferutil", "utf-8-validate"] }, "sha512-201TZ/kPWxoPr/OKWjquZR1SWKXcvxdH+e1xrx89b3YbmzLMFCLfnaG1HFIgWzJOEWZ7MvpK++odZufgYR50Rw=="], + "ws": ["ws@8.22.0", "", { "peerDependencies": { "bufferutil": "^4.0.1", "utf-8-validate": ">=5.0.2" }, "optionalPeers": ["bufferutil", "utf-8-validate"] }, "sha512-Ydggc987+RO0AnWtZ/7Wq9FtNvcrL1b/RO0ud9mWjUPgDrsAAwQSF51sm2hm1XofbU/4jkpGEsLFsZZxU+1DOg=="], "yaml": ["yaml@2.9.0", "", { "bin": { "yaml": "bin.mjs" } }, "sha512-2AvhNX3mb8zd6Zy7INTtSpl1F15HW6Wnqj0srWlkKLcpYl/gMIMJiyuGq2KeI2YFxUPjdlB+3Lc10seMLtL4cA=="], "zod": ["zod@4.5.4", "", {}, "sha512-sC95tT5iHHH9gtpj6A81kh+NEaRAUFN+qlUPDUbRfOMvNf5QCBqsb3WgvnpVtK5Y+4UfA6KqufotuTvMGiTlsA=="], + "@effect/platform-node/effect": ["effect@4.0.3", "", {}, "sha512-LoWn/Uwwx0JjHSDmBAAahx8sB+klzM6vsZovnbYowBNw6B4QScJLRLBByO61plvNiycx7HPN8FnsWUCu0eXW5w=="], + + "@effect/platform-node-shared/effect": ["effect@4.0.3", "", {}, "sha512-LoWn/Uwwx0JjHSDmBAAahx8sB+klzM6vsZovnbYowBNw6B4QScJLRLBByO61plvNiycx7HPN8FnsWUCu0eXW5w=="], + + "@misofm/musicos/effect": ["effect@4.0.3", "", {}, "sha512-LoWn/Uwwx0JjHSDmBAAahx8sB+klzM6vsZovnbYowBNw6B4QScJLRLBByO61plvNiycx7HPN8FnsWUCu0eXW5w=="], + + "@misofm/partyos/effect": ["effect@4.0.3", "", {}, "sha512-LoWn/Uwwx0JjHSDmBAAahx8sB+klzM6vsZovnbYowBNw6B4QScJLRLBByO61plvNiycx7HPN8FnsWUCu0eXW5w=="], + + "@misofm/platform/effect": ["effect@4.0.3", "", {}, "sha512-LoWn/Uwwx0JjHSDmBAAahx8sB+klzM6vsZovnbYowBNw6B4QScJLRLBByO61plvNiycx7HPN8FnsWUCu0eXW5w=="], + + "@misofm/streaming/effect": ["effect@4.0.3", "", {}, "sha512-LoWn/Uwwx0JjHSDmBAAahx8sB+klzM6vsZovnbYowBNw6B4QScJLRLBByO61plvNiycx7HPN8FnsWUCu0eXW5w=="], + "@misofm/transcoding/@types/bun": ["@types/bun@1.2.22", "", { "dependencies": { "bun-types": "1.2.22" } }, "sha512-5A/KrKos2ZcN0c6ljRSOa1fYIyCKhZfIVYeuyb4snnvomnpFqC0tTsEkdqNxbAgExV384OETQ//WAjl3XbYqQA=="], + "@misofm/transcoding/effect": ["effect@4.0.3", "", {}, "sha512-LoWn/Uwwx0JjHSDmBAAahx8sB+klzM6vsZovnbYowBNw6B4QScJLRLBByO61plvNiycx7HPN8FnsWUCu0eXW5w=="], + "@misofm/transcoding/typescript": ["typescript@5.9.3", "", { "bin": { "tsc": "bin/tsc", "tsserver": "bin/tsserver" } }, "sha512-jl1vZzPDinLr9eUt3J/t7V6FgNEw9QjvBPdysz9KfQDD41fQrC2Y4vKQdiaUpFT4bXlb1RHhLpp8wtm6M5TgSw=="], "@mysten/codegen/@types/node": ["@types/node@26.4.1", "", { "dependencies": { "undici-types": "~8.3.0" } }, "sha512-k97ENvZWtvA6yqz5/FS6a7duDgOPEeOQOc2iKS/nY6mX6qJUKtLnWzQS+Xj6tXweyj6ZcTAK2Qecetnvi9nCLA=="], @@ -400,6 +412,8 @@ "@types/ws/@types/node": ["@types/node@26.4.1", "", { "dependencies": { "undici-types": "~8.3.0" } }, "sha512-k97ENvZWtvA6yqz5/FS6a7duDgOPEeOQOc2iKS/nY6mX6qJUKtLnWzQS+Xj6tXweyj6ZcTAK2Qecetnvi9nCLA=="], + "@unconfirmed/sui-effect/effect": ["effect@4.0.3", "", {}, "sha512-LoWn/Uwwx0JjHSDmBAAahx8sB+klzM6vsZovnbYowBNw6B4QScJLRLBByO61plvNiycx7HPN8FnsWUCu0eXW5w=="], + "bun-types/@types/node": ["@types/node@26.4.1", "", { "dependencies": { "undici-types": "~8.3.0" } }, "sha512-k97ENvZWtvA6yqz5/FS6a7duDgOPEeOQOc2iKS/nY6mX6qJUKtLnWzQS+Xj6tXweyj6ZcTAK2Qecetnvi9nCLA=="], "@misofm/transcoding/@types/bun/bun-types": ["bun-types@1.2.22", "", { "dependencies": { "@types/node": "*" }, "peerDependencies": { "@types/react": "^19" } }, "sha512-hwaAu8tct/Zn6Zft4U9BsZcXkYomzpHJX28ofvx7k0Zz2HNz54n1n+tDgxoWFGB4PcFvJXJQloPhaV2eP3Q6EA=="], diff --git a/packages/musicos/package.json b/packages/musicos/package.json index a5161e9..b119edc 100644 --- a/packages/musicos/package.json +++ b/packages/musicos/package.json @@ -1,6 +1,6 @@ { "name": "@misofm/musicos", - "version": "0.7.1", + "version": "0.8.0", "packageManager": "bun@1.4.0", "description": "A sui-effect extension for the Miso object model (Composition, Recording, Release, Track): the Musicos service, PTB fragments, event decoders, and BCS codecs.", "license": "Apache-2.0", @@ -90,6 +90,7 @@ "dist", "src", "README.md", + "CHANGELOG.md", "AGENTS.md", "LLMS.md", "LICENSE", @@ -100,8 +101,8 @@ "@mysten/bcs": "2.1.1", "@mysten/sui": "2.29.0", "@types/bun": "^1.4.0", - "@unconfirmed/sui-effect": "0.2.0", - "effect": "4.0.0-rc.112", + "@unconfirmed/sui-effect": "0.3.0", + "effect": "4.0.3", "typedoc": "^0.28.20", "typedoc-plugin-markdown": "^4.13.0", "typescript": "^7.0.2" @@ -109,8 +110,8 @@ "peerDependencies": { "@mysten/bcs": "^2.1.1", "@mysten/sui": "^2.28", - "@unconfirmed/sui-effect": ">=0.1.0 <0.3.0", - "effect": ">=4.0.0-rc.112 <4.1", + "@unconfirmed/sui-effect": ">=0.3.0 <0.4.0", + "effect": ">=4.0.3 <4.1", "typescript": "^5.7 || ^6 || ^7" }, "main": "./dist/index.js" diff --git a/packages/musicos/src/Musicos.ts b/packages/musicos/src/Musicos.ts index 4118993..507d5e6 100644 --- a/packages/musicos/src/Musicos.ts +++ b/packages/musicos/src/Musicos.ts @@ -455,7 +455,7 @@ export class Musicos extends Context.Service()("@misofm */ static readonly layerConfig: Layer.Layer = Layer.unwrap( Effect.gen(function* () { - const packageId = yield* Config.nonEmptyString("PACKAGE_ID").pipe(Config.nested("MUSICOS"), Config.option); + const packageId = yield* Config.NonEmptyString("PACKAGE_ID").pipe(Config.nested("MUSICOS"), Config.option); return Musicos.layer(Option.isSome(packageId) ? { deployment: { packageId: packageId.value } } : undefined); }), ); diff --git a/packages/partyos/package.json b/packages/partyos/package.json index a2976b1..95fea53 100644 --- a/packages/partyos/package.json +++ b/packages/partyos/package.json @@ -1,6 +1,6 @@ { "name": "@misofm/partyos", - "version": "0.7.1", + "version": "0.8.0", "packageManager": "bun@1.4.0", "description": "A sui-effect extension for the PartyOS object model (Party identity, admin caps, and group membership) on Sui.", "license": "Apache-2.0", @@ -90,25 +90,25 @@ "dist", "src", "README.md", + "CHANGELOG.md", "LICENSE", "package.json" ], - "dependencies": { - "@mysten/bcs": "^2.1.1" - }, "devDependencies": { + "@mysten/bcs": "2.1.1", "@mysten/sui": "2.29.0", "@types/bun": "^1.4.0", - "@unconfirmed/sui-effect": "0.2.0", - "effect": "4.0.0-rc.112", + "@unconfirmed/sui-effect": "0.3.0", + "effect": "4.0.3", "typedoc": "^0.28.20", "typedoc-plugin-markdown": "^4.13.0", "typescript": "^7.0.2" }, "peerDependencies": { - "@mysten/sui": "2.29.0", - "@unconfirmed/sui-effect": ">=0.1.0 <0.3.0", - "effect": "4.0.0-rc.112", + "@mysten/bcs": "^2.1.1", + "@mysten/sui": "^2.29.0", + "@unconfirmed/sui-effect": ">=0.3.0 <0.4.0", + "effect": ">=4.0.3 <4.1", "typescript": "^5.7 || ^6 || ^7" }, "main": "./dist/index.js" diff --git a/packages/partyos/src/Partyos.ts b/packages/partyos/src/Partyos.ts index c82c20b..d6933c8 100644 --- a/packages/partyos/src/Partyos.ts +++ b/packages/partyos/src/Partyos.ts @@ -297,7 +297,7 @@ export class Partyos extends Context.Service()("@misofm static readonly layerConfig: Layer.Layer = Layer.unwrap( Effect.gen(function* () { - const packageId = yield* Config.nonEmptyString("PACKAGE_ID").pipe(Config.option, Config.nested("PARTYOS")); + const packageId = yield* Config.NonEmptyString("PACKAGE_ID").pipe(Config.option, Config.nested("PARTYOS")); // The raw config value is handed to `layer` unvalidated: `layer` // itself runs it through `validatePartyDeployment` (a typed Effect // failure), so a malformed `PARTYOS_PACKAGE_ID` is a diff --git a/packages/platform/package.json b/packages/platform/package.json index fc24d9a..074ede8 100644 --- a/packages/platform/package.json +++ b/packages/platform/package.json @@ -1,6 +1,6 @@ { "name": "@misofm/platform", - "version": "0.45.0", + "version": "0.46.0", "packageManager": "bun@1.4.0", "description": "Complete client SDK for the Miso platform on Sui \u2014 high-level reads, pressings, listings, records, work publishing, Party extensions, and the first-party extensions built on top of the @misofm/musicos object model and the @misofm/partyos Party identity model.", "license": "Apache-2.0", @@ -140,6 +140,7 @@ "dist", "src", "README.md", + "CHANGELOG.md", "LICENSE", "package.json" ], @@ -151,24 +152,25 @@ "prepare": "rm -rf dist && tsc -p tsconfig.build.json --noCheck" }, "dependencies": { - "@misofm/streaming": "0.3.0", - "@mysten/bcs": "^2.1.1", - "@misofm/musicos": "0.7.1", - "@misofm/partyos": "0.7.1" + "@misofm/musicos": "0.8.0", + "@misofm/partyos": "0.8.0", + "@misofm/streaming": "0.4.0" }, "devDependencies": { + "@mysten/bcs": "2.1.1", "@mysten/move-bytecode-template": "^0.4.0", "@mysten/sui": "2.29.0", "@types/bun": "^1.3.14", - "@unconfirmed/sui-effect": "0.2.0", - "effect": "4.0.0-rc.112", + "@unconfirmed/sui-effect": "0.3.0", + "effect": "4.0.3", "typescript": "^7.0.2" }, "peerDependencies": { + "@mysten/bcs": "^2.1.1", "@mysten/move-bytecode-template": "^0.4.0", - "@mysten/sui": "2.29.0", - "@unconfirmed/sui-effect": ">=0.1.0 <0.3.0", - "effect": "4.0.0-rc.112", + "@mysten/sui": "^2.29.0", + "@unconfirmed/sui-effect": ">=0.3.0 <0.4.0", + "effect": ">=4.0.3 <4.1", "typescript": "^5.7 || ^6 || ^7" }, "main": "./dist/index.js" diff --git a/packages/platform/src/Miso.ts b/packages/platform/src/Miso.ts index 8193c2a..9926e41 100644 --- a/packages/platform/src/Miso.ts +++ b/packages/platform/src/Miso.ts @@ -896,7 +896,7 @@ export class Miso extends Context.Service()("@misofm/platform */ static readonly layerConfig: Layer.Layer = Layer.unwrap( Effect.gen(function* () { - const configuredNetwork = yield* Config.nonEmptyString("MISO_NETWORK").pipe(Config.option); + const configuredNetwork = yield* Config.NonEmptyString("MISO_NETWORK").pipe(Config.option); const network = configuredNetwork._tag === "Some" ? configuredNetwork.value : (yield* Sui).network; const deployment = yield* Effect.try({ try: () => getMisoPlatformDeployment(network), diff --git a/packages/platform/tests/dependency-contract.test.ts b/packages/platform/tests/dependency-contract.test.ts index 5662708..fd1bc4a 100644 --- a/packages/platform/tests/dependency-contract.test.ts +++ b/packages/platform/tests/dependency-contract.test.ts @@ -11,8 +11,11 @@ type PackageManifest = { }; const repositoryRoot = `${import.meta.dir}/..`; -const exactVersions = { - "@mysten/sui": "2.29.0", +// The pinned development version of each package the SDK builds against, and +// the (wider) peer range consumers may bring. The dev pin must satisfy the +// peer range, and a consumer must not install the package itself. +const pinnedVersions = { + "@mysten/sui": { development: "2.29.0", peer: "^2.29.0" }, } as const; const exactVersionPattern = /^\d+\.\d+\.\d+(?:-[0-9A-Za-z.-]+)?$/; @@ -20,14 +23,17 @@ async function readManifest(path: string): Promise { return Bun.file(path).json(); } -test("Sui uses one exact development and peer dependency contract", async () => { +test("Sui is pinned for development and a caret range for consumers", async () => { const manifest = await readManifest(`${repositoryRoot}/package.json`); const consumer = await readManifest( `${repositoryRoot}/tests/fixtures/isolated-consumer/package.json`, ); expect(Object.keys(consumer.dependencies ?? {})).toEqual([ - "@misofm/effect", + // @misofm/transcoding peers on the Effect release train; npm would + // otherwise resolve `@effect/platform-node` to the newest 4.0.x, whose + // `effect` peer can be newer than the pinned `effect` below. + "@effect/platform-node", "@misofm/musicos", "@misofm/partyos", "@misofm/platform", @@ -42,17 +48,17 @@ test("Sui uses one exact development and peer dependency contract", async () => "typescript", ]); - for (const [name, expectedVersion] of Object.entries(exactVersions)) { + for (const [name, expected] of Object.entries(pinnedVersions)) { const developmentVersion = manifest.devDependencies?.[name]; const peerVersion = manifest.peerDependencies?.[name]; - expect(developmentVersion, `${name} devDependency`).toBe(expectedVersion); - expect(peerVersion, `${name} peerDependency`).toBe(expectedVersion); + expect(developmentVersion, `${name} devDependency`).toBe(expected.development); + expect(peerVersion, `${name} peerDependency`).toBe(expected.peer); expect(developmentVersion, `${name} devDependency must be exact`).toMatch( exactVersionPattern, ); - expect(peerVersion, `${name} peerDependency must be exact`).toMatch( - exactVersionPattern, + expect(peerVersion, `${name} peer range must admit the dev pin`).toBe( + `^${developmentVersion}`, ); expect( consumer.devDependencies?.[name] ?? consumer.dependencies?.[name], @@ -61,8 +67,8 @@ test("Sui uses one exact development and peer dependency contract", async () => } }); -test("installed Sui matches the declared exact version", async () => { - for (const [name, expectedVersion] of Object.entries(exactVersions)) { +test("installed Sui matches the declared development version", async () => { + for (const [name, { development: expectedVersion }] of Object.entries(pinnedVersions)) { const installed = await readManifest( `${repositoryRoot}/node_modules/${name}/package.json`, ); @@ -70,3 +76,16 @@ test("installed Sui matches the declared exact version", async () => { expect(installed.version, `${name} installed version`).toBe(expectedVersion); } }); + +test("Effect, sui-effect and bcs are peers on the stable 4.0.x line", async () => { + const manifest = await readManifest(`${repositoryRoot}/package.json`); + + expect(manifest.peerDependencies?.effect).toBe(">=4.0.3 <4.1"); + expect(manifest.peerDependencies?.["@unconfirmed/sui-effect"]).toBe(">=0.3.0 <0.4.0"); + // One copy of @mysten/bcs across the SDKs and sui-effect: a peer, not a + // bundled dependency. + expect(manifest.peerDependencies?.["@mysten/bcs"]).toBe("^2.1.1"); + expect(manifest.dependencies?.["@mysten/bcs"]).toBeUndefined(); + expect(manifest.devDependencies?.effect).toBe("4.0.3"); + expect(manifest.devDependencies?.["@unconfirmed/sui-effect"]).toBe("0.3.0"); +}); diff --git a/packages/platform/tests/fixtures/isolated-consumer/imports.ts b/packages/platform/tests/fixtures/isolated-consumer/imports.ts index 2f55b84..32836cc 100644 --- a/packages/platform/tests/fixtures/isolated-consumer/imports.ts +++ b/packages/platform/tests/fixtures/isolated-consumer/imports.ts @@ -1,4 +1,4 @@ -// Proves the published `.d.ts` for @misofm/effect, @misofm/musicos, +// Proves the published `.d.ts` for @misofm/musicos, // @misofm/partyos, @misofm/platform, @misofm/streaming, and // @misofm/transcoding are self-contained when installed as real tarballs (see // ../../../../scripts/check-consumer.ts, or `bun run test:consumer` at the @@ -7,9 +7,6 @@ // declaration file is missing, malformed, or has a broken relative path, this // file fails to typecheck with `skipLibCheck: false`. -import { SuiClient } from "@misofm/effect"; -import { SuiRpcError } from "@misofm/effect/errors"; - // musicos is a sui-effect extension (misofm/sdks#34): the `Musicos` service, // the derived `musicos()` Promise registration, and every curated subpath // the Definition of Done names (`.`, `/errors`, `/transactions`, @@ -78,9 +75,6 @@ import { ProcessExitError } from "@misofm/transcoding/errors"; // exported interface/type alias, or (for the curated `contracts` barrels and // the raw BCS codecs, which expose no standalone type export) derived from // the value itself so it still proves the underlying declaration resolves. -type _SuiClientLayerArg = Parameters[0]; -type _SuiRpcError = SuiRpcError; - type _MusicosOptions = MusicosOptions; type _MusicosService = MusicosService; type _MusicosDeploymentInvalid = MusicosDeploymentInvalid; @@ -150,8 +144,6 @@ type _TranscodingProcessExitError = ProcessExitError; // Value-position uses of every imported value. void ([ - SuiClient, - SuiRpcError, Musicos, musicos, MusicosDeploymentInvalid, @@ -196,8 +188,6 @@ void ([ // Referenced so the otherwise-unused type aliases above cannot be reported as // dead code by a stricter consumer tsconfig than this fixture's own. export type IsolatedConsumerTypeProbe = [ - _SuiClientLayerArg, - _SuiRpcError, _MusicosOptions, _MusicosService, _MusicosDeploymentInvalid, diff --git a/packages/platform/tests/fixtures/isolated-consumer/package.json b/packages/platform/tests/fixtures/isolated-consumer/package.json index 4bc5913..e326eb0 100644 --- a/packages/platform/tests/fixtures/isolated-consumer/package.json +++ b/packages/platform/tests/fixtures/isolated-consumer/package.json @@ -6,14 +6,14 @@ "check": "tsc --noEmit && node verify.mjs" }, "dependencies": { - "@misofm/effect": "file:../misofm-effect.tgz", + "@effect/platform-node": "4.0.3", "@misofm/musicos": "file:../misofm-musicos.tgz", "@misofm/partyos": "file:../misofm-partyos.tgz", "@misofm/platform": "file:../misofm-platform.tgz", "@misofm/streaming": "file:../misofm-streaming.tgz", "@misofm/transcoding": "file:../misofm-transcoding.tgz", - "effect": "4.0.0-rc.112", - "@unconfirmed/sui-effect": "0.2.0", + "effect": "4.0.3", + "@unconfirmed/sui-effect": "0.3.0", "typescript": "5.9.3" } } diff --git a/packages/platform/tests/fixtures/isolated-consumer/verify.mjs b/packages/platform/tests/fixtures/isolated-consumer/verify.mjs index c2abf04..506a052 100644 --- a/packages/platform/tests/fixtures/isolated-consumer/verify.mjs +++ b/packages/platform/tests/fixtures/isolated-consumer/verify.mjs @@ -1,9 +1,6 @@ import { existsSync, readFileSync, readdirSync, realpathSync } from "node:fs"; import { join } from "node:path"; -import * as effectRoot from "@misofm/effect"; -import * as effectErrors from "@misofm/effect/errors"; - import * as musicosRoot from "@misofm/musicos"; import * as musicosDeployments from "@misofm/musicos/deployments"; import * as musicosTransactions from "@misofm/musicos/transactions"; @@ -45,13 +42,6 @@ function hasExport(namespace, name) { // --- module load + expected-export checks ------------------------------- -invariant(Object.keys(effectRoot).length > 0, "@misofm/effect root export did not load"); -invariant(hasExport(effectRoot, "SuiClient"), "@misofm/effect root missing SuiClient"); - -invariant(Object.keys(effectErrors).length > 0, "@misofm/effect/errors export did not load"); -invariant(hasExport(effectErrors, "SuiRpcError"), "@misofm/effect/errors missing SuiRpcError"); -invariant(hasExport(effectErrors, "ObjectNotFoundError"), "@misofm/effect/errors missing ObjectNotFoundError"); - invariant(Object.keys(musicosRoot).length > 0, "@misofm/musicos root export did not load"); invariant(hasExport(musicosRoot, "Musicos"), "@misofm/musicos root missing the Musicos service"); invariant(hasExport(musicosRoot, "musicos"), "@misofm/musicos root missing the musicos() registration"); @@ -280,6 +270,11 @@ assertSingleInstance("@mysten/sui"); // composes programs from more than one `@misofm/*` package. assertSingleInstance("effect"); +// `@mysten/bcs` is a peer of partyos, musicos and platform (not a bundled +// dependency), so codecs generated in one package and parsed in another +// share one `BcsType` implementation. +assertSingleInstance("@mysten/bcs"); + // A consumer that ends up resolving two copies of the same `@misofm/*` // package (e.g. because one package pins another at a version distinct from // the workspace's) gets two distinct class identities for the same name, so diff --git a/packages/streaming/package.json b/packages/streaming/package.json index c086e40..624b865 100644 --- a/packages/streaming/package.json +++ b/packages/streaming/package.json @@ -1,6 +1,6 @@ { "name": "@misofm/streaming", - "version": "0.3.0", + "version": "0.4.0", "packageManager": "bun@1.4.0", "description": "The miso-hls/v1 streaming transcode contract (rendition ladder, segment policy, Quilt item naming) plus a browser player for Miso streams.", "license": "Apache-2.0", @@ -50,6 +50,7 @@ "dist", "src", "README.md", + "CHANGELOG.md", "LICENSE", "package.json" ], @@ -61,7 +62,7 @@ "prepare": "rm -rf dist && tsc -p tsconfig.build.json --noCheck" }, "peerDependencies": { - "effect": "4.0.0-rc.112", + "effect": ">=4.0.3 <4.1", "hls.js": "^1.6" }, "peerDependenciesMeta": { @@ -71,7 +72,7 @@ }, "devDependencies": { "@types/bun": "^1.4.0", - "effect": "4.0.0-rc.112", + "effect": "4.0.3", "hls.js": "1.6.13", "typescript": "^7.0.2" } diff --git a/packages/transcoding/package.json b/packages/transcoding/package.json index 6e76a7b..a523374 100644 --- a/packages/transcoding/package.json +++ b/packages/transcoding/package.json @@ -1,6 +1,6 @@ { "name": "@misofm/transcoding", - "version": "0.4.0", + "version": "0.5.0", "description": "Effect-based deterministic plaintext AAC fMP4 HLS transcoder.", "repository": { "type": "git", @@ -26,6 +26,7 @@ "dist", "docs", "README.md", + "CHANGELOG.md", "LICENSE" ], "exports": { @@ -57,18 +58,18 @@ "test:ffmpeg": "bun test test/ffmpeg-integration.test.ts" }, "dependencies": { - "@misofm/streaming": "0.3.0", + "@misofm/streaming": "0.4.0", "m3u8-parser": "7.2.0" }, "peerDependencies": { - "@effect/platform-node": "4.0.0-rc.112", - "effect": "4.0.0-rc.112" + "@effect/platform-node": ">=4.0.3 <4.1", + "effect": ">=4.0.3 <4.1" }, "devDependencies": { - "@effect/platform-node": "4.0.0-rc.112", + "@effect/platform-node": "4.0.3", "@types/bun": "1.2.22", "@types/node": "24.10.1", - "effect": "4.0.0-rc.112", + "effect": "4.0.3", "hls.js": "1.6.13", "playwright": "1.55.0", "prettier": "3.6.2", diff --git a/packages/transcoding/test/dependency-contract.test.ts b/packages/transcoding/test/dependency-contract.test.ts index 096e5a7..bc7fc69 100644 --- a/packages/transcoding/test/dependency-contract.test.ts +++ b/packages/transcoding/test/dependency-contract.test.ts @@ -5,14 +5,14 @@ import { join } from "node:path"; const readJson = async (url: URL): Promise> => JSON.parse(await readFile(url, "utf8")) as Record; -test("Effect peers are exact and the runtime dependency is storage-neutral", async () => { +test("Effect peers are the stable 4.0.x range and the runtime dependency is storage-neutral", async () => { const manifest = await readJson(new URL("../package.json", import.meta.url)); expect(manifest.peerDependencies).toEqual({ - "@effect/platform-node": "4.0.0-rc.112", - effect: "4.0.0-rc.112", + "@effect/platform-node": ">=4.0.3 <4.1", + effect: ">=4.0.3 <4.1", }); expect(manifest.dependencies).toEqual({ - "@misofm/streaming": "0.3.0", + "@misofm/streaming": "0.4.0", "m3u8-parser": "7.2.0", }); }); diff --git a/packages/transcoding/test/isolated-consumer.mjs b/packages/transcoding/test/isolated-consumer.mjs index 203e763..8e865b3 100644 --- a/packages/transcoding/test/isolated-consumer.mjs +++ b/packages/transcoding/test/isolated-consumer.mjs @@ -56,8 +56,8 @@ if (runtime === "node") { "install", "--ignore-scripts", tarball, - "effect@4.0.0-rc.112", - "@effect/platform-node@4.0.0-rc.112", + "effect@4.0.3", + "@effect/platform-node@4.0.3", ]); await run("node", [ "--input-type=module", @@ -70,8 +70,8 @@ if (runtime === "node") { "--ignore-scripts", tarball, ...extras, - "effect@4.0.0-rc.112", - "@effect/platform-node@4.0.0-rc.112", + "effect@4.0.3", + "@effect/platform-node@4.0.3", ]); await run("bun", [ "-e", diff --git a/scripts/check-consumer.ts b/scripts/check-consumer.ts index f83fbc6..26ead16 100644 --- a/scripts/check-consumer.ts +++ b/scripts/check-consumer.ts @@ -23,8 +23,14 @@ function unscopedName(pkgName: string): string { return pkgName.includes("/") ? pkgName.split("/")[1]! : pkgName; } +// `@misofm/effect` is deprecated and frozen on `effect@4.0.0-rc.112` (it was +// not ported to the stable 4.0.x line; sui-effect supersedes it). It cannot +// share an install with the ported packages, so the consumer fixture does not +// include it. Its own build and tests still run in the workspace. +const FROZEN_PACKAGES = new Set(["effect"]); + const packageDirs = readdirSync(packagesDir, { withFileTypes: true }) - .filter((entry) => entry.isDirectory()) + .filter((entry) => entry.isDirectory() && !FROZEN_PACKAGES.has(entry.name)) .map((entry) => entry.name) .sort(); From 4f34be17bfd05742a41aa2f92cca25d4345b29eb Mon Sep 17 00:00:00 2001 From: BL Date: Tue, 13 Oct 2026 06:46:46 +0000 Subject: [PATCH 2/4] partyos: golden vectors for the party recipes, built offline Four sponsored vectors (mainnet individual, testnet group, Unicode name, maximum-length name) generated by 0.7.1 on the rc.112 stack; the 0.8.0 recipes build byte-identical TransactionData and digests with no client. Co-Authored-By: Claude Sonnet 5.5 --- .../partyos/tests/fixtures/party.golden.json | 73 +++++++++++++++++ packages/partyos/tests/golden.test.ts | 81 +++++++++++++++++++ 2 files changed, 154 insertions(+) create mode 100644 packages/partyos/tests/fixtures/party.golden.json create mode 100644 packages/partyos/tests/golden.test.ts diff --git a/packages/partyos/tests/fixtures/party.golden.json b/packages/partyos/tests/fixtures/party.golden.json new file mode 100644 index 0000000..b5c6638 --- /dev/null +++ b/packages/partyos/tests/fixtures/party.golden.json @@ -0,0 +1,73 @@ +{ + "source": "misofm/sdks@56af6a7bdb3b1581c6d72be18ac1bcfcefb7c046", + "vectors": [ + { + "name": "individual-mainnet", + "network": "mainnet", + "kind": "individual", + "partyName": "Miso", + "recipient": "0x00000000000000000000000000000000000000000000000000000000000a11ce", + "sender": "0x00000000000000000000000000000000000000000000000000000000000a11ce", + "sponsor": "0x0000000000000000000000000000000000000000000000000000000000005905", + "gasPrice": "500", + "gasBudget": "50000000", + "minEpoch": "1274", + "maxEpoch": "1275", + "nonce": 7, + "chain": "4btiuiMPvEENsttpZC7CZ53DruC3MAgfznDbASZ7DR6S", + "transaction": "AAADAAUETWlzbwEBAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAYBAAAAAAAAAAAAIAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAChHOBACGJUAGObA7yxZHhyHR1pkqcZ8jAAC/zuQm9cdg4IKxcwVwYXJ0eRNuZXdfaW5kaXZpZHVhbF9raW5kAAAAhiVABjmwO8sWR4ch0daZKnGfIwAAv87kJvXHYOCCsXMFcGFydHkDbmV3AAMCAAABAAABAQAAhiVABjmwO8sWR4ch0daZKnGfIwAAv87kJvXHYOCCsXMFcGFydHkFc2hhcmUAAgMBAAAAAwEAAQABAQMBAAEAAQIAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAKEc4AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAWQX0AQAAAAAAAIDw+gIAAAAAAgH6BAAAAAAAAAH7BAAAAAAAAAAAIDWDSorBfKSPsUrI+ZwXyYdH6V3QcpSuQaRrOCJGpEmbBwAAAA==", + "digest": "5ERHAdYY6ns1JHq7sfJ8iwaya4ejMdq93A9LrVPExDEb" + }, + { + "name": "group-testnet", + "network": "testnet", + "kind": "group", + "partyName": "The Band", + "recipient": "0x0000000000000000000000000000000000000000000000000000000000000b0b", + "sender": "0x00000000000000000000000000000000000000000000000000000000000a11ce", + "sponsor": "0x0000000000000000000000000000000000000000000000000000000000005905", + "gasPrice": "1000", + "gasBudget": "50000000", + "minEpoch": "900", + "maxEpoch": "901", + "nonce": 4294967295, + "chain": "69WiPg3DAQiwdxfncX6wYQ2siKwAe6L9BZthQea3JNMD", + "transaction": "AAADAAkIVGhlIEJhbmQBAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAGAQAAAAAAAAAAACAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAALCwQAQZOuVPqZFzC5fMMiqiEM5ucJb+Ll1qtxeiZ+F5GAPucFcGFydHkObmV3X2dyb3VwX2tpbmQAAABBk65U+pkXMLl8wyKqIQzm5wlv4uXWq3F6Jn4XkYA+5wVwYXJ0eQNuZXcAAwIAAAEAAAEBAABBk65U+pkXMLl8wyKqIQzm5wlv4uXWq3F6Jn4XkYA+5wVwYXJ0eQVzaGFyZQACAwEAAAADAQABAAEBAwEAAQABAgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAoRzgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAABZBegDAAAAAAAAgPD6AgAAAAACAYQDAAAAAAAAAYUDAAAAAAAAAAAgTHitrPKi9a2A8n7X1UqmnTp48cpn/e+ez1dU9bi7d7D/////", + "digest": "3cxVKHXF6bD19YencfwYxEyEJyMf96eTaZ482488MeAj" + }, + { + "name": "unicode-name", + "network": "mainnet", + "kind": "individual", + "partyName": "ミソ 🎵 Café", + "recipient": "0x00000000000000000000000000000000000000000000000000000000000a11ce", + "sender": "0x00000000000000000000000000000000000000000000000000000000000a11ce", + "sponsor": "0x0000000000000000000000000000000000000000000000000000000000005905", + "gasPrice": "500", + "gasBudget": "50000000", + "minEpoch": "1274", + "maxEpoch": "1275", + "nonce": 0, + "chain": "4btiuiMPvEENsttpZC7CZ53DruC3MAgfznDbASZ7DR6S", + "transaction": "AAADABIR44Of44K9IPCfjrUgQ2Fmw6kBAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAGAQAAAAAAAAAAACAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAoRzgQAhiVABjmwO8sWR4ch0daZKnGfIwAAv87kJvXHYOCCsXMFcGFydHkTbmV3X2luZGl2aWR1YWxfa2luZAAAAIYlQAY5sDvLFkeHIdHWmSpxnyMAAL/O5Cb1x2DggrFzBXBhcnR5A25ldwADAgAAAQAAAQEAAIYlQAY5sDvLFkeHIdHWmSpxnyMAAL/O5Cb1x2DggrFzBXBhcnR5BXNoYXJlAAIDAQAAAAMBAAEAAQEDAQABAAECAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAChHOAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAFkF9AEAAAAAAACA8PoCAAAAAAIB+gQAAAAAAAAB+wQAAAAAAAAAACA1g0qKwXykj7FKyPmcF8mHR+ld0HKUrkGkazgiRqRJmwAAAAA=", + "digest": "ExQDWkYTgTC8gaJMcTpAjjhEd3KJzM739bQPWPDcQBXM" + }, + { + "name": "max-length-name", + "network": "mainnet", + "kind": "individual", + "partyName": "xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx", + "recipient": "0x00000000000000000000000000000000000000000000000000000000000a11ce", + "sender": "0x00000000000000000000000000000000000000000000000000000000000a11ce", + "sponsor": "0x0000000000000000000000000000000000000000000000000000000000005905", + "gasPrice": "500", + "gasBudget": "50000000", + "minEpoch": "1274", + "maxEpoch": "1275", + "nonce": 1, + "chain": "4btiuiMPvEENsttpZC7CZ53DruC3MAgfznDbASZ7DR6S", + "transaction": "AAADAMoByAF4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eHh4eAEBAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAYBAAAAAAAAAAAAIAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAChHOBACGJUAGObA7yxZHhyHR1pkqcZ8jAAC/zuQm9cdg4IKxcwVwYXJ0eRNuZXdfaW5kaXZpZHVhbF9raW5kAAAAhiVABjmwO8sWR4ch0daZKnGfIwAAv87kJvXHYOCCsXMFcGFydHkDbmV3AAMCAAABAAABAQAAhiVABjmwO8sWR4ch0daZKnGfIwAAv87kJvXHYOCCsXMFcGFydHkFc2hhcmUAAgMBAAAAAwEAAQABAQMBAAEAAQIAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAKEc4AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAWQX0AQAAAAAAAIDw+gIAAAAAAgH6BAAAAAAAAAH7BAAAAAAAAAAAIDWDSorBfKSPsUrI+ZwXyYdH6V3QcpSuQaRrOCJGpEmbAQAAAA==", + "digest": "4P4vv92D6vWkKA2dAzUobusvdFdZctSnxF7NAPFUF78o" + } + ] +} diff --git a/packages/partyos/tests/golden.test.ts b/packages/partyos/tests/golden.test.ts new file mode 100644 index 0000000..fac7651 --- /dev/null +++ b/packages/partyos/tests/golden.test.ts @@ -0,0 +1,81 @@ +// Copyright (c) Miso Labs, Inc. +// SPDX-License-Identifier: Apache-2.0 + +// Golden vectors for the two party-creation recipes, built fully offline: +// no client, no network, no object resolution. `fixtures/party.golden.json` +// holds the exact sponsored TransactionData bytes and digests that +// `createIndividualParty` / `createGroupParty` produced at +// misofm/sdks@56af6a7 (the last release on the rc.112 stack); this test pins +// that the Effect 4.0.3 port builds byte-identical transactions, so a consumer +// that reproduces them in another language (the Rust platform, platform-ts) +// keeps matching. + +import { Transaction } from "@mysten/sui/transactions"; +import { toBase64 } from "@mysten/sui/utils"; +import { describe, expect, test } from "bun:test"; +import { PARTYOS_DEPLOYMENTS } from "../src/deployments.ts"; +import { createGroupParty, createIndividualParty } from "../src/transactions.ts"; +import golden from "./fixtures/party.golden.json" with { type: "json" }; + +interface Vector { + readonly name: string; + readonly network: "mainnet" | "testnet"; + readonly kind: "individual" | "group"; + readonly partyName: string; + readonly recipient: string; + readonly sender: string; + readonly sponsor: string; + readonly gasPrice: string; + readonly gasBudget: string; + readonly minEpoch: string; + readonly maxEpoch: string; + readonly nonce: number; + readonly chain: string; + readonly transaction: string; + readonly digest: string; +} + +const vectors = golden.vectors as readonly Vector[]; + +const build = (v: Vector): Transaction => { + const tx = new Transaction(); + const partyPackageId = PARTYOS_DEPLOYMENTS[v.network].partyos; + const params = { name: v.partyName, recipient: v.recipient, partyPackageId }; + (v.kind === "individual" ? createIndividualParty(params) : createGroupParty(params))(tx); + tx.setSender(v.sender); + tx.setGasOwner(v.sponsor); + tx.setGasPrice(v.gasPrice); + tx.setGasBudget(v.gasBudget); + tx.setGasPayment([]); + tx.setExpiration({ + ValidDuring: { + minEpoch: v.minEpoch, + maxEpoch: v.maxEpoch, + minTimestamp: null, + maxTimestamp: null, + chain: v.chain, + nonce: v.nonce, + }, + }); + return tx; +}; + +describe("party recipes: golden vectors", () => { + test("the fixture carries all four vectors", () => { + expect(vectors.map((v) => v.name)).toEqual([ + "individual-mainnet", + "group-testnet", + "unicode-name", + "max-length-name", + ]); + }); + + for (const v of vectors) { + test(`${v.name}: bytes and digest are identical, built offline`, async () => { + const tx = build(v); + const bytes = await tx.build(); + expect(toBase64(bytes)).toBe(v.transaction); + expect(await tx.getDigest()).toBe(v.digest); + }); + } +}); From 080c6739e4048b41894b48c3eab6cc002bc8ec74 Mon Sep 17 00:00:00 2001 From: BL Date: Tue, 13 Oct 2026 06:46:46 +0000 Subject: [PATCH 3/4] docs: changelogs and migration notes for the Effect 4.0.3 releases Adds a CHANGELOG.md to each ported package (shipped in the tarball) with the breaking peer changes, the behaviour changes that come with Effect 4.0.x and sui-effect 0.3.0, and a consumer migration note; updates the README peer lists, the musicos LLMS.md Config name and the Effect conventions. Co-Authored-By: Claude Sonnet 5.5 --- CLAUDE.md | 4 +- README.md | 5 ++- packages/musicos/CHANGELOG.md | 63 ++++++++++++++++++++++++++ packages/musicos/LLMS.md | 2 +- packages/musicos/README.md | 2 +- packages/partyos/CHANGELOG.md | 74 +++++++++++++++++++++++++++++++ packages/partyos/README.md | 6 +-- packages/platform/CHANGELOG.md | 73 ++++++++++++++++++++++++++++++ packages/platform/README.md | 4 +- packages/streaming/CHANGELOG.md | 37 ++++++++++++++++ packages/transcoding/CHANGELOG.md | 47 ++++++++++++++++++++ 11 files changed, 307 insertions(+), 10 deletions(-) create mode 100644 packages/musicos/CHANGELOG.md create mode 100644 packages/partyos/CHANGELOG.md create mode 100644 packages/platform/CHANGELOG.md create mode 100644 packages/streaming/CHANGELOG.md create mode 100644 packages/transcoding/CHANGELOG.md diff --git a/CLAUDE.md b/CLAUDE.md index 40cb127..74081ce 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -70,7 +70,9 @@ opinion Miso's product adds on top — including every `party_*` extension — i ## Effect conventions -- Effect v4 release candidate, pinned exactly (see any package's `peerDependencies`). Read +- Stable Effect v4 (`>=4.0.3 <4.1`; see any package's `peerDependencies`). Move `effect` and every + `@effect/*` package together. `@misofm/effect` is the exception: deprecated and frozen on + `4.0.0-rc.112`, outside the release train. Read `node_modules/effect/AGENTS.md` and `ai-docs/` before writing Effect code; v4 is not v3. - I/O returns `Effect` with `SuiClient` (from `@misofm/effect`) in the requirements; client extension classes provide the layer internally. PTB builders stay synchronous. diff --git a/README.md b/README.md index 5efe89a..813a4ed 100644 --- a/README.md +++ b/README.md @@ -41,8 +41,9 @@ submissions return `Effect` values that require the `SuiClient` service from `@misofm/effect` and fail with tagged errors (`Effect.catchTag`); the client extensions (`miso()`, `partyos()`, `misoPlatform()`) provide that service themselves so their methods have no requirements; PTB builders stay synchronous. -Each package's `./errors` subpath lists its failures. Pin `effect` to the exact -release candidate the packages peer on. +Each package's `./errors` subpath lists its failures. The packages peer on +stable Effect `>=4.0.3 <4.1` (and `@unconfirmed/sui-effect` `>=0.3.0 <0.4.0`); install +`effect` and every `@effect/*` package at the same `4.0.x`. ## Development diff --git a/packages/musicos/CHANGELOG.md b/packages/musicos/CHANGELOG.md new file mode 100644 index 0000000..29592bb --- /dev/null +++ b/packages/musicos/CHANGELOG.md @@ -0,0 +1,63 @@ +# Changelog + +All notable changes to `@misofm/musicos`, newest first. + +## 0.8.0 + +Moves the package from Effect `4.0.0-rc.112` to stable Effect `4.0.3` and +`@unconfirmed/sui-effect` `0.3.0`. The public API is unchanged: no export was added, +removed or re-typed (the built `.d.ts` files are identical to 0.7.1), and no contract +binding changed. + +### Changed (breaking) + +- **Peer `effect` is now `>=4.0.3 <4.1`** (was `>=4.0.0-rc.112 <4.1`). Release candidates are + no longer supported; stay on 0.7.x for `effect@4.0.0-rc.112`. +- **Peer `@unconfirmed/sui-effect` is now `>=0.3.0 <0.4.0`** (was `>=0.1.0 <0.3.0`). + Dev dependencies move to `effect@4.0.3` and `@unconfirmed/sui-effect@0.3.0`. +- Peers `@mysten/sui` (`^2.28`) and `@mysten/bcs` (`^2.1.1`) are unchanged. + +### Internal + +- `Musicos.layerConfig` uses `Config.NonEmptyString` (rc.113 renamed the `Config` + constructors to PascalCase; `Config.nonEmptyString` does not exist on 4.0.x). + Behaviour is unchanged: `MUSICOS_PACKAGE_ID` unset or empty falls back to the bundled + manifest, a set value overrides it (checked against rc.112 and 4.0.3 with the same + `ConfigProvider`). +- Docs: `LLMS.md` and `README.md` name the new peer ranges. + +### Behaviour changes to be aware of (from Effect 4.0.x and sui-effect 0.3.0) + +None changes a type, a stored byte or a transaction. Audit of this package: it uses no +`partition`/`separate`, no `Effect.timeout`, no `Effect.retry`, no `Schema.brand`, no +`Encoding`; the `Config` rename above is the only source change. + +- `Effect.retry` semantics (Effect 4.0.2): a typed failure accompanied by a defect or an + interruption in the same `Cause` is no longer retried. This package passes no retry + schedule of its own; the retry policies it inherits come from `sui-effect` and retry + only the typed, retryable `TransportError`. +- `TimeoutError` now has a message (`Operation timed out after ''`; rc.112's was + empty). It reaches this package's callers only through `sui-effect` (`SuiError.describe`, + the journal's `lastError`); no text in this package matches on it. +- `ManagedRuntime.dispose` (the Promise face you get from `client.$extend(...)`) now + interrupts calls still in flight instead of letting them finish: await your calls + before disposing. +- `Cause.pretty` includes stack frames and `SchemaError` renders as JSON, so logged + error text is longer. The error classes' own `message`, `toString`, JSON and + `Schema` encode/decode output is byte-identical to the previous release (differential + check over every exported error class against the rc.112 build). + +### Migrating from 0.7.x + +1. Move the whole Effect release train to stable together: `effect@4.0.3` and every + `@effect/*` package you use at `4.0.3`. A mixed release-candidate and stable install + fails to resolve `effect/*` module paths, and two `effect` copies give the shared + `Context.Service` tags and tagged-error classes different identities. Pin `4.0.x` + explicitly (the `rc` dist-tag still points at a release candidate). +2. Move `@unconfirmed/sui-effect` to `0.3.0` (its own CHANGELOG has the full migration). +3. Nothing to change in code that imports from `@misofm/musicos`; update your own rc + imports (`effect/unstable/*` is now `effect/*`) and renames (Effect's `MIGRATION.md`, + "Effect v4 release candidates to 4.0.x"). +4. Review `partition`/`separate` destructuring in your own code: Effect 4.0.x returns + `[successes, failures]` (rc: `[failures, successes]`), which compiles either way when + both sides have the same type. diff --git a/packages/musicos/LLMS.md b/packages/musicos/LLMS.md index 6f99a57..5c685d9 100644 --- a/packages/musicos/LLMS.md +++ b/packages/musicos/LLMS.md @@ -24,7 +24,7 @@ The Miso object-model service. `layer(options)` uses `options.deployment` when given; otherwise it reads `sui.network` and picks this release's bundled manifest (`MISO_DEPLOYMENTS`), failing `MusicosDeploymentInvalid` when there is none. `layerConfig` is the same layer with `MUSICOS_PACKAGE_ID` -(`Config.nested("MUSICOS")`, `Config.nonEmptyString("PACKAGE_ID")`) +(`Config.nested("MUSICOS")`, `Config.NonEmptyString("PACKAGE_ID")`) overriding the bundled choice. `layerTest` is the real service over a fixed (or given) test package id — compose it with `layerExtensionTest` from `@unconfirmed/sui-effect/testing`. diff --git a/packages/musicos/README.md b/packages/musicos/README.md index a619f4f..482c3fe 100644 --- a/packages/musicos/README.md +++ b/packages/musicos/README.md @@ -22,7 +22,7 @@ in this codebase follows. bun add @misofm/musicos @unconfirmed/sui-effect effect @mysten/sui @mysten/bcs ``` -Peer dependencies: `@unconfirmed/sui-effect@^0.1.0`, `effect@>=4.0.0-rc.112 <4.1`, +Peer dependencies: `@unconfirmed/sui-effect@>=0.3.0 <0.4.0`, `effect@>=4.0.3 <4.1`, `@mysten/sui@^2.28`, `@mysten/bcs@^2.1.1`. ## Usage diff --git a/packages/partyos/CHANGELOG.md b/packages/partyos/CHANGELOG.md new file mode 100644 index 0000000..fc4d664 --- /dev/null +++ b/packages/partyos/CHANGELOG.md @@ -0,0 +1,74 @@ +# Changelog + +All notable changes to `@misofm/partyos`, newest first. + +## 0.8.0 + +Moves the package from Effect `4.0.0-rc.112` to stable Effect `4.0.3` and +`@unconfirmed/sui-effect` `0.3.0`, and loosens two peer ranges so one copy of each Sui +library is installed. The public API is unchanged: every export, including the +`createIndividualParty` / `createGroupParty` recipes, `PARTYOS_DEPLOYMENTS`, +`getPartyDeployment` and `partyEventParsers`, keeps its name and signature (the built +`.d.ts` files are identical to 0.7.1), and no contract binding changed. + +### Changed (breaking) + +- **Peer `effect` is now `>=4.0.3 <4.1`** (was exactly `4.0.0-rc.112`). Release candidates are + no longer supported; stay on 0.7.x for `effect@4.0.0-rc.112`. +- **Peer `@unconfirmed/sui-effect` is now `>=0.3.0 <0.4.0`** (was `>=0.1.0 <0.3.0`). +- **`@mysten/bcs` moved from `dependencies` to a peer, `^2.1.1`** (as `sui-effect` and + `@misofm/musicos` have it), so a consumer installs one copy. Install it next to + `@mysten/sui` if your package manager does not install peers automatically. +- **Peer `@mysten/sui` is widened from exactly `2.29.0` to `^2.29.0`.** Development stays + pinned to `2.29.0`. + +### Added + +- `tests/golden.test.ts` builds both party-creation recipes fully offline (no client, no + network) for four sponsored vectors (mainnet individual, testnet group, a Unicode name, + a maximum-length name) and asserts the TransactionData bytes and digests equal + `tests/fixtures/party.golden.json`, generated by 0.7.1 on the rc.112 stack. The 0.8.0 + recipes are byte-identical to 0.7.1's. + +### Internal + +- `Partyos.layerConfig` uses `Config.NonEmptyString` (rc.113 renamed the `Config` + constructors to PascalCase). Behaviour is unchanged: `PARTYOS_PACKAGE_ID` unset or empty + falls back to the bundled manifest, a set value overrides it. +- README install line and peer list updated. + +### Behaviour changes to be aware of (from Effect 4.0.x and sui-effect 0.3.0) + +None changes a type, a stored byte or a transaction. Audit of this package: it uses no +`partition`/`separate`, no `Effect.timeout`, no `Effect.retry`, no `Schema.brand`, no +`Encoding`; the `Config` rename above is the only source change. + +- `Effect.retry` semantics (Effect 4.0.2): a typed failure accompanied by a defect or an + interruption in the same `Cause` is no longer retried. This package passes no retry + schedule of its own; the retry policies it inherits come from `sui-effect` and retry + only the typed, retryable `TransportError`. +- `TimeoutError` now has a message (`Operation timed out after ''`; rc.112's was + empty). It reaches this package's callers only through `sui-effect` (`SuiError.describe`, + the journal's `lastError`); no text in this package matches on it. +- `ManagedRuntime.dispose` (the Promise face you get from `client.$extend(...)`) now + interrupts calls still in flight instead of letting them finish: await your calls + before disposing. +- `Cause.pretty` includes stack frames and `SchemaError` renders as JSON, so logged + error text is longer. The error classes' own `message`, `toString`, JSON and + `Schema` encode/decode output is byte-identical to the previous release (differential + check over every exported error class against the rc.112 build). + +### Migrating from 0.7.x + +1. Move the whole Effect release train to stable together: `effect@4.0.3` and every + `@effect/*` package you use at `4.0.3`. A mixed release-candidate and stable install + fails to resolve `effect/*` module paths, and two `effect` copies give the shared + `Context.Service` tags and tagged-error classes different identities. Pin `4.0.x` + explicitly (the `rc` dist-tag still points at a release candidate). +2. Move `@unconfirmed/sui-effect` to `0.3.0` (its own CHANGELOG has the full migration). +3. Add `@mysten/bcs@^2.1.1` to your dependencies if it is not already installed (it was a + bundled dependency; it is now a peer). Keep one copy. +4. `@mysten/sui` may now be any `^2.29.0` (it had to be exactly `2.29.0`). +5. Update your own rc imports (`effect/unstable/*` is now `effect/*`) and renames + (Effect's `MIGRATION.md`, "Effect v4 release candidates to 4.0.x"). Review + `partition`/`separate` destructuring: 4.0.x returns `[successes, failures]`. diff --git a/packages/partyos/README.md b/packages/partyos/README.md index 645f9be..2736aeb 100644 --- a/packages/partyos/README.md +++ b/packages/partyos/README.md @@ -16,11 +16,11 @@ this package. Which Move package generates into which SDK is decided by ## Install ```sh -bun add @misofm/partyos @unconfirmed/sui-effect effect @mysten/sui +bun add @misofm/partyos @unconfirmed/sui-effect effect @mysten/sui @mysten/bcs ``` -`@unconfirmed/sui-effect`, `@mysten/sui` and `effect` (exactly `4.0.0-rc.112`) are peer -dependencies. +Peer dependencies: `@unconfirmed/sui-effect@>=0.3.0 <0.4.0`, `effect@>=4.0.3 <4.1`, +`@mysten/sui@^2.29.0`, `@mysten/bcs@^2.1.1`. ## Use diff --git a/packages/platform/CHANGELOG.md b/packages/platform/CHANGELOG.md new file mode 100644 index 0000000..ddea46f --- /dev/null +++ b/packages/platform/CHANGELOG.md @@ -0,0 +1,73 @@ +# Changelog + +All notable changes to `@misofm/platform`, newest first. + +## 0.46.0 + +Moves the package from Effect `4.0.0-rc.112` to stable Effect `4.0.3` and +`@unconfirmed/sui-effect` `0.3.0`, on top of `@misofm/musicos` 0.8.0, `@misofm/partyos` +0.8.0 and `@misofm/streaming` 0.4.0. The public API is unchanged: no export was added, +removed or re-typed (the built `.d.ts` files are identical to 0.45.0), and no contract +binding changed. + +### Changed (breaking) + +- **Peer `effect` is now `>=4.0.3 <4.1`** (was exactly `4.0.0-rc.112`). Release candidates are + no longer supported; stay on 0.45.x for `effect@4.0.0-rc.112`. +- **Peer `@unconfirmed/sui-effect` is now `>=0.3.0 <0.4.0`** (was `>=0.1.0 <0.3.0`). +- **`@mysten/bcs` moved from `dependencies` to a peer, `^2.1.1`**, so a consumer installs + one copy shared with `sui-effect`, `@misofm/musicos` and `@misofm/partyos`. +- **Peer `@mysten/sui` is widened from exactly `2.29.0` to `^2.29.0`.** Development stays + pinned to `2.29.0`. +- Dependencies `@misofm/musicos` and `@misofm/partyos` move to `0.8.0` and + `@misofm/streaming` to `0.4.0` (all exact, as before). + +### Internal + +- `Miso.layerConfig` uses `Config.NonEmptyString` (rc.113 renamed the `Config` + constructors to PascalCase). `MISO_NETWORK` unset or empty still falls back to + `sui.network`. +- The isolated-consumer fixture no longer includes the deprecated `@misofm/effect` (it + stays on `effect@4.0.0-rc.112` and cannot share an install with this package); it also + asserts a single `@mysten/bcs`. `tests/dependency-contract.test.ts` pins the new peer + ranges. + +### Behaviour changes to be aware of (from Effect 4.0.x and sui-effect 0.3.0) + +None changes a type, a stored byte or a transaction. Audit of this package: it uses no +`partition`/`separate`, no `Effect.timeout`, no `Effect.retry`, no `Schema.brand`, no +`Encoding`. `Effect.orElseSucceed(() => null)` in `auth.ts` (the response-body fallback) +ignores the error argument that 4.0.x now passes, so it behaves as before. + +- `Effect.retry` semantics (Effect 4.0.2): a typed failure accompanied by a defect or an + interruption in the same `Cause` is no longer retried. This package passes no retry + schedule of its own; the retry policies it inherits come from `sui-effect` and retry + only the typed, retryable `TransportError`. +- `TimeoutError` now has a message (`Operation timed out after ''`; rc.112's was + empty). It reaches this package's callers only through `sui-effect` (`SuiError.describe`, + the journal's `lastError`); no text in this package matches on it. +- `ManagedRuntime.dispose` (the Promise face you get from `client.$extend(...)`) now + interrupts calls still in flight instead of letting them finish: await your calls + before disposing. +- `Cause.pretty` includes stack frames and `SchemaError` renders as JSON, so logged + error text is longer. The error classes' own `message`, `toString`, JSON and + `Schema` encode/decode output is byte-identical to the previous release (differential + check over every exported error class against the rc.112 build). + +### Migrating from 0.45.x + +1. Move the whole Effect release train to stable together: `effect@4.0.3` and every + `@effect/*` package you use at `4.0.3`. A mixed release-candidate and stable install + fails to resolve `effect/*` module paths, and two `effect` copies give the shared + `Context.Service` tags and tagged-error classes different identities. Pin `4.0.x` + explicitly (the `rc` dist-tag still points at a release candidate). +2. Move `@unconfirmed/sui-effect` to `0.3.0` (its own CHANGELOG has the full migration). +3. Add `@mysten/bcs@^2.1.1` to your dependencies if it is not already installed (it was a + bundled dependency; it is now a peer). +4. `@mysten/sui` may now be any `^2.29.0`. +5. Update your own rc imports (`effect/unstable/*` is now `effect/*`) and renames + (Effect's `MIGRATION.md`). Review `partition`/`separate` destructuring: 4.0.x returns + `[successes, failures]`. +6. Install `@misofm/musicos` 0.8.0, `@misofm/partyos` 0.8.0 and `@misofm/streaming` 0.4.0 + only through this package (they resolve transitively); a second copy at another version + gives two sets of tagged-error classes. diff --git a/packages/platform/README.md b/packages/platform/README.md index 96f098c..6a5d5b6 100644 --- a/packages/platform/README.md +++ b/packages/platform/README.md @@ -66,8 +66,8 @@ just crossing a package boundary. bun add @misofm/platform @unconfirmed/sui-effect effect @mysten/sui @mysten/bcs ``` -Peer dependencies: `@unconfirmed/sui-effect@^0.1.0`, `effect@>=4.0.0-rc.112 <4.1`, -`@mysten/sui@^2.28`, `@mysten/bcs@^2.1.1`. `@misofm/musicos` and +Peer dependencies: `@unconfirmed/sui-effect@>=0.3.0 <0.4.0`, `effect@>=4.0.3 <4.1`, +`@mysten/sui@^2.29.0`, `@mysten/bcs@^2.1.1`. `@misofm/musicos` and `@misofm/partyos` resolve transitively through this package, so applications get exactly one object-model SDK, one Party-identity SDK, and one compatible deployment map without installing either themselves. A custom deployment is diff --git a/packages/streaming/CHANGELOG.md b/packages/streaming/CHANGELOG.md new file mode 100644 index 0000000..194e05c --- /dev/null +++ b/packages/streaming/CHANGELOG.md @@ -0,0 +1,37 @@ +# Changelog + +All notable changes to `@misofm/streaming`, newest first. + +## 0.4.0 + +Moves the package from Effect `4.0.0-rc.112` to stable Effect `4.0.3`. The public API and +the `miso-hls/v1` contract are unchanged: no export was added, removed or re-typed (the +built `.d.ts` files are identical to 0.3.0), and the source needed no change. + +### Changed (breaking) + +- **Peer `effect` is now `>=4.0.3 <4.1`** (was exactly `4.0.0-rc.112`). Release candidates are + no longer supported; stay on 0.3.x for `effect@4.0.0-rc.112`. The optional `hls.js` peer + (`^1.6`) is unchanged. + +### Behaviour changes to be aware of (from Effect 4.0.x) + +Audit of this package: it uses `Effect.acquireRelease` / `Effect.scoped` (`acquirePlayer`), +`Fiber.interrupt` (warm-up cancellation) and `Schema.TaggedError` errors, and no +`partition`, `Effect.retry`, `Effect.timeout` or `Stream` operator. The tests that cover +release-on-scope-close, interruption aborting every in-flight fetch, and the error classes +pass unchanged. The error classes' `message`, JSON and `Schema` encode/decode output is +byte-identical to 0.3.0. + +- `Scope.close` finalizers (so `acquirePlayer`'s release) run uninterruptibly in Effect + 4.0.x; the release only detaches hls.js and clears the media element, so this is + unobservable here. +- `Cause.pretty` includes stack frames and `SchemaError` renders as JSON, so logged error + text is longer. + +### Migrating from 0.3.x + +1. Move the whole Effect release train to stable together (`effect@4.0.3`, every `@effect/*` + package at `4.0.3`). Pin `4.0.x` explicitly; the `rc` dist-tag still points at a + release candidate. +2. Nothing to change in code that imports from `@misofm/streaming`. diff --git a/packages/transcoding/CHANGELOG.md b/packages/transcoding/CHANGELOG.md new file mode 100644 index 0000000..2260080 --- /dev/null +++ b/packages/transcoding/CHANGELOG.md @@ -0,0 +1,47 @@ +# Changelog + +All notable changes to `@misofm/transcoding`, newest first. + +## 0.5.0 + +Moves the package from Effect `4.0.0-rc.112` to stable Effect `4.0.3` and +`@effect/platform-node` `4.0.3`, on top of `@misofm/streaming` 0.4.0. The public API and the +transcode output are unchanged: no export was added, removed or re-typed (the built `.d.ts` +files are identical to 0.4.0), the source needed no change, and the pinned-FFmpeg golden +and the cancellation test produce the same results. + +### Changed (breaking) + +- **Peers `effect` and `@effect/platform-node` are now `>=4.0.3 <4.1`** (were exactly + `4.0.0-rc.112`). Release candidates are no longer supported; stay on 0.4.x for + `effect@4.0.0-rc.112`. Move both packages together: a mixed install fails to resolve. +- Dependency `@misofm/streaming` moves to `0.4.0` (exact, as before). + +### Behaviour changes to be aware of (from Effect 4.0.x) + +Audit of this package: it uses no `partition`, `Effect.retry`, `Effect.timeout`, `Stream` +operator or `Schema`; its errors are `Data.TaggedError`s. It does depend on interruption +semantics (`Effect.uninterruptible`, `Effect.acquireUseRelease` for the workspace lock, +`Effect.onError` cleanup, `Fiber.interrupt` of a running transcode), which 4.0.x changed: + +- Pending interruptions are preserved when an uninterruptible effect fails, and typed + failures are dropped (defects kept) when an interruption skips recovery handlers + (Effect #8652). +- `Effect.acquireUseRelease` releases the resource when the `use` callback throws + synchronously (Effect #8020); `Scope.close` finalizers run uninterruptibly. +- Sibling and cleanup failures are kept alongside interruption in `Effect.forEach` + (Effect #8585). + +The ffmpeg integration test (cancel a running transcode, then acquire the workspace lock; +byte-golden artifacts under the pinned FFmpeg) passes on both the rc.112 and the 4.0.3 +builds. If you wrap a transcode in your own `Effect.race`/timeout, note that losers that are +still starting are now interrupted. + +### Migrating from 0.4.x + +1. Move the whole Effect release train to stable together: `effect@4.0.3` and + `@effect/platform-node@4.0.3` (and any other `@effect/*` package). Pin `4.0.x` + explicitly; the `rc` dist-tag still points at a release candidate. +2. Nothing to change in code that imports from `@misofm/transcoding`. +3. Review `partition`/`separate` destructuring in your own code: 4.0.x returns + `[successes, failures]`. From aada49ba8968784d509846f95bccc6073bacc2ef Mon Sep 17 00:00:00 2001 From: BL Date: Tue, 13 Oct 2026 07:04:58 +0000 Subject: [PATCH 4/4] Move the Effect train to 4.0.4; correct changelogs; add a @mysten/sui matrix - dev pins effect and @effect/platform-node to 4.0.4 (peer ranges stay >=4.0.3 <4.1): @effect/platform-node@4.0.3 pulls @effect/platform-node-shared ^4.0.3, which resolves to 4.0.4 and peers effect ^4.0.4, so a 4.0.3 pin was an invalid peer tree. Both isolated consumers now install with --strict-peer-deps and run npm ls - CHANGELOGs: tell consumers to pin the whole train to one 4.0.x (show 4.0.4); replace the incorrect ManagedRuntime.dispose and Cause.pretty notes with the real changes (Effect #8528, #8512, #8783, #8895); note the bcs peer is type-only - CI: sui-matrix job runs partyos, musicos and platform typecheck and tests against @mysten/sui 2.29.0 and 2.30.0 (scripts/use-sui-version.ts); the dependency-contract test takes the dev version from MISO_SUI_VERSION and asserts the peer range admits it - docs: fix the stale SuiClient/@misofm/effect lines in CLAUDE.md and README Co-Authored-By: Claude Sonnet 5.5 --- .github/workflows/ci.yml | 29 ++++++++++++++ CLAUDE.md | 6 ++- README.md | 9 +++-- bun.lock | 30 +++++++------- packages/musicos/CHANGELOG.md | 34 ++++++++++------ packages/musicos/package.json | 2 +- packages/partyos/CHANGELOG.md | 34 ++++++++++------ packages/partyos/package.json | 2 +- packages/partyos/tests/golden.test.ts | 2 +- packages/platform/CHANGELOG.md | 34 ++++++++++------ packages/platform/package.json | 2 +- .../tests/dependency-contract.test.ts | 15 ++++--- .../fixtures/isolated-consumer/package.json | 4 +- .../fixtures/isolated-consumer/verify.mjs | 6 ++- packages/streaming/CHANGELOG.md | 20 +++++++--- packages/streaming/package.json | 2 +- packages/transcoding/CHANGELOG.md | 19 ++++++--- packages/transcoding/package.json | 4 +- .../transcoding/test/isolated-consumer.mjs | 10 +++-- scripts/check-consumer.ts | 6 ++- scripts/use-sui-version.ts | 39 +++++++++++++++++++ 21 files changed, 221 insertions(+), 88 deletions(-) create mode 100644 scripts/use-sui-version.ts diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index cf05821..887c340 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -35,6 +35,35 @@ jobs: echo "::endgroup::" done + # The object-model SDKs peer on `@mysten/sui ^2.29.0` but are developed + # against the exact 2.29.0 pin. Run their typecheck and tests against the + # pin and the next release inside the range, so a widened peer is proven, + # not assumed. The lockfile is deliberately not frozen here: the script + # rewrites the dev pins first. + sui-matrix: + runs-on: ubuntu-latest + strategy: + fail-fast: false + matrix: + sui: ["2.29.0", "2.30.0"] + steps: + - uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4.4.0 + - uses: oven-sh/setup-bun@0c5077e51419868618aeaa5fe8019c62421857d6 # v2.2.0 + with: + bun-version: 1.4.0 + - name: Pin @mysten/sui ${{ matrix.sui }} + run: bun scripts/use-sui-version.ts ${{ matrix.sui }} + - name: Install dependencies + run: bun install + - name: Typecheck and test partyos, musicos, platform + env: + MISO_SUI_VERSION: ${{ matrix.sui }} + run: | + for pkg in partyos musicos platform; do + bun run --filter "@misofm/$pkg" typecheck + bun run --filter "@misofm/$pkg" test + done + # Packs every workspace package into a real tarball and installs them into # an isolated fixture consumer, then typechecks and runs it. Inside the # workspace every import resolves locally regardless of a package's diff --git a/CLAUDE.md b/CLAUDE.md index 74081ce..f5feabd 100644 --- a/CLAUDE.md +++ b/CLAUDE.md @@ -74,8 +74,10 @@ opinion Miso's product adds on top — including every `party_*` extension — i `@effect/*` package together. `@misofm/effect` is the exception: deprecated and frozen on `4.0.0-rc.112`, outside the release train. Read `node_modules/effect/AGENTS.md` and `ai-docs/` before writing Effect code; v4 is not v3. -- I/O returns `Effect` with `SuiClient` (from `@misofm/effect`) in the requirements; client - extension classes provide the layer internally. PTB builders stay synchronous. +- I/O returns `Effect` with `Sui` (from `@unconfirmed/sui-effect`; `Miso` also needs + `SuiGraphQL`) in the requirements; each service ships `layer`/`layerConfig`/`layerTest`, and + the derived Promise registrations (`musicos()`, `partyos()`, `miso()`) provide that service + themselves. PTB builders stay synchronous. - Failures are `Schema.TaggedError` classes in each package's `src/errors.ts` (`./errors` subpath); never throw strings or plain `Error` from public reads. - Domain types are `Schema.Class`; generated BCS shapes under `src/contracts/` never appear diff --git a/README.md b/README.md index 813a4ed..cf0b38b 100644 --- a/README.md +++ b/README.md @@ -37,10 +37,11 @@ see its `packages` list rather than looking for an enumeration here. ## Effect Every SDK exposes [Effect](https://effect.website) v4 in its public API: reads and -submissions return `Effect` values that require the `SuiClient` service from -`@misofm/effect` and fail with tagged errors (`Effect.catchTag`); the client -extensions (`miso()`, `partyos()`, `misoPlatform()`) provide that service -themselves so their methods have no requirements; PTB builders stay synchronous. +submissions return `Effect` values that require the `Sui` service from +[`@unconfirmed/sui-effect`](https://github.com/unconfirmedlabs/sui-effect) (`Miso` also +needs `SuiGraphQL`) and fail with tagged errors (`Effect.catchTag`); the Promise +registrations (`musicos()`, `partyos()`, `miso()`, used as `client.$extend(...)`) provide +that service themselves so their methods have no requirements; PTB builders stay synchronous. Each package's `./errors` subpath lists its failures. The packages peer on stable Effect `>=4.0.3 <4.1` (and `@unconfirmed/sui-effect` `>=0.3.0 <0.4.0`); install `effect` and every `@effect/*` package at the same `4.0.x`. diff --git a/bun.lock b/bun.lock index 635248f..aa25593 100644 --- a/bun.lock +++ b/bun.lock @@ -37,7 +37,7 @@ "@mysten/sui": "2.29.0", "@types/bun": "^1.4.0", "@unconfirmed/sui-effect": "0.3.0", - "effect": "4.0.3", + "effect": "4.0.4", "typedoc": "^0.28.20", "typedoc-plugin-markdown": "^4.13.0", "typescript": "^7.0.2", @@ -58,7 +58,7 @@ "@mysten/sui": "2.29.0", "@types/bun": "^1.4.0", "@unconfirmed/sui-effect": "0.3.0", - "effect": "4.0.3", + "effect": "4.0.4", "typedoc": "^0.28.20", "typedoc-plugin-markdown": "^4.13.0", "typescript": "^7.0.2", @@ -85,7 +85,7 @@ "@mysten/sui": "2.29.0", "@types/bun": "^1.3.14", "@unconfirmed/sui-effect": "0.3.0", - "effect": "4.0.3", + "effect": "4.0.4", "typescript": "^7.0.2", }, "peerDependencies": { @@ -102,7 +102,7 @@ "version": "0.4.0", "devDependencies": { "@types/bun": "^1.4.0", - "effect": "4.0.3", + "effect": "4.0.4", "hls.js": "1.6.13", "typescript": "^7.0.2", }, @@ -122,10 +122,10 @@ "m3u8-parser": "7.2.0", }, "devDependencies": { - "@effect/platform-node": "4.0.3", + "@effect/platform-node": "4.0.4", "@types/bun": "1.2.22", "@types/node": "24.10.1", - "effect": "4.0.3", + "effect": "4.0.4", "hls.js": "1.6.13", "playwright": "1.55.0", "prettier": "3.6.2", @@ -146,7 +146,7 @@ "@effect/language-service": ["@effect/language-service@0.87.2", "", { "bin": { "effect-language-service": "cli.js" } }, "sha512-CfiSoaVQO8pZgaMZGw5VvMvRGybsJ2LaSDoLYaqiVGvo/YYPYVR2GzUKY0h1NtIweq/+SQ5XLrvtzPIttWQ0GQ=="], - "@effect/platform-node": ["@effect/platform-node@4.0.3", "", { "dependencies": { "@effect/platform-node-shared": "^4.0.3", "undici": "^8.11.2" }, "peerDependencies": { "effect": "^4.0.3", "redis": ">=5.0.0 <7.0.0" } }, "sha512-ctvREpC1EzRVsOm0JyIzYHajAQScFaec6Gl+M7TEIpEqdmmx6Ju11Um92EA/CE2KBfY5Fp1QWlqTkK6lOL7tqg=="], + "@effect/platform-node": ["@effect/platform-node@4.0.4", "", { "dependencies": { "@effect/platform-node-shared": "^4.0.4", "undici": "^8.11.2" }, "peerDependencies": { "effect": "^4.0.4", "redis": ">=5.0.0 <7.0.0" } }, "sha512-SdoyQMrO5zmqBebb2fxDk0sHYyJjBiw4QmLdV2ZcWf3ATpQPge3B5sTLijZg49PadekOwNeO83o5TfdtiiFEig=="], "@effect/platform-node-shared": ["@effect/platform-node-shared@4.0.4", "", { "dependencies": { "@types/ws": "^8.18.2", "ws": "^8.22.0" }, "peerDependencies": { "effect": "^4.0.4" } }, "sha512-gh2KRmqGWrJ0FVL8GqnI1GpB+fCfCUI7sGiUZkxxBHyHj1t94rm6VDJffCfuVZWe6GpvYXtizifVczUrgOce8A=="], @@ -386,21 +386,21 @@ "zod": ["zod@4.5.4", "", {}, "sha512-sC95tT5iHHH9gtpj6A81kh+NEaRAUFN+qlUPDUbRfOMvNf5QCBqsb3WgvnpVtK5Y+4UfA6KqufotuTvMGiTlsA=="], - "@effect/platform-node/effect": ["effect@4.0.3", "", {}, "sha512-LoWn/Uwwx0JjHSDmBAAahx8sB+klzM6vsZovnbYowBNw6B4QScJLRLBByO61plvNiycx7HPN8FnsWUCu0eXW5w=="], + "@effect/platform-node/effect": ["effect@4.0.4", "", {}, "sha512-Sr50OeVSC3M5UkoUYUhFf3EULryhGaZZUf6OzDHTvaznOw7HRlxOKdF3/4nvQXHL22StOyMG3Cvo8Bt7xUp+Ng=="], - "@effect/platform-node-shared/effect": ["effect@4.0.3", "", {}, "sha512-LoWn/Uwwx0JjHSDmBAAahx8sB+klzM6vsZovnbYowBNw6B4QScJLRLBByO61plvNiycx7HPN8FnsWUCu0eXW5w=="], + "@effect/platform-node-shared/effect": ["effect@4.0.4", "", {}, "sha512-Sr50OeVSC3M5UkoUYUhFf3EULryhGaZZUf6OzDHTvaznOw7HRlxOKdF3/4nvQXHL22StOyMG3Cvo8Bt7xUp+Ng=="], - "@misofm/musicos/effect": ["effect@4.0.3", "", {}, "sha512-LoWn/Uwwx0JjHSDmBAAahx8sB+klzM6vsZovnbYowBNw6B4QScJLRLBByO61plvNiycx7HPN8FnsWUCu0eXW5w=="], + "@misofm/musicos/effect": ["effect@4.0.4", "", {}, "sha512-Sr50OeVSC3M5UkoUYUhFf3EULryhGaZZUf6OzDHTvaznOw7HRlxOKdF3/4nvQXHL22StOyMG3Cvo8Bt7xUp+Ng=="], - "@misofm/partyos/effect": ["effect@4.0.3", "", {}, "sha512-LoWn/Uwwx0JjHSDmBAAahx8sB+klzM6vsZovnbYowBNw6B4QScJLRLBByO61plvNiycx7HPN8FnsWUCu0eXW5w=="], + "@misofm/partyos/effect": ["effect@4.0.4", "", {}, "sha512-Sr50OeVSC3M5UkoUYUhFf3EULryhGaZZUf6OzDHTvaznOw7HRlxOKdF3/4nvQXHL22StOyMG3Cvo8Bt7xUp+Ng=="], - "@misofm/platform/effect": ["effect@4.0.3", "", {}, "sha512-LoWn/Uwwx0JjHSDmBAAahx8sB+klzM6vsZovnbYowBNw6B4QScJLRLBByO61plvNiycx7HPN8FnsWUCu0eXW5w=="], + "@misofm/platform/effect": ["effect@4.0.4", "", {}, "sha512-Sr50OeVSC3M5UkoUYUhFf3EULryhGaZZUf6OzDHTvaznOw7HRlxOKdF3/4nvQXHL22StOyMG3Cvo8Bt7xUp+Ng=="], - "@misofm/streaming/effect": ["effect@4.0.3", "", {}, "sha512-LoWn/Uwwx0JjHSDmBAAahx8sB+klzM6vsZovnbYowBNw6B4QScJLRLBByO61plvNiycx7HPN8FnsWUCu0eXW5w=="], + "@misofm/streaming/effect": ["effect@4.0.4", "", {}, "sha512-Sr50OeVSC3M5UkoUYUhFf3EULryhGaZZUf6OzDHTvaznOw7HRlxOKdF3/4nvQXHL22StOyMG3Cvo8Bt7xUp+Ng=="], "@misofm/transcoding/@types/bun": ["@types/bun@1.2.22", "", { "dependencies": { "bun-types": "1.2.22" } }, "sha512-5A/KrKos2ZcN0c6ljRSOa1fYIyCKhZfIVYeuyb4snnvomnpFqC0tTsEkdqNxbAgExV384OETQ//WAjl3XbYqQA=="], - "@misofm/transcoding/effect": ["effect@4.0.3", "", {}, "sha512-LoWn/Uwwx0JjHSDmBAAahx8sB+klzM6vsZovnbYowBNw6B4QScJLRLBByO61plvNiycx7HPN8FnsWUCu0eXW5w=="], + "@misofm/transcoding/effect": ["effect@4.0.4", "", {}, "sha512-Sr50OeVSC3M5UkoUYUhFf3EULryhGaZZUf6OzDHTvaznOw7HRlxOKdF3/4nvQXHL22StOyMG3Cvo8Bt7xUp+Ng=="], "@misofm/transcoding/typescript": ["typescript@5.9.3", "", { "bin": { "tsc": "bin/tsc", "tsserver": "bin/tsserver" } }, "sha512-jl1vZzPDinLr9eUt3J/t7V6FgNEw9QjvBPdysz9KfQDD41fQrC2Y4vKQdiaUpFT4bXlb1RHhLpp8wtm6M5TgSw=="], @@ -412,7 +412,7 @@ "@types/ws/@types/node": ["@types/node@26.4.1", "", { "dependencies": { "undici-types": "~8.3.0" } }, "sha512-k97ENvZWtvA6yqz5/FS6a7duDgOPEeOQOc2iKS/nY6mX6qJUKtLnWzQS+Xj6tXweyj6ZcTAK2Qecetnvi9nCLA=="], - "@unconfirmed/sui-effect/effect": ["effect@4.0.3", "", {}, "sha512-LoWn/Uwwx0JjHSDmBAAahx8sB+klzM6vsZovnbYowBNw6B4QScJLRLBByO61plvNiycx7HPN8FnsWUCu0eXW5w=="], + "@unconfirmed/sui-effect/effect": ["effect@4.0.4", "", {}, "sha512-Sr50OeVSC3M5UkoUYUhFf3EULryhGaZZUf6OzDHTvaznOw7HRlxOKdF3/4nvQXHL22StOyMG3Cvo8Bt7xUp+Ng=="], "bun-types/@types/node": ["@types/node@26.4.1", "", { "dependencies": { "undici-types": "~8.3.0" } }, "sha512-k97ENvZWtvA6yqz5/FS6a7duDgOPEeOQOc2iKS/nY6mX6qJUKtLnWzQS+Xj6tXweyj6ZcTAK2Qecetnvi9nCLA=="], diff --git a/packages/musicos/CHANGELOG.md b/packages/musicos/CHANGELOG.md index 29592bb..4efeb88 100644 --- a/packages/musicos/CHANGELOG.md +++ b/packages/musicos/CHANGELOG.md @@ -4,7 +4,7 @@ All notable changes to `@misofm/musicos`, newest first. ## 0.8.0 -Moves the package from Effect `4.0.0-rc.112` to stable Effect `4.0.3` and +Moves the package from Effect `4.0.0-rc.112` to stable Effect `4.0.x` (developed and tested on `4.0.4`, peer floor `4.0.3`) and `@unconfirmed/sui-effect` `0.3.0`. The public API is unchanged: no export was added, removed or re-typed (the built `.d.ts` files are identical to 0.7.1), and no contract binding changed. @@ -14,7 +14,7 @@ binding changed. - **Peer `effect` is now `>=4.0.3 <4.1`** (was `>=4.0.0-rc.112 <4.1`). Release candidates are no longer supported; stay on 0.7.x for `effect@4.0.0-rc.112`. - **Peer `@unconfirmed/sui-effect` is now `>=0.3.0 <0.4.0`** (was `>=0.1.0 <0.3.0`). - Dev dependencies move to `effect@4.0.3` and `@unconfirmed/sui-effect@0.3.0`. + Dev dependencies move to `effect@4.0.4` and `@unconfirmed/sui-effect@0.3.0`. - Peers `@mysten/sui` (`^2.28`) and `@mysten/bcs` (`^2.1.1`) are unchanged. ### Internal @@ -22,7 +22,7 @@ binding changed. - `Musicos.layerConfig` uses `Config.NonEmptyString` (rc.113 renamed the `Config` constructors to PascalCase; `Config.nonEmptyString` does not exist on 4.0.x). Behaviour is unchanged: `MUSICOS_PACKAGE_ID` unset or empty falls back to the bundled - manifest, a set value overrides it (checked against rc.112 and 4.0.3 with the same + manifest, a set value overrides it (checked against rc.112 and 4.0.x with the same `ConfigProvider`). - Docs: `LLMS.md` and `README.md` name the new peer ranges. @@ -39,21 +39,31 @@ None changes a type, a stored byte or a transaction. Audit of this package: it u - `TimeoutError` now has a message (`Operation timed out after ''`; rc.112's was empty). It reaches this package's callers only through `sui-effect` (`SuiError.describe`, the journal's `lastError`); no text in this package matches on it. -- `ManagedRuntime.dispose` (the Promise face you get from `client.$extend(...)`) now - interrupts calls still in flight instead of letting them finish: await your calls - before disposing. -- `Cause.pretty` includes stack frames and `SchemaError` renders as JSON, so logged - error text is longer. The error classes' own `message`, `toString`, JSON and +- `ManagedRuntime.dispose` (the Promise face you get from `client.$extend(...)`) now waits + for managed fibers and their cleanup to finish before it releases layer resources + (Effect #8528), `Scope.close` finalizers run uninterruptibly (#8512), and disposing from + one of the runtime's own fibers no longer deadlocks (#8783). In-flight calls were + interrupted by `dispose` before and still are; what changes is that `dispose()` now + resolves only after their cleanup has run. +- A `SchemaError` serialised as JSON, inspected or sent through a JSON logger is now a + compact `{ _tag, message }` object instead of a dump of the schema AST (Effect #8895), so + such log lines are shorter. `Cause.pretty` is unchanged. This package maps decode + failures to strings before they escape, so it has no impact here. The error classes' own `message`, `toString`, JSON and `Schema` encode/decode output is byte-identical to the previous release (differential check over every exported error class against the rc.112 build). ### Migrating from 0.7.x -1. Move the whole Effect release train to stable together: `effect@4.0.3` and every - `@effect/*` package you use at `4.0.3`. A mixed release-candidate and stable install +1. Move the whole Effect release train to stable together and pin it to one `4.0.x` + version, for example `"effect": "4.0.4"` with `"@effect/platform-node": "4.0.4"` and every + other `@effect/*` package you use at `4.0.4` (`4.0.3` works too, if all of them match). + Do not rely on the peer range alone: it admits `>=4.0.3 <4.1`, but each `@effect/*` package + peers on its own `effect` floor (for example `@effect/platform-node@4.0.4` and its + `@effect/platform-node-shared` need `effect ^4.0.4`), so an unpinned install can resolve an + invalid tree (npm `ERESOLVE` / `ELSPROBLEMS`). A mixed release-candidate and stable install fails to resolve `effect/*` module paths, and two `effect` copies give the shared - `Context.Service` tags and tagged-error classes different identities. Pin `4.0.x` - explicitly (the `rc` dist-tag still points at a release candidate). + `Context.Service` tags and tagged-error classes different identities. The `rc` dist-tag + still points at a release candidate. 2. Move `@unconfirmed/sui-effect` to `0.3.0` (its own CHANGELOG has the full migration). 3. Nothing to change in code that imports from `@misofm/musicos`; update your own rc imports (`effect/unstable/*` is now `effect/*`) and renames (Effect's `MIGRATION.md`, diff --git a/packages/musicos/package.json b/packages/musicos/package.json index b119edc..b51309f 100644 --- a/packages/musicos/package.json +++ b/packages/musicos/package.json @@ -102,7 +102,7 @@ "@mysten/sui": "2.29.0", "@types/bun": "^1.4.0", "@unconfirmed/sui-effect": "0.3.0", - "effect": "4.0.3", + "effect": "4.0.4", "typedoc": "^0.28.20", "typedoc-plugin-markdown": "^4.13.0", "typescript": "^7.0.2" diff --git a/packages/partyos/CHANGELOG.md b/packages/partyos/CHANGELOG.md index fc4d664..8e321f1 100644 --- a/packages/partyos/CHANGELOG.md +++ b/packages/partyos/CHANGELOG.md @@ -4,7 +4,7 @@ All notable changes to `@misofm/partyos`, newest first. ## 0.8.0 -Moves the package from Effect `4.0.0-rc.112` to stable Effect `4.0.3` and +Moves the package from Effect `4.0.0-rc.112` to stable Effect `4.0.x` (developed and tested on `4.0.4`, peer floor `4.0.3`) and `@unconfirmed/sui-effect` `0.3.0`, and loosens two peer ranges so one copy of each Sui library is installed. The public API is unchanged: every export, including the `createIndividualParty` / `createGroupParty` recipes, `PARTYOS_DEPLOYMENTS`, @@ -17,7 +17,9 @@ library is installed. The public API is unchanged: every export, including the no longer supported; stay on 0.7.x for `effect@4.0.0-rc.112`. - **Peer `@unconfirmed/sui-effect` is now `>=0.3.0 <0.4.0`** (was `>=0.1.0 <0.3.0`). - **`@mysten/bcs` moved from `dependencies` to a peer, `^2.1.1`** (as `sui-effect` and - `@misofm/musicos` have it), so a consumer installs one copy. Install it next to + `@misofm/musicos` have it), so a consumer installs one copy; the use is type-only (the + generated declarations import `@mysten/bcs` types; runtime codecs come through + `@mysten/sui/bcs`). Install it next to `@mysten/sui` if your package manager does not install peers automatically. - **Peer `@mysten/sui` is widened from exactly `2.29.0` to `^2.29.0`.** Development stays pinned to `2.29.0`. @@ -50,21 +52,31 @@ None changes a type, a stored byte or a transaction. Audit of this package: it u - `TimeoutError` now has a message (`Operation timed out after ''`; rc.112's was empty). It reaches this package's callers only through `sui-effect` (`SuiError.describe`, the journal's `lastError`); no text in this package matches on it. -- `ManagedRuntime.dispose` (the Promise face you get from `client.$extend(...)`) now - interrupts calls still in flight instead of letting them finish: await your calls - before disposing. -- `Cause.pretty` includes stack frames and `SchemaError` renders as JSON, so logged - error text is longer. The error classes' own `message`, `toString`, JSON and +- `ManagedRuntime.dispose` (the Promise face you get from `client.$extend(...)`) now waits + for managed fibers and their cleanup to finish before it releases layer resources + (Effect #8528), `Scope.close` finalizers run uninterruptibly (#8512), and disposing from + one of the runtime's own fibers no longer deadlocks (#8783). In-flight calls were + interrupted by `dispose` before and still are; what changes is that `dispose()` now + resolves only after their cleanup has run. +- A `SchemaError` serialised as JSON, inspected or sent through a JSON logger is now a + compact `{ _tag, message }` object instead of a dump of the schema AST (Effect #8895), so + such log lines are shorter. `Cause.pretty` is unchanged. This package maps decode + failures to strings before they escape, so it has no impact here. The error classes' own `message`, `toString`, JSON and `Schema` encode/decode output is byte-identical to the previous release (differential check over every exported error class against the rc.112 build). ### Migrating from 0.7.x -1. Move the whole Effect release train to stable together: `effect@4.0.3` and every - `@effect/*` package you use at `4.0.3`. A mixed release-candidate and stable install +1. Move the whole Effect release train to stable together and pin it to one `4.0.x` + version, for example `"effect": "4.0.4"` with `"@effect/platform-node": "4.0.4"` and every + other `@effect/*` package you use at `4.0.4` (`4.0.3` works too, if all of them match). + Do not rely on the peer range alone: it admits `>=4.0.3 <4.1`, but each `@effect/*` package + peers on its own `effect` floor (for example `@effect/platform-node@4.0.4` and its + `@effect/platform-node-shared` need `effect ^4.0.4`), so an unpinned install can resolve an + invalid tree (npm `ERESOLVE` / `ELSPROBLEMS`). A mixed release-candidate and stable install fails to resolve `effect/*` module paths, and two `effect` copies give the shared - `Context.Service` tags and tagged-error classes different identities. Pin `4.0.x` - explicitly (the `rc` dist-tag still points at a release candidate). + `Context.Service` tags and tagged-error classes different identities. The `rc` dist-tag + still points at a release candidate. 2. Move `@unconfirmed/sui-effect` to `0.3.0` (its own CHANGELOG has the full migration). 3. Add `@mysten/bcs@^2.1.1` to your dependencies if it is not already installed (it was a bundled dependency; it is now a peer). Keep one copy. diff --git a/packages/partyos/package.json b/packages/partyos/package.json index 95fea53..e1803b8 100644 --- a/packages/partyos/package.json +++ b/packages/partyos/package.json @@ -99,7 +99,7 @@ "@mysten/sui": "2.29.0", "@types/bun": "^1.4.0", "@unconfirmed/sui-effect": "0.3.0", - "effect": "4.0.3", + "effect": "4.0.4", "typedoc": "^0.28.20", "typedoc-plugin-markdown": "^4.13.0", "typescript": "^7.0.2" diff --git a/packages/partyos/tests/golden.test.ts b/packages/partyos/tests/golden.test.ts index fac7651..ee75ab5 100644 --- a/packages/partyos/tests/golden.test.ts +++ b/packages/partyos/tests/golden.test.ts @@ -6,7 +6,7 @@ // holds the exact sponsored TransactionData bytes and digests that // `createIndividualParty` / `createGroupParty` produced at // misofm/sdks@56af6a7 (the last release on the rc.112 stack); this test pins -// that the Effect 4.0.3 port builds byte-identical transactions, so a consumer +// that the Effect 4.0.x port builds byte-identical transactions, so a consumer // that reproduces them in another language (the Rust platform, platform-ts) // keeps matching. diff --git a/packages/platform/CHANGELOG.md b/packages/platform/CHANGELOG.md index ddea46f..322b6be 100644 --- a/packages/platform/CHANGELOG.md +++ b/packages/platform/CHANGELOG.md @@ -4,7 +4,7 @@ All notable changes to `@misofm/platform`, newest first. ## 0.46.0 -Moves the package from Effect `4.0.0-rc.112` to stable Effect `4.0.3` and +Moves the package from Effect `4.0.0-rc.112` to stable Effect `4.0.x` (developed and tested on `4.0.4`, peer floor `4.0.3`) and `@unconfirmed/sui-effect` `0.3.0`, on top of `@misofm/musicos` 0.8.0, `@misofm/partyos` 0.8.0 and `@misofm/streaming` 0.4.0. The public API is unchanged: no export was added, removed or re-typed (the built `.d.ts` files are identical to 0.45.0), and no contract @@ -16,7 +16,9 @@ binding changed. no longer supported; stay on 0.45.x for `effect@4.0.0-rc.112`. - **Peer `@unconfirmed/sui-effect` is now `>=0.3.0 <0.4.0`** (was `>=0.1.0 <0.3.0`). - **`@mysten/bcs` moved from `dependencies` to a peer, `^2.1.1`**, so a consumer installs - one copy shared with `sui-effect`, `@misofm/musicos` and `@misofm/partyos`. + one copy shared with `sui-effect`, `@misofm/musicos` and `@misofm/partyos`. The use is + type-only (the generated declarations import `@mysten/bcs` types; runtime codecs come + through `@mysten/sui/bcs`), so one copy keeps those types identical to `@mysten/sui`'s. - **Peer `@mysten/sui` is widened from exactly `2.29.0` to `^2.29.0`.** Development stays pinned to `2.29.0`. - Dependencies `@misofm/musicos` and `@misofm/partyos` move to `0.8.0` and @@ -46,21 +48,31 @@ ignores the error argument that 4.0.x now passes, so it behaves as before. - `TimeoutError` now has a message (`Operation timed out after ''`; rc.112's was empty). It reaches this package's callers only through `sui-effect` (`SuiError.describe`, the journal's `lastError`); no text in this package matches on it. -- `ManagedRuntime.dispose` (the Promise face you get from `client.$extend(...)`) now - interrupts calls still in flight instead of letting them finish: await your calls - before disposing. -- `Cause.pretty` includes stack frames and `SchemaError` renders as JSON, so logged - error text is longer. The error classes' own `message`, `toString`, JSON and +- `ManagedRuntime.dispose` (the Promise face you get from `client.$extend(...)`) now waits + for managed fibers and their cleanup to finish before it releases layer resources + (Effect #8528), `Scope.close` finalizers run uninterruptibly (#8512), and disposing from + one of the runtime's own fibers no longer deadlocks (#8783). In-flight calls were + interrupted by `dispose` before and still are; what changes is that `dispose()` now + resolves only after their cleanup has run. +- A `SchemaError` serialised as JSON, inspected or sent through a JSON logger is now a + compact `{ _tag, message }` object instead of a dump of the schema AST (Effect #8895), so + such log lines are shorter. `Cause.pretty` is unchanged. This package maps decode + failures to strings before they escape, so it has no impact here. The error classes' own `message`, `toString`, JSON and `Schema` encode/decode output is byte-identical to the previous release (differential check over every exported error class against the rc.112 build). ### Migrating from 0.45.x -1. Move the whole Effect release train to stable together: `effect@4.0.3` and every - `@effect/*` package you use at `4.0.3`. A mixed release-candidate and stable install +1. Move the whole Effect release train to stable together and pin it to one `4.0.x` + version, for example `"effect": "4.0.4"` with `"@effect/platform-node": "4.0.4"` and every + other `@effect/*` package you use at `4.0.4` (`4.0.3` works too, if all of them match). + Do not rely on the peer range alone: it admits `>=4.0.3 <4.1`, but each `@effect/*` package + peers on its own `effect` floor (for example `@effect/platform-node@4.0.4` and its + `@effect/platform-node-shared` need `effect ^4.0.4`), so an unpinned install can resolve an + invalid tree (npm `ERESOLVE` / `ELSPROBLEMS`). A mixed release-candidate and stable install fails to resolve `effect/*` module paths, and two `effect` copies give the shared - `Context.Service` tags and tagged-error classes different identities. Pin `4.0.x` - explicitly (the `rc` dist-tag still points at a release candidate). + `Context.Service` tags and tagged-error classes different identities. The `rc` dist-tag + still points at a release candidate. 2. Move `@unconfirmed/sui-effect` to `0.3.0` (its own CHANGELOG has the full migration). 3. Add `@mysten/bcs@^2.1.1` to your dependencies if it is not already installed (it was a bundled dependency; it is now a peer). diff --git a/packages/platform/package.json b/packages/platform/package.json index 074ede8..b7d9f4f 100644 --- a/packages/platform/package.json +++ b/packages/platform/package.json @@ -162,7 +162,7 @@ "@mysten/sui": "2.29.0", "@types/bun": "^1.3.14", "@unconfirmed/sui-effect": "0.3.0", - "effect": "4.0.3", + "effect": "4.0.4", "typescript": "^7.0.2" }, "peerDependencies": { diff --git a/packages/platform/tests/dependency-contract.test.ts b/packages/platform/tests/dependency-contract.test.ts index fd1bc4a..1b578a3 100644 --- a/packages/platform/tests/dependency-contract.test.ts +++ b/packages/platform/tests/dependency-contract.test.ts @@ -14,8 +14,12 @@ const repositoryRoot = `${import.meta.dir}/..`; // The pinned development version of each package the SDK builds against, and // the (wider) peer range consumers may bring. The dev pin must satisfy the // peer range, and a consumer must not install the package itself. +// +// CI also runs the SDKs against other releases inside the peer range +// (`scripts/use-sui-version.ts`, the `sui-matrix` job): it rewrites the dev pin +// and sets MISO_SUI_VERSION, which replaces the expected development version. const pinnedVersions = { - "@mysten/sui": { development: "2.29.0", peer: "^2.29.0" }, + "@mysten/sui": { development: process.env["MISO_SUI_VERSION"] ?? "2.29.0", peer: "^2.29.0" }, } as const; const exactVersionPattern = /^\d+\.\d+\.\d+(?:-[0-9A-Za-z.-]+)?$/; @@ -57,9 +61,10 @@ test("Sui is pinned for development and a caret range for consumers", async () = expect(developmentVersion, `${name} devDependency must be exact`).toMatch( exactVersionPattern, ); - expect(peerVersion, `${name} peer range must admit the dev pin`).toBe( - `^${developmentVersion}`, - ); + expect( + Bun.semver.satisfies(developmentVersion ?? "", peerVersion ?? ""), + `${name} peer range must admit the dev pin`, + ).toBe(true); expect( consumer.devDependencies?.[name] ?? consumer.dependencies?.[name], `${name} must be resolved only through the SDK peer contract`, @@ -86,6 +91,6 @@ test("Effect, sui-effect and bcs are peers on the stable 4.0.x line", async () = // bundled dependency. expect(manifest.peerDependencies?.["@mysten/bcs"]).toBe("^2.1.1"); expect(manifest.dependencies?.["@mysten/bcs"]).toBeUndefined(); - expect(manifest.devDependencies?.effect).toBe("4.0.3"); + expect(manifest.devDependencies?.effect).toBe("4.0.4"); expect(manifest.devDependencies?.["@unconfirmed/sui-effect"]).toBe("0.3.0"); }); diff --git a/packages/platform/tests/fixtures/isolated-consumer/package.json b/packages/platform/tests/fixtures/isolated-consumer/package.json index e326eb0..232612e 100644 --- a/packages/platform/tests/fixtures/isolated-consumer/package.json +++ b/packages/platform/tests/fixtures/isolated-consumer/package.json @@ -6,13 +6,13 @@ "check": "tsc --noEmit && node verify.mjs" }, "dependencies": { - "@effect/platform-node": "4.0.3", + "@effect/platform-node": "4.0.4", "@misofm/musicos": "file:../misofm-musicos.tgz", "@misofm/partyos": "file:../misofm-partyos.tgz", "@misofm/platform": "file:../misofm-platform.tgz", "@misofm/streaming": "file:../misofm-streaming.tgz", "@misofm/transcoding": "file:../misofm-transcoding.tgz", - "effect": "4.0.3", + "effect": "4.0.4", "@unconfirmed/sui-effect": "0.3.0", "typescript": "5.9.3" } diff --git a/packages/platform/tests/fixtures/isolated-consumer/verify.mjs b/packages/platform/tests/fixtures/isolated-consumer/verify.mjs index 506a052..aa0cfef 100644 --- a/packages/platform/tests/fixtures/isolated-consumer/verify.mjs +++ b/packages/platform/tests/fixtures/isolated-consumer/verify.mjs @@ -271,8 +271,10 @@ assertSingleInstance("@mysten/sui"); assertSingleInstance("effect"); // `@mysten/bcs` is a peer of partyos, musicos and platform (not a bundled -// dependency), so codecs generated in one package and parsed in another -// share one `BcsType` implementation. +// dependency). The runtime codecs come through `@mysten/sui/bcs`; the peer is +// type-only (the generated declarations `import type {} from "@mysten/bcs"`), +// so one installed copy keeps the `BcsType` types in the packed `.d.ts` files +// identical to the ones `@mysten/sui` exposes. assertSingleInstance("@mysten/bcs"); // A consumer that ends up resolving two copies of the same `@misofm/*` diff --git a/packages/streaming/CHANGELOG.md b/packages/streaming/CHANGELOG.md index 194e05c..3c90959 100644 --- a/packages/streaming/CHANGELOG.md +++ b/packages/streaming/CHANGELOG.md @@ -4,7 +4,7 @@ All notable changes to `@misofm/streaming`, newest first. ## 0.4.0 -Moves the package from Effect `4.0.0-rc.112` to stable Effect `4.0.3`. The public API and +Moves the package from Effect `4.0.0-rc.112` to stable Effect `4.0.x` (developed and tested on `4.0.4`, peer floor `4.0.3`). The public API and the `miso-hls/v1` contract are unchanged: no export was added, removed or re-typed (the built `.d.ts` files are identical to 0.3.0), and the source needed no change. @@ -26,12 +26,20 @@ byte-identical to 0.3.0. - `Scope.close` finalizers (so `acquirePlayer`'s release) run uninterruptibly in Effect 4.0.x; the release only detaches hls.js and clears the media element, so this is unobservable here. -- `Cause.pretty` includes stack frames and `SchemaError` renders as JSON, so logged error - text is longer. +- A `SchemaError` serialised as JSON or inspected is now a compact `{ _tag, message }` + object instead of a dump of the schema AST (Effect #8895), so such log lines are + shorter. `Cause.pretty` is unchanged. Nothing in this package logs a `SchemaError`. ### Migrating from 0.3.x -1. Move the whole Effect release train to stable together (`effect@4.0.3`, every `@effect/*` - package at `4.0.3`). Pin `4.0.x` explicitly; the `rc` dist-tag still points at a - release candidate. +1. Move the whole Effect release train to stable together and pin it to one `4.0.x` + version, for example `"effect": "4.0.4"` with `"@effect/platform-node": "4.0.4"` and every + other `@effect/*` package you use at `4.0.4` (`4.0.3` works too, if all of them match). + Do not rely on the peer range alone: it admits `>=4.0.3 <4.1`, but each `@effect/*` package + peers on its own `effect` floor (for example `@effect/platform-node@4.0.4` and its + `@effect/platform-node-shared` need `effect ^4.0.4`), so an unpinned install can resolve an + invalid tree (npm `ERESOLVE` / `ELSPROBLEMS`). A mixed release-candidate and stable install + fails to resolve `effect/*` module paths, and two `effect` copies give the shared + `Context.Service` tags and tagged-error classes different identities. The `rc` dist-tag + still points at a release candidate. 2. Nothing to change in code that imports from `@misofm/streaming`. diff --git a/packages/streaming/package.json b/packages/streaming/package.json index 624b865..6a6093e 100644 --- a/packages/streaming/package.json +++ b/packages/streaming/package.json @@ -72,7 +72,7 @@ }, "devDependencies": { "@types/bun": "^1.4.0", - "effect": "4.0.3", + "effect": "4.0.4", "hls.js": "1.6.13", "typescript": "^7.0.2" } diff --git a/packages/transcoding/CHANGELOG.md b/packages/transcoding/CHANGELOG.md index 2260080..7107e3a 100644 --- a/packages/transcoding/CHANGELOG.md +++ b/packages/transcoding/CHANGELOG.md @@ -4,8 +4,8 @@ All notable changes to `@misofm/transcoding`, newest first. ## 0.5.0 -Moves the package from Effect `4.0.0-rc.112` to stable Effect `4.0.3` and -`@effect/platform-node` `4.0.3`, on top of `@misofm/streaming` 0.4.0. The public API and the +Moves the package from Effect `4.0.0-rc.112` to stable Effect `4.0.x` (developed and tested on `4.0.4`, peer floor `4.0.3`) and +`@effect/platform-node` `4.0.4`, on top of `@misofm/streaming` 0.4.0. The public API and the transcode output are unchanged: no export was added, removed or re-typed (the built `.d.ts` files are identical to 0.4.0), the source needed no change, and the pinned-FFmpeg golden and the cancellation test produce the same results. @@ -33,15 +33,22 @@ semantics (`Effect.uninterruptible`, `Effect.acquireUseRelease` for the workspac (Effect #8585). The ffmpeg integration test (cancel a running transcode, then acquire the workspace lock; -byte-golden artifacts under the pinned FFmpeg) passes on both the rc.112 and the 4.0.3 +byte-golden artifacts under the pinned FFmpeg) passes on both the rc.112 and the 4.0.4 builds. If you wrap a transcode in your own `Effect.race`/timeout, note that losers that are still starting are now interrupted. ### Migrating from 0.4.x -1. Move the whole Effect release train to stable together: `effect@4.0.3` and - `@effect/platform-node@4.0.3` (and any other `@effect/*` package). Pin `4.0.x` - explicitly; the `rc` dist-tag still points at a release candidate. +1. Move the whole Effect release train to stable together and pin it to one `4.0.x` + version, for example `"effect": "4.0.4"` with `"@effect/platform-node": "4.0.4"` (both are peers of this package) and every + other `@effect/*` package you use at `4.0.4` (`4.0.3` works too, if all of them match). + Do not rely on the peer range alone: it admits `>=4.0.3 <4.1`, but each `@effect/*` package + peers on its own `effect` floor (for example `@effect/platform-node@4.0.4` and its + `@effect/platform-node-shared` need `effect ^4.0.4`), so an unpinned install can resolve an + invalid tree (npm `ERESOLVE` / `ELSPROBLEMS`). A mixed release-candidate and stable install + fails to resolve `effect/*` module paths, and two `effect` copies give the shared + `Context.Service` tags and tagged-error classes different identities. The `rc` dist-tag + still points at a release candidate. 2. Nothing to change in code that imports from `@misofm/transcoding`. 3. Review `partition`/`separate` destructuring in your own code: 4.0.x returns `[successes, failures]`. diff --git a/packages/transcoding/package.json b/packages/transcoding/package.json index a523374..e45ba4c 100644 --- a/packages/transcoding/package.json +++ b/packages/transcoding/package.json @@ -66,10 +66,10 @@ "effect": ">=4.0.3 <4.1" }, "devDependencies": { - "@effect/platform-node": "4.0.3", + "@effect/platform-node": "4.0.4", "@types/bun": "1.2.22", "@types/node": "24.10.1", - "effect": "4.0.3", + "effect": "4.0.4", "hls.js": "1.6.13", "playwright": "1.55.0", "prettier": "3.6.2", diff --git a/packages/transcoding/test/isolated-consumer.mjs b/packages/transcoding/test/isolated-consumer.mjs index 8e865b3..829f265 100644 --- a/packages/transcoding/test/isolated-consumer.mjs +++ b/packages/transcoding/test/isolated-consumer.mjs @@ -54,11 +54,13 @@ if (runtime === "node") { // tarballs reach npm only through `overrides`. await run("npm", [ "install", + "--strict-peer-deps", "--ignore-scripts", tarball, - "effect@4.0.3", - "@effect/platform-node@4.0.3", + "effect@4.0.4", + "@effect/platform-node@4.0.4", ]); + await run("npm", ["ls"]); await run("node", [ "--input-type=module", "-e", @@ -70,8 +72,8 @@ if (runtime === "node") { "--ignore-scripts", tarball, ...extras, - "effect@4.0.3", - "@effect/platform-node@4.0.3", + "effect@4.0.4", + "@effect/platform-node@4.0.4", ]); await run("bun", [ "-e", diff --git a/scripts/check-consumer.ts b/scripts/check-consumer.ts index 26ead16..3d56d31 100644 --- a/scripts/check-consumer.ts +++ b/scripts/check-consumer.ts @@ -66,10 +66,14 @@ rmSync(join(fixtureDir, "node_modules"), { recursive: true, force: true }); rmSync(join(fixtureDir, "package-lock.json"), { force: true }); console.log("test:consumer: installing isolated-consumer fixture"); -execFileSync("npm", ["install", "--ignore-scripts", "--no-audit", "--no-fund"], { +// `--strict-peer-deps` and `npm ls` fail on an invalid peer tree (for example +// an `@effect/*` package whose `effect` peer floor is newer than the pinned +// `effect`), which npm would otherwise only warn about. +execFileSync("npm", ["install", "--strict-peer-deps", "--ignore-scripts", "--no-audit", "--no-fund"], { cwd: fixtureDir, stdio: "inherit", }); +execFileSync("npm", ["ls"], { cwd: fixtureDir, stdio: "inherit" }); console.log("test:consumer: running isolated-consumer check (tsc + verify.mjs)"); execFileSync("npm", ["run", "check"], { cwd: fixtureDir, stdio: "inherit" }); diff --git a/scripts/use-sui-version.ts b/scripts/use-sui-version.ts new file mode 100644 index 0000000..0c53d61 --- /dev/null +++ b/scripts/use-sui-version.ts @@ -0,0 +1,39 @@ +// Copyright (c) Miso Labs, Inc. +// SPDX-License-Identifier: Apache-2.0 + +// Rewrites every exact `@mysten/sui` development pin in the workspace to one +// version, so CI can run the object-model SDKs' typecheck and tests against +// another release inside the packages' declared peer range (`^2.29.0`). It +// only edits package.json files; follow it with a plain `bun install`. The +// lockfile is not meant to be committed after this. +// +// bun scripts/use-sui-version.ts 2.30.0 +// +// Tests that assert the installed version read it from MISO_SUI_VERSION. + +import { readFileSync, readdirSync, writeFileSync } from "node:fs"; +import { join } from "node:path"; + +const version = process.argv[2]; +if (!version || !/^\d+\.\d+\.\d+$/.test(version)) { + console.error("usage: bun scripts/use-sui-version.ts "); + process.exit(1); +} + +const root = join(import.meta.dir, ".."); +const manifests = [ + join(root, "package.json"), + ...readdirSync(join(root, "packages"), { withFileTypes: true }) + .filter((entry) => entry.isDirectory()) + .map((entry) => join(root, "packages", entry.name, "package.json")), +]; + +for (const path of manifests) { + const manifest = JSON.parse(readFileSync(path, "utf8")) as { + devDependencies?: Record; + }; + if (manifest.devDependencies?.["@mysten/sui"] === undefined) continue; + manifest.devDependencies["@mysten/sui"] = version; + writeFileSync(path, `${JSON.stringify(manifest, null, 2)}\n`); + console.log(`use-sui-version: ${path} -> @mysten/sui ${version}`); +}