Skip to content

consume new compile project endpoint - #11757

Merged
Richard Knoll (riknoll) merged 6 commits into
masterfrom
dev/riknoll/new-compile-endpoint
Nov 13, 2026
Merged

Richard Knoll (riknoll) merged 6 commits into
masterfrom
dev/riknoll/new-compile-endpoint

Conversation

@riknoll

Copy link
Copy Markdown
Member

consuming the new project endpoint.

also deprecating the old platformio and npmDependencies fields in pxt.json since we don't actually use them anywhere; i think they were mostly just for testing new hardware builds

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

Critical regressions exclude required native build inputs from requests and hashes, break project include paths and simulator-only compilation, and leave the new CLI tests unable to type-check.

5 open issues
What changed in this PR

Updates PXT’s native compilation pipeline to consume the new project-based cloud endpoint, with shared request preparation for compiler and backend use.

Changes:

  • Adds canonical native-project payloads and hashes.
  • Uses the project compile endpoint, checks both hex cache locations, and fetches the returned build URL.
  • Removes support for package-level npmDependencies and platformio, with warnings, documentation, and request-focused tests.
File Description
tests/​common/​testUtils.ts Adds a target version to the shared test fixture.
tests/​cli-test/​clirunner.ts Adds request, variant, dependency, and legacy-field test cases.
pxtlib/​shared/​packageutils.ts Removes unsupported package fields with warnings.
pxtlib/​shared/​extensionrequest.ts Prepares canonical project requests, encoded payloads, and hashes.
pxtlib/​shared/​extensioninfo.ts Ignores legacy package settings while preserving target-level PlatformIO configuration.
pxtlib/​package.ts Attaches project request data during compile-option preparation.
pxtlib/​cpp.ts Integrates the project endpoint, cache lookup, and returned build URLs.
localtypings/​pxtpackage.d.ts Removes obsolete package configuration fields.
localtypings/​pxtarget.d.ts Adds project payload and hash fields to extension metadata.
docs/​extensions/​pxt-json.md Documents removed fields and supported PlatformIO target settings.
backendutils/​backendutils.ts Includes shared request helpers in the backend bundle.

Review effort: Max

Comment thread pxtlib/package.ts Resolved
Comment thread pxtlib/shared/extensionrequest.ts Resolved
packageUtils.isVariantDisabled(configs[resolvePath(dep)], variant));

const config: PackageConfig = {
name: path ? original.name : "this",

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is technically a breaking change, but one that will only affect extension authors and not end-users. and i think it's pretty unlikely to affect the extension authors either; only if they were prefixing their includes with the name of their extension

Comment thread tests/cli-test/clirunner.ts Resolved
Comment thread pxtlib/package.ts Resolved
@riknoll
Richard Knoll (riknoll) added this pull request to the merge queue Nov 13, 2026
Merged via the queue into master with commit 6a6b1e1 Nov 13, 2026
20 checks passed
@riknoll
Richard Knoll (riknoll) deleted the dev/riknoll/new-compile-endpoint branch November 13, 2026 19:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants