Skip to content

Library reopen doesn't check to see if path is valid #118

Closed
@Loran425

Description

@Loran425

Expected Behavior

When opening the program if the saved library is no longer valid the program will show an information or error prompt informing the user of the error.

Current Behavior

If the library path is no longer valid, TagStudio will attempt to open the old library with an error in the terminal but will not tell the user of the error via the interface.

Possible Solution

Verify the library path is None or an existing directory when starting up if not either of these, show a popup informing the user.

Steps to Reproduce

  1. Open a library
  2. Close Tagstudio
  3. Delete or rename the library folder in the file manager
  4. Reopen Tagstudio
[ERROR] No existing TagStudio library found at 'C:\Users\Loran425\Pictures\Item Icons\tradingicons\Testing'. Creating one.
Traceback (most recent call last):
  File "C:\Users\Loran425\PycharmProjects\TagStudio\tagstudio\src\core\library.py", line 555, in create_library
    self.verify_ts_folders()
  File "C:\Users\Loran425\PycharmProjects\TagStudio\tagstudio\src\core\library.py", line 575, in verify_ts_folders
    os.mkdir(full_ts_path)
FileNotFoundError: [WinError 3] The system cannot find the path specified: 'C:\\Users\\Loran425\\Pictures\\Item Icons\\tradingicons\\Testing\\.TagStudio'

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type: BugSomething isn't working as intendedgood first issueGood for newcomers

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions