Skip to content

✨ feat(sdk): support IntelliJ Platform 262 (2026.2)#186

Merged
gaborbernat merged 4 commits into
mainfrom
migrate-262
May 29, 2026
Merged

✨ feat(sdk): support IntelliJ Platform 262 (2026.2)#186
gaborbernat merged 4 commits into
mainfrom
migrate-262

Conversation

@gaborbernat

Copy link
Copy Markdown
Member

PyCharm 262 (2026.2) reshaped the Python SDK API the plugin builds against, so the 2.3.x line is binary incompatible there and was capped at 261 in #184. This brings the plugin forward onto the 262 API so 2026.2 gets a working build. 🚀

Four call sites had to move: UvSdkAdditionalData now takes interpreter paths as String rather than Path, VirtualEnvSdkFlavor relocated to com.intellij.python.venv.sdk.flavors, the uv icons relocated to com.intellij.python.uv.common.icons, and PythonSdkUtil.isVirtualEnv(String) was removed entirely. The first three are direct swaps. For the last one the detector now infers a virtualenv from the presence of pyvenv.cfg in the environment root, which every modern venv/virtualenv writes and which the uv and conda branches already rely on. One consequence worth noting: a legacy environment with no pyvenv.cfg now reports SYSTEM instead of VIRTUALENV.

The build targets the latest 262 EAP (262.6653.28-EAP-SNAPSHOT, resolved from the snapshots channel), moves sinceBuild to 262, reopens untilBuild, and bumps to 2.4.0-dev (superseding the automated #185). The 261-capped 2.3.x line continues to serve 2026.1, so the two ranges coexist on the Marketplace. Because 2026.2 is still EAP, the API may shift again before GA and need a follow-up.

🤖 Generated with Claude Code

Build 262 reshaped the Python SDK API the plugin relies on:
- UvSdkAdditionalData venv/uv paths are now String, not Path
- VirtualEnvSdkFlavor moved to com.intellij.python.venv.sdk.flavors
- PythonSdkUtil.isVirtualEnv(String) was removed; detect via pyvenv.cfg
- uv icons moved to com.intellij.python.uv.common.icons

Target the 262 EAP build, set sinceBuild=262, reopen untilBuild, and bump
to 2.4.0-dev. The 261-capped 2.3.x line keeps serving 2026.1 users.
@gaborbernat gaborbernat added the enhancement New feature or request label May 29, 2026
EAP-SNAPSHOT builds have no download.jetbrains.com installer; they exist
only as snapshot maven artifacts. Set useInstaller=false (via the
dependency configuration block) so the platform dependency and the
verifier IDEs resolve from the repository.
The 262 VirtualEnvSdkFlavor.getInstance() is a companion-object function
backed by an extension point. mockkStatic(::class) does not intercept it,
so the real lookup ran and threw outside a platform fixture. Use
mockkObject(VirtualEnvSdkFlavor.Companion) instead.
The Professional EAP build shows an evaluation-login dialog on startup that
blocks the headless robot, timing out the interpreter UI tests. Community
resolves the same 262 snapshot, carries every Python SDK API the plugin
touches, and starts without a login wall. The verifier still checks both
Community and Professional.
@gaborbernat gaborbernat merged commit 52932b8 into main May 29, 2026
9 checks passed
@gaborbernat gaborbernat deleted the migrate-262 branch May 29, 2026 13:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant