Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

git.Repo InvalidGitRepositoryError #255

Closed
@malford

Description

@malford

Previously when using GitPython 0.3.2c1 we had something that would point to a sub directory in a repo:

repo = git.Repo(os.path.dirname('/path/to/repo/sub_dir'))

Now after upgrading to GitPython 0.3.6 I am getting this error:

Traceback (most recent call last):  File "/path/to/repo/sub_dir/perc_version", line 685, in <module>    main()  File "/path/to/repo/sub_dir/perc_version", line 567, in main    perc_lib.fail_if_outdated()  File "/path/to/repo/sub_dir/lib.py", line 451, in fail_if_outdated    repo = git.Repo(os.path.dirname(command_path))  File "/usr/local/lib/python2.7/site-packages/git/repo/base.py", line 162, in __init__    raise InvalidGitRepositoryError(epath)git.exc.InvalidGitRepositoryError: /path/to/repo/sub_dir

I can fix by adding anotheros.path.dirname but should this be the behavior forgit.Repo to need the top level of a repo or a bug?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions


      [8]ページ先頭

      ©2009-2025 Movatter.jp