Vector35/snippets

Snippet Editor fails to open after closing any file tab

Closed this issue · 2 comments

Version and Platform (required):

  • Binary Ninja Version: 3.1.3592-dev
  • OS: Windows
  • OS Version: 11
  • CPU Architecture: x64

Bug Description:
The Snippet Editor window will not open if any file tabs have been closed.

Steps To Reproduce:
Please provide all steps required to reproduce the behavior:

  1. Open any number of files for analysis
  2. Close a file tab
  3. Attempt to open the Snippet Editor
  4. See error in log

Expected Behavior:
I expected Snippet Editor to open regardless of what tabs have been closed.

Screenshots:
If applicable, please add screenshots here to help explain your problem.

Additional Information:
After closing any tab and attempting to open Snippets, the following output can be seen in the log:

Traceback (most recent call last):
  File "C:\Users\<USER>\AppData\Roaming\Binary Ninja\plugins\snippets-master\__init__.py", line 707, in launchPlugin
    snippets.show()
RuntimeError: Internal C++ object (Snippets) already deleted.

Restarting Binary Ninja is required to open the Snippet Editor again.

This is a dupe but on another repo that I'm about to migrate it to. Appreciate the heads up, it's unfortunately a side effect of a change a while ago that made snippets non-modal which was nice to be able to flip back and forth but it wasn't designed for that and this is the side effect of it.

Duplicate of #23