Skip to content
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

PSReadLine Error / Bug Report #4682

Open
3 tasks done
Q-DavidStein opened this issue Mar 27, 2025 · 1 comment
Open
3 tasks done

PSReadLine Error / Bug Report #4682

Q-DavidStein opened this issue Mar 27, 2025 · 1 comment
Labels
Needs-Triage 🔍 It's a new issue that core contributor team needs to triage.

Comments

@Q-DavidStein
Copy link

Prerequisites

  • Write a descriptive title.
  • Make sure you are able to repro it on the latest released version
  • Search the existing issues, especially the pinned issues.

Exception report

Oops, something went wrong.                                                                                                                                                                                      
Please report this bug with ALL the details below, including both the 'Environment' and 'Exception' sections.                                                                                                    
Please report on GitHub: https://github.com/PowerShell/PSReadLine/issues/new?template=Bug_Report.yaml                                                                                                            
Thank you!                                                                                                                                                                                                       
                                                                                                                                                                                                                 
### Environment                                                                                                                                                                                                  
PSReadLine: 2.3.6+d2e770f93b7a53d8660a6402eb29d1ae1c35e767
PowerShell: 7.5.0
OS: Linux Mint 22.1
BufferWidth: 209
BufferHeight: 29

Last 200 Keys:

 l Backspace Backspace Backspace Backspace Backspace Backspace Backspace Backspace 3 5 1 . x m l Enter
 UpArrow Spacebar - Tab Tab l o Tab Spacebar Tab c o m Tab Enter
 UpArrow Backspace Backspace Backspace Backspace Backspace Backspace Backspace Backspace Backspace Tab Tab b a d Tab Enter
 UpArrow Spacebar - Tab Tab J S Tab Backspace Backspace Backspace Backspace e x Tab Enter
 UpArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow LeftArrow RightArrow 9 Delete RightArrow RightArrow RightArrow RightArrow RightArrow Delete Delete Delete Delete Delete Delete Delete Delete Delete Delete Delete Delete Delete Delete Delete Delete Delete Delete Delete Delete Delete Delete Delete Spacebar Enter
 c a p l i s t Enter
 r e s t a r t - r e q u e s t Spacebar 7 f 1 5 6 a a e - 8 4 a f - 4 1 0 0 - 8 9 9 d - 5 f e a 1 0 f 5 9 b c 7

### Exception

System.InvalidOperationException: Cannot locate the offset in the rendered text that was pointed by the original cursor. Initial Coord: (38, 31) Buffer: (209, 32) Cursor: (85, 28)
   at Microsoft.PowerShell.PSConsoleReadLine.RecomputeInitialCoords(Boolean isTextBufferUnchanged)
   at Microsoft.PowerShell.PSConsoleReadLine.ReallyRender(RenderData renderData, String defaultColor)
   at Microsoft.PowerShell.PSConsoleReadLine.ForceRender()
   at Microsoft.PowerShell.PSConsoleReadLine.SelfInsert(Nullable`1 key, Object arg)
   at Microsoft.PowerShell.PSConsoleReadLine.ProcessOneKey(PSKeyInfo key, Dictionary`2 dispatchTable, Boolean ignoreIfNoAction, Object arg)
   at Microsoft.PowerShell.PSConsoleReadLine.InputLoop()
   at Microsoft.PowerShell.PSConsoleReadLine.ReadLine(Runspace runspace, EngineIntrinsics engineIntrinsics, CancellationToken cancellationToken, Nullable`1 lastRunStatus)

Screenshot

Image

Environment data

PS Version: 7.5.0
PS HostName: ConsoleHost
PSReadLine Version: 2.3.6
PSReadLine EditMode: Emacs
OS: Linux p50 6.8.0-56-generic #58-Ubuntu SMP PREEMPT_DYNAMIC Fri Feb 14 15:33:28 UTC 2025 x86_64 x86_64 x86_64 GNU/Linux
BufferWidth: 209
BufferHeight: 32

Steps to reproduce

Run a local module function and paste in a value using CTRL+SHIFT+V for the input parameter. It's never done this before.

Expected behavior

No exceptions/errors.

Actual behavior

Displayed the error shown above.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Needs-Triage 🔍 It's a new issue that core contributor team needs to triage.
Projects
None yet
Development

No branches or pull requests

2 participants
@Q-DavidStein and others