From 136a7b2d7d46a65d047c22c5af92ca214763466b Mon Sep 17 00:00:00 2001 From: Cristina Poncela Cubeiro <140309543+cristinaponcela@users.noreply.github.com> Date: Thu, 5 Nov 2026 12:42:32 +0100 Subject: [PATCH] chore(licenses): rename dir (#11834) Radius's control-plane client now bundles pi-schema, and Vite's license step reads the first entry whose name starts with "license" as the package's license file. Here that entry is pi-schema's LICENSES/ folder, so Vite tries to read a directory as a file and the build fails, which renaming the folder fixes without any Radius-side workaround. --- packages/mcp/CHANGELOG.md | 1 + packages/mcp/README.md | 2 +- .../modelcontextprotocol-typescript-sdk.txt | 0 packages/mcp/package.json | 2 +- packages/mcp/src/oauth/discovery.ts | 2 +- packages/mcp/src/oauth/flow.ts | 2 +- packages/mcp/src/oauth/types.ts | 2 +- packages/schema/CHANGELOG.md | 1 + packages/schema/README.md | 2 +- .../schema/{LICENSES => THIRD_PARTY_NOTICES}/typebox-LICENSE | 0 packages/schema/package.json | 2 +- 11 files changed, 9 insertions(+), 7 deletions(-) rename packages/mcp/{LICENSES => THIRD_PARTY_NOTICES}/modelcontextprotocol-typescript-sdk.txt (100%) rename packages/schema/{LICENSES => THIRD_PARTY_NOTICES}/typebox-LICENSE (100%) diff --git a/packages/mcp/CHANGELOG.md b/packages/mcp/CHANGELOG.md index acb7e171e..f65bc953e 100644 --- a/packages/mcp/CHANGELOG.md +++ b/packages/mcp/CHANGELOG.md @@ -10,6 +10,7 @@ ### Fixed +- The third-party licenses are in `THIRD_PARTY_NOTICES/`, renamed from `LICENSES/`, which Vite's license notices read as the package's license file, failing browser builds that bundle the package. - Fixed Streamable HTTP `application/json` responses bypassing `maxMessageBytes`; oversized JSON responses are now cancelled and rejected like oversized SSE events ([#11335](https://github.com/earendil-works/pi/issues/11335)) - Fixed Streamable HTTP errors reading the whole HTTP error body; only the first 8 KiB kept in the error is read, and the rest is cancelled diff --git a/packages/mcp/README.md b/packages/mcp/README.md index d9e7f6f12..16d239524 100644 --- a/packages/mcp/README.md +++ b/packages/mcp/README.md @@ -147,7 +147,7 @@ if (started.kind === "redirect") { For a browser on the same machine, `listenForLoopbackSignIn()` starts a loopback callback server and returns its redirect URI, and `waitForLoopbackSignIn()` waits for the response on it or for a pasted redirect URL. `clientMetadataDocuments` lets authorization servers that support Client ID Metadata Documents identify the application by a document it publishes instead of registering a client. `createMcpAuthProvider()` is the matching `AuthProvider` for connections: it refreshes the stored tokens and throws `McpOAuthAuthorizationRequiredError` when the user has to sign in. -The OAuth implementation is adapted from the MIT-licensed Model Context Protocol TypeScript SDK v1.29.0. Its license is included under `LICENSES/`. +The OAuth implementation is adapted from the MIT-licensed Model Context Protocol TypeScript SDK v1.29.0. Its license is included under `THIRD_PARTY_NOTICES/`. ### Configuration diff --git a/packages/mcp/LICENSES/modelcontextprotocol-typescript-sdk.txt b/packages/mcp/THIRD_PARTY_NOTICES/modelcontextprotocol-typescript-sdk.txt similarity index 100% rename from packages/mcp/LICENSES/modelcontextprotocol-typescript-sdk.txt rename to packages/mcp/THIRD_PARTY_NOTICES/modelcontextprotocol-typescript-sdk.txt diff --git a/packages/mcp/package.json b/packages/mcp/package.json index 8a9bac663..354cf02cc 100644 --- a/packages/mcp/package.json +++ b/packages/mcp/package.json @@ -27,7 +27,7 @@ "dist", "README.md", "CHANGELOG.md", - "LICENSES" + "THIRD_PARTY_NOTICES" ], "scripts": { "clean": "node ../../scripts/package-files.mjs clean dist", diff --git a/packages/mcp/src/oauth/discovery.ts b/packages/mcp/src/oauth/discovery.ts index 1d348ca98..7ef3cf077 100644 --- a/packages/mcp/src/oauth/discovery.ts +++ b/packages/mcp/src/oauth/discovery.ts @@ -1,6 +1,6 @@ /* * Adapted from modelcontextprotocol/typescript-sdk v1.29.0 src/client/auth.ts. - * Copyright (c) 2024 Anthropic, PBC. Licensed under MIT; see LICENSES/. + * Copyright (c) 2024 Anthropic, PBC. Licensed under MIT; see THIRD_PARTY_NOTICES/. * Modified to remove Zod/CORS shims and enforce authorization-server issuer validation. */ diff --git a/packages/mcp/src/oauth/flow.ts b/packages/mcp/src/oauth/flow.ts index 993c0a7b1..bac4fde3e 100644 --- a/packages/mcp/src/oauth/flow.ts +++ b/packages/mcp/src/oauth/flow.ts @@ -1,6 +1,6 @@ /* * Adapted from modelcontextprotocol/typescript-sdk v1.29.0 src/client/auth.ts. - * Copyright (c) 2024 Anthropic, PBC. Licensed under MIT; see LICENSES/. + * Copyright (c) 2024 Anthropic, PBC. Licensed under MIT; see THIRD_PARTY_NOTICES/. * Modified to remove SDK/Zod dependencies and use WebCrypto for PKCE. */ diff --git a/packages/mcp/src/oauth/types.ts b/packages/mcp/src/oauth/types.ts index d7d915394..f07bfbbe7 100644 --- a/packages/mcp/src/oauth/types.ts +++ b/packages/mcp/src/oauth/types.ts @@ -1,6 +1,6 @@ /* * Adapted from modelcontextprotocol/typescript-sdk v1.29.0. - * Copyright (c) 2024 Anthropic, PBC. Licensed under MIT; see LICENSES/. + * Copyright (c) 2024 Anthropic, PBC. Licensed under MIT; see THIRD_PARTY_NOTICES/. * Modified to use dependency-free structural validation. */ diff --git a/packages/schema/CHANGELOG.md b/packages/schema/CHANGELOG.md index 01342cf12..9a42d47d2 100644 --- a/packages/schema/CHANGELOG.md +++ b/packages/schema/CHANGELOG.md @@ -17,6 +17,7 @@ ### Fixed +- The third-party licenses are in `THIRD_PARTY_NOTICES/`, renamed from `LICENSES/`, which Vite's license notices read as the package's license file, failing browser builds that bundle the package. - A required property set to `undefined` is valid when its schema takes `undefined` (a union with `Type.Undefined()`, `Type.Unknown()`, `Type.Any()`), as in TypeBox; before, it was always missing. An optional one set to `undefined` still counts as absent. - Fixed local `$ref`s in schemas whose root `$id` is a relative path with a directory, such as `schemas/tool.json`: the `$id` was applied twice, so `compile` threw and `unresolvedRefs: "reject"` rejected valid tool arguments. Relative `$id`s are now also applied once with `unevaluatedProperties`/`unevaluatedItems`, when explaining errors under nested resources, and on the first coercion of a schema with `$dynamicRef` ([#11697](https://github.com/earendil-works/pi/issues/11697)) diff --git a/packages/schema/README.md b/packages/schema/README.md index 62b03f899..560029726 100644 --- a/packages/schema/README.md +++ b/packages/schema/README.md @@ -316,4 +316,4 @@ schemas that arrive later. `npm test` runs the official test suite (drafts 2020-12 and 7, including the optional and format tests, vendored in `test/fixtures/`) and the package's own tests. -The format checks are adapted from TypeBox 1.3.27 (MIT); its license is in `LICENSES/`. +The format checks are adapted from TypeBox 1.3.27 (MIT); its license is in `THIRD_PARTY_NOTICES/`. diff --git a/packages/schema/LICENSES/typebox-LICENSE b/packages/schema/THIRD_PARTY_NOTICES/typebox-LICENSE similarity index 100% rename from packages/schema/LICENSES/typebox-LICENSE rename to packages/schema/THIRD_PARTY_NOTICES/typebox-LICENSE diff --git a/packages/schema/package.json b/packages/schema/package.json index 4e176a57c..a411e05e9 100644 --- a/packages/schema/package.json +++ b/packages/schema/package.json @@ -22,7 +22,7 @@ "dist", "README.md", "CHANGELOG.md", - "LICENSES" + "THIRD_PARTY_NOTICES" ], "scripts": { "clean": "node ../../scripts/package-files.mjs clean dist",