From 4260ddefbeb3631ebeb92c82715045696713c5bf Mon Sep 17 00:00:00 2001 From: Claude Date: Mon, 30 Nov 2026 18:29:11 +0000 Subject: [PATCH 1/4] ADFA-7211 Plugin API changelog: re-bucket 26.41 to 26.48, and say min_ide_version is not enforced Each entry from 26.41 on now sits under the first release tag that contains its commit (git tag --list --contains), dated by the tagged commit; ADFA-7134 and ADFA-7139 are in no tag and go under "26.49 - unreleased". Entry text is unchanged except the "Floor plugin.min_ide_version at ..." versions, which named the wrong release in ten places and now name the one that first shipped each entry. min_ide_version is read, checked for non-blank and shown, but never compared with the IDE version. Say so in the changelog, PLUGIN_AUTHORING.md, plugin-api.md and the ToolSourceRegistry.CONTRACT_VERSION Javadoc, which claimed it was enforced. The regeneration step now says to run at every release tag. Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_01Vh2DAZ8yszEP4MqbR9PLba --- docs/PLUGIN_API_CHANGELOG.md | 51 ++++++++++++------- docs/PLUGIN_AUTHORING.md | 4 +- docs/plugin-api.md | 2 +- .../plugins/services/ToolSourceRegistry.java | 2 +- 4 files changed, 39 insertions(+), 20 deletions(-) diff --git a/docs/PLUGIN_API_CHANGELOG.md b/docs/PLUGIN_API_CHANGELOG.md index 22e515e2d9..d2b8561942 100644 --- a/docs/PLUGIN_API_CHANGELOG.md +++ b/docs/PLUGIN_API_CHANGELOG.md @@ -11,8 +11,15 @@ correct `plugin.min_ide_version`. ## How to use this Set `plugin.min_ide_version` to the **highest** version below among the -capabilities your plugin actually uses. Only `min` is enforced at install today; -`max` is parsed but advisory. +capabilities your plugin actually uses. + +Neither `min` nor `max` is enforced at install today. `PluginLoader` reads both, +`PluginSecurityManager` checks only that `min` is not blank, and the Plugin Manager +shows `min` in the plugin's details; nothing compares either with the IDE's version. +So an IDE older than your floor still installs the plugin, and a call to a member it +lacks fails there with `NoSuchMethodError` (a missing class, `NoClassDefFoundError`). +Set the floor anyway: it records what the plugin needs, for users and for any check +added later. ```xml @@ -35,14 +42,14 @@ need a source change, a recompile, or both · `tooling` = API-stability milestone. **[verified]** = read from the checked-in ABI dump. **[reconstructed]** = diffed from `plugin-api/src` history (predates the dump; symbol-accurate). -### 26.48 — unreleased +### 26.49 — unreleased - **added — Show the IDE's own documentation from a plugin** _(ADFA-7134)_ `IdeTooltipService.showTooltip(anchorView, category, tag)` now reads the IDE's documentation when `category` is `ide`, `java`, `kotlin` or `xml`, for example `showTooltip(view, "java", "android.widget.TextView")`. Before, every category was replaced with the plugin's own, so those calls found nothing. Any other category still reads the plugin's own entries, so a plugin that passes its own category under another spelling is - unaffected. Floor `plugin.min_ide_version` at `26.48` to rely on it. + unaffected. Floor `plugin.min_ide_version` at `26.49` to rely on it. - **added — Find the SQLite debugger of the open project's apps** _(ADFA-7139)_ **[verified]** `DebuggerEndpointService.getEndpoints()` returns an unmodifiable `List`, one per app of the open project that has reported to the IDE: `applicationId`, `port` (on `127.0.0.1`), `token` (the bearer @@ -63,8 +70,10 @@ milestone. **[verified]** = read from the checked-in ABI dump. **[reconstructed] below, and does not stop a plugin from taking another plugin's service from `PluginManager.getInstance().getLoadedPlugin(id).context.services` or `PluginFragmentHelper.getServiceRegistry` (tracked in ADFA-7194). Floor `plugin.min_ide_version` - at `26.48`: an IDE of 26.47 or older rejects the unknown `debugger.endpoints` permission when it + at `26.49`: an IDE of 26.48 or older rejects the unknown `debugger.endpoints` permission when it validates the manifest, so it refuses to install a plugin that declares it. + +### 26.48 — 2026-11-23 - **added — Hear the editor open and close a project, and save a file** _(ADFA-3570)_ **[verified]** `IdeProjectService.addProjectLifecycleListener(ProjectLifecycleListener)` calls `onProjectOpened(projectDir)` when the editor starts opening a project (its sync does not wait @@ -78,7 +87,7 @@ milestone. **[verified]** = read from the checked-in ABI dump. **[reconstructed] first. Paths are canonical, except one the IDE cannot resolve (`getCanonicalFile()` fails), which is absolute instead. Floor `plugin.min_ide_version` at `26.48` to use them. -### 26.43 — unreleased +### 26.47 — 2026-11-17 - **breaking — JavaScript highlighting and the IDE's grammar names are the IDE's** _(ADFA-7084)_ The IDE now highlights `js`, `mjs`, `cjs` and `jsx` itself. A `LanguageDefinition` can still claim them, but only with a language server: its grammar is ignored for them, and its server @@ -92,6 +101,8 @@ milestone. **[verified]** = read from the checked-in ABI dump. **[reconstructed] server: it keeps its server and needs no change. A plugin that wants its own JavaScript grammar used claims another extension, and builds the grammar to export `tree_sitter_` under a name of its own. + +### 26.44 — 2026-10-27 - **tooling — Interface bodies are Java default methods again** _(ADFA-6560)_ **[verified]** Since ADFA-4058 (May 2026) pinned `languageVersion`, `plugin-api` compiled each Kotlin interface body as an abstract method plus a `DefaultImpls` static. Plugins built against an earlier @@ -104,11 +115,11 @@ milestone. **[verified]** = read from the checked-in ABI dump. **[reconstructed] of a method added after it was built instead of failing with `AbstractMethodError`. A plugin built against this `plugin-api` calls those bodies on the interface, and an IDE built - between ADFA-4058 and 26.42 has none: there, any interface method the plugin does not override - fails with `AbstractMethodError`. Floor `plugin.min_ide_version` at `26.43`, or override every + between ADFA-4058 and 26.43 has none: there, any interface method the plugin does not override + fails with `AbstractMethodError`. Floor `plugin.min_ide_version` at `26.44`, or override every method of the interfaces you implement. -### 26.42 — unreleased +### 26.43 — 2026-10-20 - **added — Tell whether a server is on this device, the local network or the internet** _(ADFA-6536)_ **[verified]** `net.ServerUrl.parse(url)` returns `ServerUrlParseResult.Valid(url)` or `Invalid(reason)`, where `Invalid.Reason` is `BLANK`, `MALFORMED`, `UNSUPPORTED_SCHEME` or `NO_HOST` (more may be added). A @@ -116,7 +127,7 @@ milestone. **[verified]** = read from the checked-in ABI dump. **[reconstructed] `LOOPBACK` (`localhost`, `127.0.0.0/8`, `::1`, `0.0.0.0`, `::`), `PRIVATE_NETWORK` (RFC 1918, link-local, IPv6 unique-local, `.local` and dotless names) or `PUBLIC`. It reads the URL as typed and never resolves a name, so it is safe on the main thread. It only classifies; each plugin decides what it allows - for each locality. Floor `plugin.min_ide_version` at `26.42` to use it. + for each locality. Floor `plugin.min_ide_version` at `26.43` to use it. - **added — Start Quick Build and get its result** _(ADFA-6493)_ **[verified]** `IdeBuildService.getQuickBuildAvailability()` returns `QuickBuildAvailability.Available`, or `Unavailable(reason, message)` with a `QuickBuildUnavailableReason`: `EXPERIMENTS_DISABLED`, @@ -131,7 +142,7 @@ milestone. **[verified]** = read from the checked-in ABI dump. **[reconstructed] drops a plugin's start still saving or asking the user; the start's future reports what actually happened, usually `Cancelled`. It needs `system.commands`. `getQuickBuildStatus()` returns a `QuickBuildState`: `READY`, `BUILDING`, `FULL_BUILD_NEXT`, `RECONNECTING`, `ERROR`, or `UNAVAILABLE`. Floor `plugin.min_ide_version` at - `26.42`: an older IDE has none of these methods or classes. + `26.43`: an older IDE has none of these methods or classes. - **added — Context window and typed failures for LLM backends** _(ADFA-6493)_ **[verified]** `LlmInferenceService.ContextWindowReportingBackend.getContextWindowTokens()` lets a backend report the tokens one request may hold (for a local model, the context actually allocated), or 0 while @@ -142,9 +153,9 @@ milestone. **[verified]** = read from the checked-in ABI dump. **[reconstructed] `onError(error, kind)` that falls back to `onError(error)`, so consumers built before it still hear every failure. It lives on a new `ErrorCallback` that `StreamCallback` and `ToolStreamCallback` both extend, so one class can still implement both. Floor - `plugin.min_ide_version` at `26.42` to call or implement any of them. + `plugin.min_ide_version` at `26.43` to call or implement any of them. -### 26.41 — unreleased +### 26.42 — 2026-10-13 - **added — Terminal readiness and visible terminal commands** _(ADFA-6373, ADFA-6385)_ **[verified]** `IdeTerminalService.isTerminalReady()` reports whether the terminal environment is installed and bash runs; it needs no permission. `runInTerminal(command, workingDirectory, waitMillis)` @@ -162,7 +173,7 @@ milestone. **[verified]** = read from the checked-in ABI dump. **[reconstructed] that exited before the plugin's last 8 others did. `stopCommand(commandId, waitMillis)` interrupts that command with Ctrl-C and returns its state as `readCommand` does after waiting up to `waitMillis` for it to exit; it never touches a later command in the same session. All three need `system.commands`; - the working directory must lie inside the project. Floor `plugin.min_ide_version` at `26.41`: + the working directory must lie inside the project. Floor `plugin.min_ide_version` at `26.42`: an older IDE has no `IdeTerminalService` class, so referencing it fails to load. - **added — Run Gradle tasks with arguments, get a structured result, cancel** _(ADFA-6373)_ **[verified]** `IdeBuildService.executeTasks(tasks: List, arguments: List)` runs on the @@ -173,12 +184,12 @@ milestone. **[verified]** = read from the checked-in ABI dump. **[reconstructed] `IdeBuildService.cancelBuild()` cancels the running build, whoever started it. Non-empty `arguments` and `cancelBuild()` need `system.commands` and throw `SecurityException` without it. While the build runs, a sync or build the user starts is refused. Floor - `plugin.min_ide_version` at `26.41`: an older IDE has neither method. + `plugin.min_ide_version` at `26.42`: an older IDE has neither method. - **added — List the project's Gradle tasks** _(ADFA-6373)_ **[verified]** `IdeBuildService.getTasks()` returns the open project's tasks, root project and modules alike, as `GradleTaskInfo(path, name, projectPath, group, description)`. It reflects the last sync: empty before one or with no project open, and a task added since appears after the next. - Needs no permission. Floor `plugin.min_ide_version` at `26.41`: an older IDE has no such + Needs no permission. Floor `plugin.min_ide_version` at `26.42`: an older IDE has no such method or class. - **breaking — `IdeBuildService.executeTasks(vararg String)` needs at least one task** _(ADFA-6373)_ With no tasks it used to run the project's default tasks; it now completes with `false` @@ -197,6 +208,8 @@ milestone. **[verified]** = read from the checked-in ABI dump. **[reconstructed] With no project open, a `workingDirectory` used to be accepted unchecked; `executeCommand` now throws `SecurityException`, as it does for one outside the project. Pass null to run in the default directory. + +### 26.41 — 2026-10-06 - **added — Plugin languages: tree-sitter highlighting and a language server** _(ADFA-4851)_ **[verified]** A plugin implementing `LanguageExtension` returns `LanguageDefinition`s, each claiming file extensions and optionally carrying a `TreeSitterGrammar` and a `LanguageServerDefinition`. @@ -329,6 +342,7 @@ milestone. **[verified]** = read from the checked-in ABI dump. **[reconstructed] no permission: plugins run in-process under the IDE's uid, so a gate would disclose log access, not enforce it. Purely additive (the ABI dump diff is additions only). Floor `plugin.min_ide_version` at `26.41` to use it; an older IDE has no such service. + ### 26.40 — 2026-09-29 - **added — An embedding capability a backend can declare** _(ADFA-6053)_ **[verified]** A backend that has an embedding model can now say so. The only embedding entry point @@ -712,4 +726,7 @@ git tag --list --contains | grep -E '^[0-9]{2}\.[0-9]{2}$' | sort -V | hea ``` When a release is tagged, replace its bucket's `unreleased` with the tag date and move -any entry the tag does not contain up to the next bucket. +any entry the tag does not contain up to the next bucket. The release tags are +lightweight, so the tag date is the tagged commit's date (`git log -1 --format=%cs `). +Do this at every release tag: nothing automates or checks it, and when it was skipped +from 26.41 to 26.48, entries sat up to four releases too early (ADFA-7211). diff --git a/docs/PLUGIN_AUTHORING.md b/docs/PLUGIN_AUTHORING.md index 204f694fc8..9f084d3f17 100644 --- a/docs/PLUGIN_AUTHORING.md +++ b/docs/PLUGIN_AUTHORING.md @@ -133,7 +133,9 @@ won't fail, but the plugin will be hard to identify in the UI. To choose `plugin.min_ide_version`, see the [Plugin API Changelog](PLUGIN_API_CHANGELOG.md) — it maps each plugin -capability to the `YY.WW` release that first shipped it. +capability to the `YY.WW` release that first shipped it. The IDE records and +shows the value but does not enforce it at install, and does not enforce +`plugin.max_ide_version` either. Example (adapted from `apk-viewer-plugin/src/main/AndroidManifest.xml`): diff --git a/docs/plugin-api.md b/docs/plugin-api.md index 40e729aebf..cffff0d7a4 100644 --- a/docs/plugin-api.md +++ b/docs/plugin-api.md @@ -32,7 +32,7 @@ The surface a plugin binds to is broader than one module. All of the following a That is **not** license to break plugins casually. The rule for now: -> Every change to the surface above must be **deliberate, documented, and justified.** Know when you're changing the contract, say so in the PR (what breaks, who's affected, why it's worth it), and record it here or in a changelog. Prefer **additive** changes; gate behavior with `plugin.min_ide_version` / `plugin.max_ide_version` where it helps. +> Every change to the surface above must be **deliberate, documented, and justified.** Know when you're changing the contract, say so in the PR (what breaks, who's affected, why it's worth it), and record it here or in a changelog. Prefer **additive** changes; gate behavior with `plugin.min_ide_version` / `plugin.max_ide_version` where it helps. Neither is enforced at install today (see [PLUGIN_API_CHANGELOG.md](PLUGIN_API_CHANGELOG.md#how-to-use-this)), so a gate only records the requirement. When the API is later frozen, this doc gains a formal compatibility guarantee and (ideally) automated enforcement — see Follow-ups. diff --git a/plugin-api/src/main/java/com/itsaky/androidide/plugins/services/ToolSourceRegistry.java b/plugin-api/src/main/java/com/itsaky/androidide/plugins/services/ToolSourceRegistry.java index 60c6db1768..dc2f6491fc 100644 --- a/plugin-api/src/main/java/com/itsaky/androidide/plugins/services/ToolSourceRegistry.java +++ b/plugin-api/src/main/java/com/itsaky/androidide/plugins/services/ToolSourceRegistry.java @@ -25,7 +25,7 @@ public interface ToolSourceRegistry { * Contract revision, bumped whenever a member is added here. * *

- * It marks the revision, it does not negotiate one: javac inlines a constant into every class that reads it, so a plugin carries the value it compiled against and the host its own, and neither can read the other's. Version compatibility is enforced where the loader already enforces it, by {@code plugin.min_ide_version} in the plugin manifest. + * It marks the revision, it does not negotiate one: javac inlines a constant into every class that reads it, so a plugin carries the value it compiled against and the host its own, and neither can read the other's. Nothing enforces compatibility either: a plugin states the IDE version it needs in {@code plugin.min_ide_version}, which the loader records and the Plugin Manager shows, but the IDE does not compare it with its own version at install, so on an older IDE a member added after it fails at the call with {@code NoSuchMethodError}. */ int CONTRACT_VERSION = 2; From 07478eea643a9e172dcf6c7ee392c7bf3a38867d Mon Sep 17 00:00:00 2001 From: Claude Date: Mon, 30 Nov 2026 18:33:16 +0000 Subject: [PATCH 2/4] ADFA-7211 plugin-api KDoc: the release each API first shipped in The same floors the changelog now corrects, in the KDoc: the terminal service, Gradle task arguments and task list, and the in-process task run (ADFA-6373, ADFA-6385) first shipped in 26.42, not 26.41, and the Quick Build methods (ADFA-6493) in 26.43, not 26.42. Comments only. Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_01Vh2DAZ8yszEP4MqbR9PLba --- .../plugins/extensions/BuildActionExtension.kt | 2 +- .../androidide/plugins/services/IdeServices.kt | 12 ++++++------ .../plugins/services/IdeTerminalService.kt | 2 +- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/plugin-api/src/main/kotlin/com/itsaky/androidide/plugins/extensions/BuildActionExtension.kt b/plugin-api/src/main/kotlin/com/itsaky/androidide/plugins/extensions/BuildActionExtension.kt index d38bdceb68..b3516a567a 100644 --- a/plugin-api/src/main/kotlin/com/itsaky/androidide/plugins/extensions/BuildActionExtension.kt +++ b/plugin-api/src/main/kotlin/com/itsaky/androidide/plugins/extensions/BuildActionExtension.kt @@ -94,7 +94,7 @@ sealed class CommandSpec { * refused. Keep the timeout no longer than the task needs. A cancel or timeout asks Gradle to * stop and completes once it has. * - * Before 26.41 this ran `./gradlew` as a separate process. + * Before 26.42 this ran `./gradlew` as a separate process. */ data class GradleTask( val taskPath: String, diff --git a/plugin-api/src/main/kotlin/com/itsaky/androidide/plugins/services/IdeServices.kt b/plugin-api/src/main/kotlin/com/itsaky/androidide/plugins/services/IdeServices.kt index 8f2c0463da..1b9943c541 100644 --- a/plugin-api/src/main/kotlin/com/itsaky/androidide/plugins/services/IdeServices.kt +++ b/plugin-api/src/main/kotlin/com/itsaky/androidide/plugins/services/IdeServices.kt @@ -448,7 +448,7 @@ interface IdeBuildService { /** * Executes the given Gradle task paths (e.g. ":app:assembleDebug") and completes with - * true on success, false on failure/cancellation. Since 26.41, no tasks, or a task name + * true on success, false on failure/cancellation. Since 26.42, no tasks, or a task name * starting with `-`, completes with false without building. * * Default completes with false so this addition is binary-compatible: hosts that predate @@ -471,8 +471,8 @@ interface IdeBuildService { * Non-empty [arguments] need the `system.commands` permission (`--init-script` runs any code * in the IDE's Gradle daemon); without it this throws [SecurityException]. * - * The default body is not a compatibility shim: an IDE older than 26.41 has no such method - * and the call fails with `NoSuchMethodError`. Floor `plugin.min_ide_version` at 26.41 to use + * The default body is not a compatibility shim: an IDE older than 26.42 has no such method + * and the call fails with `NoSuchMethodError`. Floor `plugin.min_ide_version` at 26.42 to use * it. */ fun executeTasks( @@ -487,7 +487,7 @@ interface IdeBuildService { * down. The cancelled run's own future then completes with [GradleTaskResult.Cancelled]. * Needs the `system.commands` permission; without it this throws [SecurityException]. * - * Floor `plugin.min_ide_version` at 26.41 to use it (see [executeTasks]). + * Floor `plugin.min_ide_version` at 26.42 to use it (see [executeTasks]). */ fun cancelBuild(): CompletableFuture = CompletableFuture.completedFuture(false) @@ -518,7 +518,7 @@ interface IdeBuildService { * reported them at the last sync. Empty when no project is open or it has not synced. A task * added to a build script since then appears only after the next sync. * - * Floor `plugin.min_ide_version` at 26.41 to use it (see [executeTasks]). + * Floor `plugin.min_ide_version` at 26.42 to use it (see [executeTasks]). */ fun getTasks(): List = emptyList() @@ -526,7 +526,7 @@ interface IdeBuildService { * Whether [startQuickBuild] can run for the open project, and if not, why. Needs no permission. * * The default body is not a compatibility shim (see [executeTasks]): floor - * `plugin.min_ide_version` at 26.42 to use the Quick Build methods. + * `plugin.min_ide_version` at 26.43 to use the Quick Build methods. */ fun getQuickBuildAvailability(): QuickBuildAvailability = QuickBuildAvailability.Unavailable(QuickBuildUnavailableReason.NOT_SUPPORTED, "Quick Build is not supported") diff --git a/plugin-api/src/main/kotlin/com/itsaky/androidide/plugins/services/IdeTerminalService.kt b/plugin-api/src/main/kotlin/com/itsaky/androidide/plugins/services/IdeTerminalService.kt index 0d7ae6a2c7..51b53540f9 100644 --- a/plugin-api/src/main/kotlin/com/itsaky/androidide/plugins/services/IdeTerminalService.kt +++ b/plugin-api/src/main/kotlin/com/itsaky/androidide/plugins/services/IdeTerminalService.kt @@ -4,7 +4,7 @@ package com.itsaky.androidide.plugins.services * Service interface for the IDE's terminal environment (bash and the packages installed with it). * * Use [IdeCommandService] to run a command headless; use [runInTerminal] when the user should see - * what ran. Available since 26.41. + * what ran. Available since 26.42. */ interface IdeTerminalService { /** From 03cc7d6cdb1ae55dc0f4f33869005deccac7c359 Mon Sep 17 00:00:00 2001 From: David Schachter Date: Mon, 30 Nov 2026 11:43:29 -0800 Subject: [PATCH 3/4] ADFA-7211 docs: the version fields gate nothing; the 26.44 floor's alternative covers defaulted arguments CodeRabbit on #2335: - docs/plugin-api.md told maintainers to "gate behavior" with plugin.min_ide_version / plugin.max_ide_version, then said neither is enforced. It now says they record the versions a plugin needs, gate nothing (plugin-api has no IDE version to check at runtime either), and that a plugin for older IDEs has to guard its calls to newer API. - The 26.44 entry offered "override every method of the interfaces you implement" as the alternative to the 26.44 floor. An IDE between ADFA-4058 and 26.43 also lacks the interfaces' $default helpers, so a call that omits a defaulted argument of an interface method fails with NoSuchMethodError there. The alternative now also says to pass every argument. Interface methods with defaulted arguments include IdeArchiveService.extract, IdeCommandService.executeCommand, IdeTerminalService.runInTerminal and IdeServices' listFiles and executeTasks. Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_01Vh2DAYT7GPoC2cDzo8LErn --- docs/PLUGIN_API_CHANGELOG.md | 11 +++++++---- docs/plugin-api.md | 2 +- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/docs/PLUGIN_API_CHANGELOG.md b/docs/PLUGIN_API_CHANGELOG.md index d2b8561942..dfea50169c 100644 --- a/docs/PLUGIN_API_CHANGELOG.md +++ b/docs/PLUGIN_API_CHANGELOG.md @@ -114,10 +114,13 @@ milestone. **[verified]** = read from the checked-in ABI dump. **[reconstructed] stays for plugins built since May. A plugin that implements an interface now inherits the body of a method added after it was built instead of failing with `AbstractMethodError`. - A plugin built against this `plugin-api` calls those bodies on the interface, and an IDE built - between ADFA-4058 and 26.43 has none: there, any interface method the plugin does not override - fails with `AbstractMethodError`. Floor `plugin.min_ide_version` at `26.44`, or override every - method of the interfaces you implement. + A plugin built against this `plugin-api` calls those bodies, and the `$default` helpers, on the + interface, and an IDE built between ADFA-4058 and 26.43 has neither: there, any interface method + the plugin does not override fails with `AbstractMethodError`, and a call that omits a defaulted + argument of an interface method (such as `IdeArchiveService.extract` or + `IdeCommandService.executeCommand`) fails with `NoSuchMethodError`. Floor + `plugin.min_ide_version` at `26.44`, or override every method of the interfaces you implement and + pass every argument when you call an interface method. ### 26.43 — 2026-10-20 - **added — Tell whether a server is on this device, the local network or the internet** _(ADFA-6536)_ **[verified]** diff --git a/docs/plugin-api.md b/docs/plugin-api.md index cffff0d7a4..a5173d2f3f 100644 --- a/docs/plugin-api.md +++ b/docs/plugin-api.md @@ -32,7 +32,7 @@ The surface a plugin binds to is broader than one module. All of the following a That is **not** license to break plugins casually. The rule for now: -> Every change to the surface above must be **deliberate, documented, and justified.** Know when you're changing the contract, say so in the PR (what breaks, who's affected, why it's worth it), and record it here or in a changelog. Prefer **additive** changes; gate behavior with `plugin.min_ide_version` / `plugin.max_ide_version` where it helps. Neither is enforced at install today (see [PLUGIN_API_CHANGELOG.md](PLUGIN_API_CHANGELOG.md#how-to-use-this)), so a gate only records the requirement. +> Every change to the surface above must be **deliberate, documented, and justified.** Know when you're changing the contract, say so in the PR (what breaks, who's affected, why it's worth it), and record it here or in a changelog. Prefer **additive** changes, and record the IDE versions a plugin needs in `plugin.min_ide_version` / `plugin.max_ide_version`. Neither is enforced at install today (see [PLUGIN_API_CHANGELOG.md](PLUGIN_API_CHANGELOG.md#how-to-use-this)), and `plugin-api` offers no IDE version to check at runtime, so these values gate nothing: a plugin that must run on an older IDE has to guard its calls to newer API itself (for example by catching `LinkageError`). When the API is later frozen, this doc gains a formal compatibility guarantee and (ideally) automated enforcement — see Follow-ups. From e49d6c2f547810f2adba94963260fad11c55c183 Mon Sep 17 00:00:00 2001 From: David Schachter Date: Mon, 30 Nov 2026 11:58:51 -0800 Subject: [PATCH 4/4] ADFA-7211 changelog: the 26.36 saveFile entry's DefaultImpls note holds until 26.44 The independent review of #2335 found that the 26.36 entry still said plugin-api sets no -Xjvm-default, so the default body rescues no implementer. That was true until 26.44, which set jvmDefault = ENABLE and made interface bodies Java default methods. The entry now says so, and that the body still does nothing for a caller on an IDE without saveFile. Co-Authored-By: Claude Opus 5.5 Claude-Session: https://claude.ai/code/session_01Vh2DAYT7GPoC2cDzo8LErn --- docs/PLUGIN_API_CHANGELOG.md | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/docs/PLUGIN_API_CHANGELOG.md b/docs/PLUGIN_API_CHANGELOG.md index dfea50169c..d70c5b3225 100644 --- a/docs/PLUGIN_API_CHANGELOG.md +++ b/docs/PLUGIN_API_CHANGELOG.md @@ -457,12 +457,14 @@ milestone. **[verified]** = read from the checked-in ABI dump. **[reconstructed] Because an older IDE's `IdeEditorService` has no `saveFile` at all, calling it there fails with `NoSuchMethodError` at the call site — floor - `plugin.min_ide_version` at `26.36` if you call it. The Kotlin `default` body is - not a Java default method: `plugin-api` sets no `-Xjvm-default`, so the compiler - emits an abstract interface method plus a `DefaultImpls` static (both visible in - the ABI dump). It therefore rescues neither a caller nor an implementer compiled - against an older `plugin-api` — the latter gets `AbstractMethodError`. Only the - host's own implementers benefit, and they are recompiled with it. + `plugin.min_ide_version` at `26.36` if you call it. Until 26.44 the Kotlin + `default` body was not a Java default method: `plugin-api` set no `-Xjvm-default`, + so the compiler emitted an abstract interface method plus a `DefaultImpls` static + (both visible in the ABI dump). It therefore rescued neither a caller nor an + implementer compiled against an older `plugin-api` — the latter got + `AbstractMethodError`. Only the host's own implementers benefited, and they are + recompiled with it. Since 26.44 the body is a Java default method (see that + entry); it still does nothing for a caller on an IDE without `saveFile`. - **added — Keystore-backed secret storage for plugins** _(ADFA-5269)_ **[verified]** A plugin that stores a credential can encrypt it with AES/GCM under a hardware-backed