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

Sporadic failures inPopen() under Windows with processes left insubprocess._active list #508

Closed
@ankostis

Description

@ankostis

Under Windows, when running test-cases creating different temporary repositories consecutively, I get sporadic failures when executing thegit process:

 File "D:\Apps\WinPython-64bit-3.5.2.1\python-3.5.2.amd64\lib\site-packages\git\repo\base.py", line 872, in init    git.init(**kwargs)  File "D:\Apps\WinPython-64bit-3.5.2.1\python-3.5.2.amd64\lib\site-packages\git\cmd.py", line 466, in <lambda>    return lambda *args, **kwargs: self._call_process(name, *args, **kwargs)  File "D:\Apps\WinPython-64bit-3.5.2.1\python-3.5.2.amd64\lib\site-packages\git\cmd.py", line 910, in _call_process    return self.execute(make_call(), **_kwargs)  File "D:\Apps\WinPython-64bit-3.5.2.1\python-3.5.2.amd64\lib\site-packages\git\cmd.py", line 630, in execute    raise GitCommandNotFound(str(err))git.exc.GitCommandNotFound: [WinError 6] The handle is invalid
  • Digging a bit further, I noticed that before executing the failingPopen(), thesubprocess._active list contains 2 leftovers processes, while this list is always empty when not failing.
  • I tried to add some delays withtime.sleep() but it did not help.
  • It did help when I simplified my test-cases, i.e. dropping some commit actions.
  • Tested under:
    • Windows 10,
    • WinPython 3.5.2:
    • gitpython: both latest in PyPiv2.0.8 and latest master from github(df65f51) (2.0.9-dev0).
    • smmap:0.9.0
    • gitdb:0.6.4

An minor note: the try-catchPopen() code assumes that any exception caught is becausegit was not found, while above it obviously not the case.

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