PowerShell / PowerShell/PowerShellEditorServices

Move prompt gathering out of GetSessionDetails

Open
#423 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Area-Extension Terminal Issue-Enhancement
Dominant language
C#
Stars
767
Forks
266
Avg merge
3d 16h
Merged PRs (30d)
1

Description

When I introduced the concept of gathering session details after each command that gets run, I rolled prompt gathering into that to avoid running yet another command each time a prompt is needed. It seems that this causes more problems than necessary because a prompt function that throws errors does not get handled correctly anymore.

I'll move prompt gathering back out into the ConsoleService so that we can check for errors and return a default prompt appropriately.

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 by locating GetSessionDetails and ConsoleService, then trace where prompt gathering and prompt-function errors are handled. Move prompt gathering to ConsoleService and verify that prompt errors produce the default prompt as described in the issue.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp, powershell
Domain
developer-experience, tooling
Issue type
Refactor
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.