fixes git repo issue
This commit is contained in:
parent
51d06cff92
commit
112dd68f16
|
@ -3,5 +3,5 @@
|
||||||
|
|
||||||
"""Main module for the rsl_rl package."""
|
"""Main module for the rsl_rl package."""
|
||||||
|
|
||||||
__version__ = "2.0.0"
|
__version__ = "2.0.1"
|
||||||
__license__ = "BSD-3"
|
__license__ = "BSD-3"
|
||||||
|
|
|
@ -60,7 +60,11 @@ def unpad_trajectories(trajectories, masks):
|
||||||
|
|
||||||
def store_code_state(logdir, repositories):
|
def store_code_state(logdir, repositories):
|
||||||
for repository_file_path in repositories:
|
for repository_file_path in repositories:
|
||||||
repo = git.Repo(repository_file_path, search_parent_directories=True)
|
try:
|
||||||
|
repo = git.Repo(repository_file_path, search_parent_directories=True)
|
||||||
|
except git.InvalidGitRepositoryError:
|
||||||
|
# skip if not a git repository
|
||||||
|
continue
|
||||||
repo_name = pathlib.Path(repo.working_dir).name
|
repo_name = pathlib.Path(repo.working_dir).name
|
||||||
t = repo.head.commit.tree
|
t = repo.head.commit.tree
|
||||||
content = f"--- git status ---\n{repo.git.status()} \n\n\n--- git diff ---\n{repo.git.diff(t)}"
|
content = f"--- git status ---\n{repo.git.status()} \n\n\n--- git diff ---\n{repo.git.diff(t)}"
|
||||||
|
|
2
setup.py
2
setup.py
|
@ -5,7 +5,7 @@ from setuptools import find_packages, setup
|
||||||
|
|
||||||
setup(
|
setup(
|
||||||
name="rsl_rl",
|
name="rsl_rl",
|
||||||
version="2.0.0",
|
version="2.0.1",
|
||||||
packages=find_packages(),
|
packages=find_packages(),
|
||||||
license="BSD-3",
|
license="BSD-3",
|
||||||
description="Fast and simple RL algorithms implemented in pytorch",
|
description="Fast and simple RL algorithms implemented in pytorch",
|
||||||
|
|
Loading…
Reference in New Issue