Skip to content

Commit

Permalink
ruff
Browse files Browse the repository at this point in the history
  • Loading branch information
javierggt committed Aug 22, 2024
1 parent e85c463 commit 9b2cbed
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions skare3_tools/test_results.py
Original file line number Diff line number Diff line change
Expand Up @@ -66,18 +66,18 @@ def remove(uid=None, directory=None, uids=(), directories=()):
if uid and uid not in uids:
uids += [uid]

directories = [SKARE3_TEST_DATA / directory for directory in directories]
directories = [SKARE3_TEST_DATA / drctry for drctry in directories]
if directory and directory not in directories:
directories += [SKARE3_TEST_DATA / directory]

# make sure all directories are absolute and within the data tree
for directory in directories:
if SKARE3_TEST_DATA not in directory.resolve().parents:
LOGGER.warning(f"warning: {directory} not in SKARE3_DASH_DATA. Ignoring")
for drctry in directories:
if SKARE3_TEST_DATA not in drctry.resolve().parents:
LOGGER.warning(f"warning: {drctry} not in SKARE3_DASH_DATA. Ignoring")
directories = [
directory
for directory in directories
if SKARE3_TEST_DATA in directory.resolve().parents
drctry
for drctry in directories
if SKARE3_TEST_DATA in drctry.resolve().parents
]

# make a list of everything that will be removed
Expand Down

0 comments on commit 9b2cbed

Please sign in to comment.