diff --git a/leverage/path.py b/leverage/path.py index a6564d8..9a53852 100644 --- a/leverage/path.py +++ b/leverage/path.py @@ -67,9 +67,9 @@ def get_account_path(): cur_path = Path(get_working_path()) prev_path = cur_path - # NOTE: currently we only support up to 5 subdir levels. Normally we use + # NOTE: currently we only support up to 8 subdir levels. Normally we use # only 2 subdirectories so this should be enough for most cases. - for _ in range(5): + for _ in range(8): if cur_path.resolve() == root_path: break diff --git a/tests/test_path.py b/tests/test_path.py index c90a4c8..2aa7796 100644 --- a/tests/test_path.py +++ b/tests/test_path.py @@ -72,7 +72,7 @@ def test_get_root_path(): def test_get_account_path(monkeypatch, tmp_path): # Make a deep directory structure root_dir = leaf_dir = tmp_path - leaf_dir = leaf_dir / "subdir" / "subdir" / "subdir" / "subdir" + leaf_dir = leaf_dir / "subdir" / "subdir" / "subdir" / "subdir" / "subdir" / "subdir" / "subdir" leaf_dir.mkdir(parents=True) monkeypatch.setattr(lepath, "get_root_path", lambda: root_dir)