Skip to content

Error when deleting database that doesn't exist on disk anymore #693

@max-schaefer

Description

@max-schaefer

Describe the bug
When trying to delete a database from the UI that doesn't exist on disk anymore, I sometimes get "Cannot read property 'belongsToSourceArchiveExplorerUri' of undefined", possibly originating here (though this is a guess, since I don't have a stack trace).

To Reproduce

  • Create a new database, for example using codeql test run
  • Import it
  • Exit VSCode
  • Remove the database
  • Start VSCode again; the database now displays a red cross next to it.
  • Try removing the database; the log will show a message about "Removing workspace folder at index -1", possibly caused by the typo fixed in Fix dubious index check #692. The database is not removed.
  • Try removing the database again; the log will show the message mentioned above.

Expected behavior
It should delete the database.

Metadata

Metadata

Assignees

No one assigned

    Labels

    VSCodebugSomething isn't working

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions