Skip to content

System.PlatformNotSupportedException while running under tmux in iTerm2 on MacOS #654

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
bgshacklett opened this issue Mar 22, 2018 · 8 comments
Labels
Issue-Bug It either shouldn't be doing this or needs an investigation.
Milestone

Comments

@bgshacklett
Copy link

Environment data

PS version: 6.0.2
PSReadline version: 2.0.0-beta1
os: Darwin BrianShlettsMBP.attlocal.net 17.4.0 Darwin Kernel Version 17.4.0: Sun Dec 17 09:19:54 PST 2017; root:xnu-4570.41.2~1/RELEASE_X86_64 x86_64
PS file version:
PS /Users/brianshacklett/.vim>

Steps to reproduce or exception report

PS /Users/brianshacklett/.vim>
Oops, something went wrong.  Please report this bug with the details below.
Report on GitHub: https://github.com/lzybkr/PSReadLine/issues/new
-----------------------------------------------------------------------
Last 77 Keys:
 t m u x Space - - v e r s i o n Enter
 UpArrow Ctrl+c UpArrow Backspace Backspace Backspace Backspace Backspace Backspace Backspace Backspace V Enter
 Ctrl+c Ctrl+b % Backspace Ctrl+b % Backspace Ctrl+b 5 Backspace Ctrl+b Backspace Backspace j Backspace g i t Space s t a t u s Enter
 v i m Space . g i t m o d u l e s Enter
 Enter
 Ctrl+l Ctrl+l Ctrl+l Ctrl+l Ctrl+l Ctrl+l

Exception:
System.PlatformNotSupportedException: Operation is not supported on this platform.
   at System.ConsolePal.SetWindowPosition(Int32 left, Int32 top)
   at Microsoft.PowerShell.PSConsoleReadLine.ProcessOneKey(ConsoleKeyInfo key, Dictionary`2 dispatchTable, Boolean ignoreIfNoAction, Object arg)
   at Microsoft.PowerShell.PSConsoleReadLine.InputLoop()
   at Microsoft.PowerShell.PSConsoleReadLine.ReadLine(Runspace runspace, EngineIntrinsics engineIntrinsics)
-----------------------------------------------------------------------
@lzybkr lzybkr added the Issue-Bug It either shouldn't be doing this or needs an investigation. label Mar 22, 2018
@lzybkr lzybkr added this to the 2.0.0-beta2 milestone Mar 22, 2018
@bgshacklett bgshacklett changed the title Crash while running under tmux in iTerm2 on MacOS System.PlatformNotSupportedException while running under tmux in iTerm2 on MacOS Apr 3, 2018
@lzybkr lzybkr modified the milestones: 2.0.0-beta2, 2.0.0-beta3 Jun 4, 2018
This was referenced Oct 19, 2018
@petegooch
Copy link

Ditto.

PS version: 6.1.0
PSReadline version: 2.0.0-beta3
os: Linux pitrlaptop 4.15.0-36-generic #39-Ubuntu SMP Mon Sep 24 16:19:09 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux
PS file version:
<nothing here?>

@SteveL-MSFT SteveL-MSFT self-assigned this Oct 31, 2018
@SteveL-MSFT
Copy link
Member

Not reproing for me on Mojave and PSCore 6.1 or PSCore 6.2-preview.1 with PSReadLine 2.0.0-beta2.

tmux
pwsh
vim

all works

@lzybkr
Copy link
Contributor

lzybkr commented Oct 31, 2018

The TERM setting might be important for this issue.

@SteveL-MSFT
Copy link
Member

SteveL-MSFT commented Nov 1, 2018

Using iTerm2 on Mojave (newer than original issue from @bgshacklett above) with tmux starting pwsh then vim works fine. TERM was screen in this case. Using the built in Terminal app on Mojave, TERM is xterm-256color which also worked. Tried both PSCore6.0.4 and PSCore6.2-Preview.1.

@SteveL-MSFT SteveL-MSFT removed their assignment Nov 1, 2018
@bgshacklett
Copy link
Author

I'll update my config and test as soon as I have a moment.

@DarkRTA
Copy link

DarkRTA commented Dec 17, 2018

I am also getting this issue upon pressing ctrl-l twice.

For reference my $TERM environment variable was set to xterm-256color. This only seems to happen when i press ctrl-l and the terminal was cleared recently.

Enviroment Data

PS version: 6.1.1
PSReadline version: 2.0.0-beta3
os: Linux [hostname removed] 4.15.0-42-generic #45-Ubuntu SMP Thu Nov 15 19:32:57 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux
PS file version:  6.1.1.0 

Steps to reproduce

Last 2 Keys:

 Ctrl+l Ctrl+l

Exception:

System.PlatformNotSupportedException: Operation is not supported on this platform.
   at System.ConsolePal.SetWindowPosition(Int32 left, Int32 top)
   at Microsoft.PowerShell.PSConsoleReadLine.ProcessOneKey(ConsoleKeyInfo key, Dictionary`2 dispatchTable, Boolean ignoreIfNoAction, Object arg)
   at Microsoft.PowerShell.PSConsoleReadLine.InputLoop()
   at Microsoft.PowerShell.PSConsoleReadLine.ReadLine(Runspace runspace, EngineIntrinsics engineIntrinsics, CancellationToken cancellationToken)

@SteveL-MSFT
Copy link
Member

This was repro'ing for me with beta.3, but using the latest built from master doesn't repro.

@lzybkr
Copy link
Contributor

lzybkr commented Dec 18, 2018

#790 must have fixed this, so I'll go ahead and close this issue.

@lzybkr lzybkr closed this as completed Dec 18, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Issue-Bug It either shouldn't be doing this or needs an investigation.
Projects
None yet
Development

No branches or pull requests

5 participants