posit-dev / posit-dev/positron

Project Wizard: sort interpreters by version within each runtime source group

Open
#4,030 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

area: folder template enhancement
Dominant language
TypeScript
Stars
4.3k
Forks
184
Avg merge
1d 9h
Merged PRs (30d)
195

Description

Background

  • The interpreters shown in the Python Environment Step and R Configuration Step are grouped by runtime source (e.g. Pyenv, System, Global, etc.), but not explicitly sorted by version within each group
  • Generally, the dropdown list looks to be sorted as it seems interpreter discovery/registration occurs in some sort of alphabetical/numerical order
  • However, it seems like sometimes the descending version order is not preserved, possibly because an interpreter gets saved as a "preferred interpreter" and its discovery and registration may be prioritized
  • We should apply a simple sort within each runtime source group to order them by version (descending, i.e. newest version towards the top)
Example from Project Wizard Python Environment Step

missing_sorting_python_runtimes

Relevant Code

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start in src/vs/workbench/browser/positronNewProjectWizard/utilities/interpreterDropDownUtils.ts at interpretersToDropdownItems. Trace how runtime source groups and interpreter versions are represented, then add the requested ordering within each group. Done means the Project Wizard Python and R interpreter dropdowns show newest versions first while preserving runtime source groups.

Written by the indexing model from the issue text.

Assessment

Tech stack
typescript
Domain
frontend
Issue type
Feature
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.