Commit 315f77d
authored
feat(python-setup): GA the uv-native environment setup (#2124)
## Why
The uv-native "Set up Python environment" flow shipped behind an opt-in
feature flag (`environment.pythonSetup` in
`databricks.experiments.optInto`) because its CLI command, `environments
setup-local`, was only available in custom CLI builds. That command now
ships in the bundled CLI (v1.12.1), so the flag — and the temporary
`cliPathOverride` escape hatch — have served their purpose. This makes
the flow generally available.
## What
- **Remove the opt-in flag.** Drop `environment.pythonSetup` from the
`databricks.experiments.optInto` enum, delete the
`PYTHON_SETUP_FEATURE_ID` constant, and construct the `FeatureManager`
with an empty disabled list.
- **Remove the temporary override.** Delete the
`databricks.experiments.cliPathOverride` setting, its `WorkspaceConfigs`
getter, and `resolveCliPath`; the CLI client always uses the bundled
CLI.
- **Visibility is now purely project-based.** The uv flow shows only for
uv-suitable projects (`isUvSetupSuitable`) — clean uv/greenfield
projects with no competing manager. Projects driven by pip/poetry/conda
keep the legacy checklist via `routeEnvironmentSetup`, exactly as
before.
- **Serverless-version prompt scoped to uv projects.**
`ConnectionCommands.selectServerless` now gates the version prompt on
uv-suitability (injected `isUvSetupVisible`) rather than the flag, so
enabling serverless on a non-uv project keeps the plain, version-less
enable — the old flow for pip users is unchanged.
- **Tests.** Delete the flag-coupling drift test; update the
gate/deps/args/connection tests to the always-on behavior and add a
regression test pinning the pip-path (plain serverless enable, no
version prompt).
## Backward compatibility
- Users who already added `environment.pythonSetup` to
`experiments.optInto` — harmless leftover; the value is simply no longer
read.
- Users who set `experiments.cliPathOverride` — the setting is removed
(VS Code flags it as unknown, benign) and the bundled CLI is used, which
now ships the command.
- No persisted-state or telemetry-schema changes.
## Verification
- `yarn --cwd packages/databricks-vscode build` — clean
- `yarn --cwd packages/databricks-vscode test:lint` — clean
- `yarn --cwd packages/databricks-vscode test:unit` — 829 passing, 0
failing
This pull request and its description were written by Isaac.1 parent 253b366 commit 315f77d
17 files changed
Lines changed: 205 additions & 477 deletions
File tree
- packages/databricks-vscode
- src
- configuration
- feature-manager
- python-setup
- controllers
- utils
- telemetry
- vscode-objs
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1797 | 1797 | | |
1798 | 1798 | | |
1799 | 1799 | | |
1800 | | - | |
1801 | | - | |
| 1800 | + | |
1802 | 1801 | | |
1803 | 1802 | | |
1804 | 1803 | | |
1805 | | - | |
1806 | | - | |
| 1804 | + | |
1807 | 1805 | | |
1808 | 1806 | | |
1809 | 1807 | | |
1810 | 1808 | | |
1811 | 1809 | | |
1812 | 1810 | | |
1813 | | - | |
1814 | | - | |
1815 | | - | |
1816 | | - | |
1817 | | - | |
1818 | 1811 | | |
1819 | 1812 | | |
1820 | 1813 | | |
| |||
Lines changed: 112 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
83 | 83 | | |
84 | 84 | | |
85 | 85 | | |
| 86 | + | |
86 | 87 | | |
87 | 88 | | |
88 | 89 | | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
89 | 94 | | |
90 | 95 | | |
91 | 96 | | |
92 | 97 | | |
93 | 98 | | |
94 | 99 | | |
95 | 100 | | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
96 | 106 | | |
97 | 107 | | |
98 | 108 | | |
| |||
115 | 125 | | |
116 | 126 | | |
117 | 127 | | |
118 | | - | |
| 128 | + | |
| 129 | + | |
119 | 130 | | |
120 | 131 | | |
121 | 132 | | |
122 | 133 | | |
| 134 | + | |
| 135 | + | |
123 | 136 | | |
124 | 137 | | |
125 | 138 | | |
| |||
130 | 143 | | |
131 | 144 | | |
132 | 145 | | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
133 | 149 | | |
134 | 150 | | |
135 | 151 | | |
| |||
191 | 207 | | |
192 | 208 | | |
193 | 209 | | |
194 | | - | |
| 210 | + | |
| 211 | + | |
195 | 212 | | |
196 | 213 | | |
197 | 214 | | |
| |||
224 | 241 | | |
225 | 242 | | |
226 | 243 | | |
227 | | - | |
| 244 | + | |
| 245 | + | |
228 | 246 | | |
229 | 247 | | |
230 | 248 | | |
231 | 249 | | |
232 | 250 | | |
233 | 251 | | |
234 | 252 | | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
| 262 | + | |
| 263 | + | |
| 264 | + | |
| 265 | + | |
| 266 | + | |
| 267 | + | |
| 268 | + | |
| 269 | + | |
| 270 | + | |
| 271 | + | |
| 272 | + | |
| 273 | + | |
| 274 | + | |
| 275 | + | |
| 276 | + | |
| 277 | + | |
| 278 | + | |
| 279 | + | |
| 280 | + | |
| 281 | + | |
| 282 | + | |
| 283 | + | |
| 284 | + | |
| 285 | + | |
| 286 | + | |
| 287 | + | |
| 288 | + | |
| 289 | + | |
| 290 | + | |
| 291 | + | |
| 292 | + | |
| 293 | + | |
| 294 | + | |
| 295 | + | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
| 299 | + | |
| 300 | + | |
| 301 | + | |
| 302 | + | |
| 303 | + | |
| 304 | + | |
| 305 | + | |
| 306 | + | |
| 307 | + | |
| 308 | + | |
| 309 | + | |
| 310 | + | |
| 311 | + | |
| 312 | + | |
| 313 | + | |
| 314 | + | |
| 315 | + | |
| 316 | + | |
| 317 | + | |
| 318 | + | |
| 319 | + | |
| 320 | + | |
| 321 | + | |
| 322 | + | |
| 323 | + | |
| 324 | + | |
| 325 | + | |
| 326 | + | |
| 327 | + | |
| 328 | + | |
| 329 | + | |
| 330 | + | |
| 331 | + | |
| 332 | + | |
| 333 | + | |
| 334 | + | |
| 335 | + | |
| 336 | + | |
| 337 | + | |
| 338 | + | |
| 339 | + | |
| 340 | + | |
| 341 | + | |
| 342 | + | |
| 343 | + | |
235 | 344 | | |
236 | 345 | | |
Lines changed: 19 additions & 13 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
24 | 24 | | |
25 | 25 | | |
26 | 26 | | |
27 | | - | |
28 | | - | |
29 | | - | |
30 | | - | |
| 27 | + | |
31 | 28 | | |
32 | 29 | | |
33 | 30 | | |
| |||
98 | 95 | | |
99 | 96 | | |
100 | 97 | | |
101 | | - | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
102 | 107 | | |
103 | 108 | | |
104 | 109 | | |
| |||
294 | 299 | | |
295 | 300 | | |
296 | 301 | | |
297 | | - | |
298 | | - | |
299 | | - | |
300 | | - | |
301 | | - | |
302 | | - | |
| 302 | + | |
| 303 | + | |
| 304 | + | |
| 305 | + | |
| 306 | + | |
| 307 | + | |
| 308 | + | |
303 | 309 | | |
304 | 310 | | |
305 | | - | |
| 311 | + | |
306 | 312 | | |
307 | 313 | | |
308 | | - | |
| 314 | + | |
309 | 315 | | |
310 | 316 | | |
311 | 317 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
47 | 47 | | |
48 | 48 | | |
49 | 49 | | |
50 | | - | |
51 | | - | |
52 | | - | |
53 | | - | |
54 | | - | |
| 50 | + | |
55 | 51 | | |
56 | 52 | | |
57 | 53 | | |
| |||
63 | 59 | | |
64 | 60 | | |
65 | 61 | | |
66 | | - | |
67 | | - | |
68 | | - | |
69 | | - | |
70 | | - | |
| 62 | + | |
71 | 63 | | |
72 | 64 | | |
73 | 65 | | |
| |||
900 | 892 | | |
901 | 893 | | |
902 | 894 | | |
903 | | - | |
904 | | - | |
905 | | - | |
906 | | - | |
907 | | - | |
908 | | - | |
909 | | - | |
| 895 | + | |
910 | 896 | | |
911 | 897 | | |
912 | 898 | | |
| |||
921 | 907 | | |
922 | 908 | | |
923 | 909 | | |
924 | | - | |
925 | | - | |
926 | | - | |
| 910 | + | |
| 911 | + | |
| 912 | + | |
927 | 913 | | |
928 | 914 | | |
929 | 915 | | |
| |||
932 | 918 | | |
933 | 919 | | |
934 | 920 | | |
935 | | - | |
936 | | - | |
937 | | - | |
938 | | - | |
939 | | - | |
| 921 | + | |
940 | 922 | | |
941 | 923 | | |
942 | 924 | | |
| |||
958 | 940 | | |
959 | 941 | | |
960 | 942 | | |
961 | | - | |
962 | | - | |
963 | | - | |
| 943 | + | |
| 944 | + | |
| 945 | + | |
964 | 946 | | |
965 | 947 | | |
966 | 948 | | |
| |||
984 | 966 | | |
985 | 967 | | |
986 | 968 | | |
987 | | - | |
988 | 969 | | |
989 | 970 | | |
990 | 971 | | |
| |||
1355 | 1336 | | |
1356 | 1337 | | |
1357 | 1338 | | |
1358 | | - | |
| 1339 | + | |
| 1340 | + | |
| 1341 | + | |
| 1342 | + | |
| 1343 | + | |
1359 | 1344 | | |
1360 | 1345 | | |
1361 | 1346 | | |
| |||
Lines changed: 1 addition & 17 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
8 | 8 | | |
9 | 9 | | |
10 | 10 | | |
11 | | - | |
12 | | - | |
13 | | - | |
14 | | - | |
15 | | - | |
16 | | - | |
17 | | - | |
18 | | - | |
19 | | - | |
20 | | - | |
21 | | - | |
22 | | - | |
23 | | - | |
24 | | - | |
25 | | - | |
26 | | - | |
27 | | - | |
| 11 | + | |
28 | 12 | | |
29 | 13 | | |
30 | 14 | | |
| |||
0 commit comments