Skip to content

Blank lines not permitted after operator in specific terminals #1088

@vexx32

Description

@vexx32

Enter the following directly into terminal with Enter or Shift+Enter between lines:

5 +

5 -

10

In PowerShell's default terminal, this works perfectly and lines are allowed to be continued.

However, in a VS Code pwsh terminal (not the vscode-powershell Integrated Terminal, just a regular one) and in the new Windows Terminal, a parsing error is reported as soon as the blank line is entered, not allowing any time to add additional input.

This works as expected when executing a stored script file. I suspect this is a bug in PSReadLine, but I suppose it's possible that the bug comes from Windows Terminal and VS Code's terminal, this just seems like the most logical place to start. 🙂

Environment data

Windows Terminal

PS version: 7.0.0-preview.3
PSReadline version: 2.0.0-beta5
os: 10.0.18362.1 (WinBuild.160101.0800)
PS file version: 7.0.0.0
HostName: ConsoleHost (Windows Terminal)
BufferWidth: 120
BufferHeight: 27

VS Code Terminal

PS version: 7.0.0-preview.4
PSReadline version: 2.0.0-beta5
os: 10.0.18362.1 (WinBuild.160101.0800)
PS file version: 7.0.0.0
HostName: ConsoleHost
BufferWidth: 221
BufferHeight: 16

Steps to reproduce or exception report

  1. Open terminal
  2. Enter aforementioned simple expression with empty lines in between
  3. See error.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions