Skip to content

TPI: New Project #457

@eleanorjboyd

Description

@eleanorjboyd

Refs:

Complexity: 5

Create Issue


🧪 Repo & Project Info
Extension Required: Python Environments Extension
Sample requirements.txt:

txt
Copy
Edit
requests==2.31.0
numpy==1.26.4

Multiroot Repos for Testing:
Single environment shared across folders and separate environment per folder: repo

🛠 Setup

  • Open VS Code
  • Confirm the Python Environments Extension is installed
  • Open the Python side panel
  • Click the “New Project” icon (📂➕ at the top of the panel)

✅ Part 1: Script Flow – No Environment Prompt

  • Click "Create New"
  • Choose “New Python Script”
  • Confirm:
    • A single .py file is created in the selected folder
    • You are not prompted to create an environment

✅ Part 2: Package Flow – Auto Environment Creation

  • create a requirements.txt file
  • Click "Create New"
  • Choose “New Python Package”
  • Choose to create a venv as well
    Confirm:
  • A folder is with your project name
  • A virtual environment is created
  • The interpreter is automatically selected
  • the project shows up in your "python project" section with the right env
  • Confirm your requirements.txt file is detected and its pkgs are installed
  • vscode/settings.json incldues your new pkg

✅ Part 3: Multi-root Workspace Scenarios

🔹 Monorepo – Shared Environment Across Folders

  • Open the workspace with multiple folders
  • Run “New Project” in one subfolder and create an environment
  • Confirm:
  • Only one environment is created
  • .vscode/settings.json is updated appropriately specifically that it has the workspace as an argument in settings object
  • only one new project shows up in the "Python Project" UI

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions