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

System.NullReferenceException when attempting to paste text in highlighted block #5881

Closed
GitBlanton opened this issue Nov 13, 2019 · 1 comment

Comments

@GitBlanton
Copy link

Describe the bug
When attempting to paste text from the clipboard to highlighted block of text (ie, hold ALT and then left-click the mouse to highlight a block of text that spans several rows and columns), an "unexpected error" occurred.

Steps to Reproduce

  1. Select a snippet of text (1 row, 10 characters, for example) and copy to the clipboard with Ctrl-C.
  2. Hold ALT, then left-click the mouse to highlight a section of text that will be replaced by the clipboard contents.
  3. Paste text with Ctrl-V. At this point the error occurred.

Expected behavior
Expected behavior is that each row of the highlighted text would be replaced by the contents of the clipboard.

Additional context and screenshots
[Add any other information such as screenshots, error message, or stack trace]
[Window Title]
devenv.exe

[Main Instruction]
An unexpected error occurred

[Content]
Please press Ctrl+C to copy the contents of this dialog and report this error to our issue tracker.

[^] Hide details [Close]

[Expanded Information]

Build: 15.9.18254.1

System.NullReferenceException: Object reference not set to an instance of an object.
   at Microsoft.PythonTools.Intellisense.CompletionSessionExtensions.SetTriggerCharacter(IIntellisenseSession session, Char triggerChar)
   at Microsoft.PythonTools.Intellisense.IntellisenseController.<TriggerCompletionSession>d__43.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at Microsoft.PythonTools.Infrastructure.TaskExtensions.ReThrowTaskException(Object state)
   at Microsoft.PythonTools.Infrastructure.TaskExtensions.DoNotWait(Task task)
   at Microsoft.PythonTools.Language.EditFilter.ExecWorker(Guid& pguidCmdGroup, UInt32 nCmdID, UInt32 nCmdexecopt, IntPtr pvaIn, IntPtr pvaOut)
   at Microsoft.PythonTools.Language.EditFilter.Exec(Guid& pguidCmdGroup, UInt32 nCmdID, UInt32 nCmdexecopt, IntPtr pvaIn, IntPtr pvaOut)
--- End of stack trace from previous location where exception was thrown ---
   at Microsoft.VisualStudio.Telemetry.WindowsErrorReporting.WatsonReport.GetClrWatsonExceptionInfo(Exception exceptionObject)

Sample
VisualStudio crash, editor view (2019-11-13)
Code

N/A, error occurred during editing of code.  See attached image for more info.

Diagnostics file
The diagnostics file contains information such as the Python version, environments, loaded assemblies, configuration options, etc. This file makes it easier for us to reproduce and fix bugs, so we would really appreciate it if you could provide it to us. This file can be generated by going to Tools->Options->Python->Diagnostics.
You can attach the file to this issue or email it to us at ptvshelp@microsoft.com. If you email it, please add a link to this issue.

XXX

Diagnostic Info 2019-11-13T161846.txt

@bschnurr
Copy link
Member

this issue seems to be a duplicate of #4762

Please update to VS 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants