Skip to content

Commit

Permalink
Merge pull request #32 from instadeepai/fix/support_parent_rel_paths
Browse files Browse the repository at this point in the history
fix: error when vault's rel_dir is a parent directory
  • Loading branch information
EdanToledo authored Aug 29, 2024
2 parents e03c4af + f5819f0 commit 0dffe1b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion flashbax/vault/vault.py
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,8 @@ def __init__( # noqa: CCR001
"""
# Get the base path for the vault and the metadata path
vault_str = vault_uid if vault_uid else datetime.now().strftime("%Y%m%d%H%M%S")
self._base_path = os.path.join(os.getcwd(), rel_dir, vault_name, vault_str)
base_path_unnorm = os.path.join(os.getcwd(), rel_dir, vault_name, vault_str)
self._base_path = os.path.normpath(base_path_unnorm)
metadata_path = epath.Path(os.path.join(self._base_path, METADATA_FILE))

# Check if the vault exists, otherwise create the necessary dirs and files
Expand Down

0 comments on commit 0dffe1b

Please sign in to comment.