microsoft / microsoft/vscode-python-environments

Expose helper for resolving python-env search paths (getAllExtraSearchPaths)

Đang mở
#960 1 bình luận 0 reaction 1 người được giao Xem trên GitHub

@eleanorjboyd đang làm issue này rồi.

Từ ngày 11/11/2025.

area-api feature-request help wanted needs PR
Ngôn ngữ chính
TypeScript
Star
138
Fork
62
Merge trung bình
1 ngày 4 giờ
Pull request đã merge (30 ngày)
35

Mô tả

Summary

Extensions that integrate with ms-python.vscode-python-envs need the canonical list of user-configured search paths. Today that logic lives in src/managers/common/nativePythonFinder.ts#getAllExtraSearchPaths, but it isn’t exposed through the public API, so consumers have to re-implement a fairly large helper.

What we’d like

Export a function (or add an API surface) that returns the same array of search directories the native finder uses—covering legacy python.venvPath / venvFolders, python-env.globalSearchPaths, workspaceSearchPaths, validation, and relative-path resolution across multi-root workspaces.

Why

In order to use this for another environment plugin, such as the pixi env manager (https://github.com/renan-r-santos/pixi-code), one would have to copy over that code verbatim so it can stay behaviourally aligned with ms-python.vscode-python-envs. Keeping two copies in sync is brittle; a shared helper would make it much easier to keep the behaviour consistent by default.

Happy to send a PR once there’s agreement on where such an export should live.

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Đánh giá

Issue này chưa được đánh giá.

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.