Skip to content

don't create a jabs directory if the user selects a project directory that doesn't contain videos - #251

Merged
gbeane merged 4 commits into
mainfrom
avoid-creating-jabs-directory-when-user-selects-wrong-dir
Dec 30, 2025
Merged

don't create a jabs directory if the user selects a project directory that doesn't contain videos#251
gbeane merged 4 commits into
mainfrom
avoid-creating-jabs-directory-when-user-selects-wrong-dir

Conversation

@gbeane

@gbeane gbeane commented Dec 26, 2025

Copy link
Copy Markdown
Collaborator

if the user selects the wrong directory, JABS always creates the "jabs" subdirectory. If the user tries to open a project without any videos or pose files, we assume they selected the wrong directory and abort

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Prevents JABS from creating the "jabs" subdirectory when a user selects an invalid project directory that lacks video or pose files, helping avoid clutter from accidental directory selections.

  • Added validation to check for video and pose files before creating the jabs directory
  • Updated create_directories method with an optional validate parameter
  • Raises ValueError when attempting to create directories in an invalid project location

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/jabs/project/project_paths.py Outdated
Comment thread src/jabs/project/project_paths.py Outdated
@gbeane
gbeane requested a review from bergsalex December 26, 2025 01:24
@gbeane gbeane self-assigned this Dec 26, 2025
gbeane and others added 2 commits December 25, 2025 20:24
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
@gbeane
gbeane requested a review from Copilot December 26, 2025 01:35

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 5 out of 5 changed files in this pull request and generated 1 comment.


💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/jabs/project/project.py
@gbeane
gbeane merged commit fd5f108 into main Dec 30, 2025
2 checks passed
@gbeane
gbeane deleted the avoid-creating-jabs-directory-when-user-selects-wrong-dir branch December 30, 2025 18:04
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

Successfully merging this pull request may close these issues.

4 participants