Skip to content

chore: (docs) document API version support and deprecation policy @W-12345678@ - #692

Open
rax-it wants to merge 2 commits into
mainfrom
rv/api-version-support-policy
Open

rax-it wants to merge 2 commits into
mainfrom
rv/api-version-support-policy

Conversation

@rax-it

@rax-it rax-it commented Oct 9, 2026

Copy link
Copy Markdown
Contributor

What does this PR do?

Records the API version support policy agreed in #platform-cli, so we don't have to dig through Slack next time. Adds an "API version support" section to CONTRIBUTING.md:

  • Bundles: why each API version ships its own @lwc/sfdx-local-dev-dist bundle (it includes that release's LWC compiler).
  • Version selection: --api-version, then org-api-version config, then the Dev Hub's API version. So usage tapers off after R2b instead of stopping.
  • Removal process: follows the 4-month CLI deprecation policy. Deprecate at release N R2b, check telemetry, remove at N+1 R2b.
  • Telemetry: where to find it (CLI Azure Application Insights) and how to get access.
  • Decision log: API 66.0 is deprecated at 264 R2b and removed at 266 R2b. Includes 180-day usage data.

Also replaces the stale "62.0-65.0" note in .cursorrules with a pointer to the new section.

What issues does this PR fix or reference?

🤖 Generated with Claude Code

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@rax-it
rax-it requested review from a team as code owners October 9, 2026 17:10
@github-actions

github-actions Bot commented Oct 9, 2026

Copy link
Copy Markdown

This PR lacks any commits of the 'fix' or 'feat' type, and therefore will not trigger a release. To silence all further warnings, react to this warning comment (or any other) with the 👀 emoji.

NOTE: If your repo uses squash commits, make sure to add the appropriate conventional commit prefix (e.g., 'fix:', 'feat:', 'chore:', etc) in the squash commit message.

@rax-it rax-it changed the title docs: document API version support and deprecation policy chore(docs): document API version support and deprecation policy Oct 9, 2026
@rax-it rax-it changed the title chore(docs): document API version support and deprecation policy chore: (docs) document API version support and deprecation policy Oct 9, 2026
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@rax-it rax-it changed the title chore: (docs) document API version support and deprecation policy chore: (docs) document API version support and deprecation policy @W-12345678@ Oct 9, 2026
Comment thread CONTRIBUTING.md
- If the release to NPM doesn't happen, you can manually [run a release](https://github.com/salesforcecli/plugin-lightning-dev/actions/workflows/create-github-release.yml) via Github actions or by submitting a [release PR](https://github.com/salesforcecli/plugin-lightning-dev/pull/299).
- Create a [patch branch pull request](https://github.com/salesforcecli/plugin-lightning-dev/commit/ef98bd9c407a7d9817850559e5b82a4fec92fb90) on the \*-patch branch to release the pre-release version of the plugin. Ensure this step completes successfully and has released a newly tagged "prerelease" version of the plugin to NPM.

R2b Release

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Add steps to this section:

  1. Remove any deprecated API versions
  2. Mark the just-finished release as deprecated

Removing stuff is a breaking change, so we'll need to do a major release every R2b. The table below implies we're already meant to do a major release, so double check the instructions.

Comment thread CONTRIBUTING.md
Comment on lines +76 to +88
### Removing a version

Removing a version is a breaking change, so it follows the [Salesforce CLI deprecation policy](https://developer.salesforce.com/docs/platform/salesforce-cli-reference/guide/cli_reference_deprecation.html): 4 months' notice, which is roughly one release.

1. Deprecate the version at release N R2b. The plugin doesn't have a deprecation mechanism yet. The intended approach:
- Add a `deprecated` field to the version's `apiVersionMetadata` entry.
- When a command selects that version, print a warning with `this.warn()`.
- Don't use `Lifecycle.emitWarning()`: `SfCommand` only prints those when the command exits, and `lightning dev` commands are long-running.
- Also announce the deprecation in the release notes.
2. Check usage telemetry before removing it (see below).
3. Remove it at release N+1 R2b.

The new version is added at the start of the N+1 rollout, but the old one can't be removed until R2b. So the plugin briefly ships one extra bundle.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

There's already a section above for R2b, move this into there.

Comment thread CONTRIBUTING.md
Comment on lines +90 to +95
### Usage telemetry

Command executions by API version are in the CLI's Azure Application Insights. To get access, follow [DX Telemetry - Azure Application Insights Access](https://docs.google.com/document/d/1mHWon34OUj67CnKUdGGB7nrpTtDBx_9OcUhl79tVF-A/edit?tab=t.0).

The telemetry doesn't show whether a version was picked by default or set explicitly. Judge removal on the trend over a set window after release, not a single snapshot.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Suggested change
### Usage telemetry
Command executions by API version are in the CLI's Azure Application Insights. To get access, follow [DX Telemetry - Azure Application Insights Access](https://docs.google.com/document/d/1mHWon34OUj67CnKUdGGB7nrpTtDBx_9OcUhl79tVF-A/edit?tab=t.0).
The telemetry doesn't show whether a version was picked by default or set explicitly. Judge removal on the trend over a set window after release, not a single snapshot.
  1. We shouldn't link to internal docs from a public repo.
  2. Because we've decided on the deprecation policy, we don't need to care about telemetry for contributing.

Comment thread CONTRIBUTING.md
Comment on lines +97 to +100

| Date | Decision | Source |
| ---------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| 2026-10-09 | Keep API 66.0 through the 264 rollout. Deprecate it at 264 R2b and remove it at 266 R2b. 180-day usage: 66.0: 8,514 executions / 1,503 orgs; 67.0: 17,273 / 1,974; 68.0: 2,688 / 362. | [#platform-cli](https://salesforce-internal.slack.com/archives/C01LKDT1P6J/p1791556792551479), [original request](https://salesforce-internal.slack.com/archives/C05P1MZ2DN2/p1790887576398399) |

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Suggested change
| Date | Decision | Source |
| ---------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| 2026-10-09 | Keep API 66.0 through the 264 rollout. Deprecate it at 264 R2b and remove it at 266 R2b. 180-day usage: 66.0: 8,514 executions / 1,503 orgs; 67.0: 17,273 / 1,974; 68.0: 2,688 / 362. | [#platform-cli](https://salesforce-internal.slack.com/archives/C01LKDT1P6J/p1791556792551479), [original request](https://salesforce-internal.slack.com/archives/C05P1MZ2DN2/p1790887576398399) |
  1. Internal
  2. Not particularly relevant to contributing

Comment thread CONTRIBUTING.md
Comment on lines +66 to +75
### How users select a version

The bundle is picked from the org connection's API version, not the org's release:

- `lightning dev app|component|site --api-version <version>`, otherwise
- the `org-api-version` config value, otherwise
- the Dev Hub's API version.

So an R2b rollout shifts the default but never drops a version's usage to zero. Users and projects can pin an older version, and orgs don't all upgrade at the same moment. Expect usage to taper off after rollout.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Suggested change
### How users select a version
The bundle is picked from the org connection's API version, not the org's release:
- `lightning dev app|component|site --api-version <version>`, otherwise
- the `org-api-version` config value, otherwise
- the Dev Hub's API version.
So an R2b rollout shifts the default but never drops a version's usage to zero. Users and projects can pin an older version, and orgs don't all upgrade at the same moment. Expect usage to taper off after rollout.

Usage is described in the README, and this isn't particularly relevant to contributing.

Comment thread CONTRIBUTING.md

## API version support

Each supported API version ships its own `@lwc/sfdx-local-dev-dist-<version>` bundle (aliased in `package.json`, listed in `apiVersionMetadata`). Bundles can't be shared across versions because each one includes that release's LWC compiler. Every bundle adds significant install size, so plan version removals as well as additions.

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Suggested change
Each supported API version ships its own `@lwc/sfdx-local-dev-dist-<version>` bundle (aliased in `package.json`, listed in `apiVersionMetadata`). Bundles can't be shared across versions because each one includes that release's LWC compiler. Every bundle adds significant install size, so plan version removals as well as additions.
Because Salesforce releases are deployed in a staggered manner, this plugin supports multiple API versions at a time. Because users can manually specify an API version to use, this plugin deprecates each API version once rollout of the following version has completed, and removes each deprecated version after one release.
Supported versions are listed in `apiVersionMetadata` in `package.json`.

The motivation is more important than the technical details here. (And the technical details may change when we make changes to add deprecation warnings.)

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.

2 participants