Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Error while installing GitPython #58043

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
ronak2303 opened this issue Jul 28, 2020 · 8 comments
Closed

Error while installing GitPython #58043

ronak2303 opened this issue Jul 28, 2020 · 8 comments
Assignees
Labels
cannot-reproduce cannot be replicated with info/context provided
Milestone

Comments

@ronak2303
Copy link

ronak2303 commented Jul 28, 2020

Description of Issue

i am trying to install GitPython for to handle my git repository. i also have tried installing python3 and pip3 but still same error.
error i am getting as below.

      ID: GitPython
Function: pip.installed
    Name: GitPython < 2.0.9
  Result: False
 Comment: An exception occurred in this state: Traceback (most recent call last):
            File "/usr/lib/python2.7/site-packages/salt/state.py", line 1933, in call
              **cdata['kwargs'])
            File "/usr/lib/python2.7/site-packages/salt/loader.py", line 1951, in wrapper
              return f(*args, **kwargs)
            File "/usr/lib/python2.7/site-packages/salt/states/pip_state.py", line 812, in installed
              **kwargs)
            File "/usr/lib/python2.7/site-packages/salt/states/pip_state.py", line 314, in _check_if_installed
              for version in reversed(available_versions):
          TypeError: argument to reversed() must be a sequence
 Started: 14:36:48.336599
Duration: 368473.146 ms
 Changes:

Setup

i have top.sls with below code.
base:
'wh-*':
- gitsetup

i have my gitsetup.sls as below.
git:
pkg.installed

GitPython:
pip.installed:
- name: GitPython < 2.0.9
- proxy: http://<>
- upgrade: True

Steps to Reproduce Issue

above is the code i have and its keep failing.

Versions Report

(Provided by running salt --versions-report. Please also mention any differences in master/minion versions.)

Salt Version:
Salt: 2019.2.4

Dependency Versions:
cffi: 1.14.1
cherrypy: unknown
dateutil: 1.5
docker-py: Not Installed
gitdb: 4.0.5
gitpython: Not Installed
ioflo: Not Installed
Jinja2: 2.7.2
libgit2: Not Installed
libnacl: Not Installed
M2Crypto: 0.21.1
Mako: Not Installed
msgpack-pure: Not Installed
msgpack-python: 0.5.6
mysql-python: Not Installed
pycparser: 2.20
pycrypto: 2.6.1
pycryptodome: Not Installed
pygit2: Not Installed
Python: 2.7.5 (default, Jun 11 2019, 14:33:56)
python-gnupg: Not Installed
PyYAML: 3.10
PyZMQ: 15.3.0
RAET: Not Installed
smmap: 3.0.4
timelib: Not Installed
Tornado: 4.2.1
ZMQ: 4.1.4

System Versions:
dist: redhat 7.7 Maipo
locale: UTF-8
machine: x86_64
release: 3.10.0-1062.4.3.el7.x86_64
system: Linux
version: Red Hat Enterprise Linux Server 7.7 Maipo

all master and minion on same version

Master:
2019.2.4
Up to date:
----------
minion1:
2019.2.4
minion2:
2019.2.4
minon3: -- this is master as well.
2019.2.4

@cmcmarrow cmcmarrow added the cannot-reproduce cannot be replicated with info/context provided label Jul 28, 2020
@cmcmarrow
Copy link
Contributor

Does this work for you?

GitPython:
  pip.installed:
   - name: GitPython < 2.0.9
   - upgrade: True

@cmcmarrow cmcmarrow added this to the Follow up milestone Jul 28, 2020
@cmcmarrow
Copy link
Contributor

@ronak2303 I could not reproduce this. I tried on master and 19.2.3.3 Do you have your proxy setup right?

@ronak2303
Copy link
Author

@ronak2303 I could not reproduce this. I tried on master and 19.2.3.3 Do you have your proxy setup right?

hi cmcmarrow,
our servers are not exposed to internet to without proxy i get same error.
when i tried first time it worked without error, i do not have output of it. but when i tried to run to make sure i have latest i started getting this error.

  ID: GitPython

Function: pip.installed
Name: GitPython < 2.0.9
Result: False
Comment: An exception occurred in this state: Traceback (most recent call l ast):
File "/usr/lib/python2.7/site-packages/salt/state.py", line 1933 , in call
**cdata['kwargs'])
File "/usr/lib/python2.7/site-packages/salt/loader.py", line 195 1, in wrapper
return f(*args, **kwargs)
File "/usr/lib/python2.7/site-packages/salt/states/pip_state.py" , line 812, in installed
**kwargs)
File "/usr/lib/python2.7/site-packages/salt/states/pip_state.py" , line 314, in _check_if_installed
for version in reversed(available_versions):
TypeError: argument to reversed() must be a sequence
Started: 20:32:06.827795
Duration: 368637.515 ms
Changes:

@ronak2303
Copy link
Author

@ronak2303 I could not reproduce this. I tried on master and 19.2.3.3 Do you have your proxy setup right?

hi McMarrow,
i was able to reproduce this by below step on other server.
1st ) i ran the script 2 time to make sure that GitPython installed.
2nd ) i put gitfs entry in master file /etc/salt/master and restart salt master.
once i restart i see "No suitable gitfs provider module is installed" when i do systemctl status salt.master
3rd) then i remove entry for gitfs from /etc/salt/master and restart salt master again,
4th ) i try to run same code again to have GitPython again and error appears.

i am running python 2.7 and linux 7.7

@cmcmarrow
Copy link
Contributor

cmcmarrow commented Aug 5, 2020

@ronak2303 I tried your steps to reproduce. Still no luck :( Next I will install readhat 7.7 and python 2.7.5`.

Salt Version:
           Salt: 2019.2.2.4
 
Dependency Versions:
           cffi: 1.12.3
       cherrypy: unknown
       dateutil: 2.8.0
      docker-py: 4.0.2
          gitdb: 0.6.4
      gitpython: 2.1.15
          ioflo: 1.7.5
         Jinja2: 2.10.1
        libgit2: Not Installed
        libnacl: Not Installed
       M2Crypto: Not Installed
           Mako: Not Installed
   msgpack-pure: Not Installed
 msgpack-python: 0.6.1
   mysql-python: Not Installed
      pycparser: 2.19
       pycrypto: 2.6.1
   pycryptodome: Not Installed
         pygit2: Not Installed
         Python: 2.7.17 (default, Nov  7 2019, 10:07:09)
   python-gnupg: 0.4.4
         PyYAML: 3.13
          PyZMQ: 18.0.2
           RAET: Not Installed
          smmap: 3.0.4
        timelib: 0.2.4
        Tornado: 5.1.1
            ZMQ: 4.3.1
 
System Versions:
           dist: Ubuntu 19.10 eoan
         locale: UTF-8
        machine: x86_64
        release: 5.3.0-64-generic
         system: Linux
        version: Ubuntu 19.10 eoan

@sagetherage
Copy link
Contributor

@ronak2303 let me know if you are willing to setting up a call between you and @cmcmarrow so he can reproduce and get this fixed. I am happy to help coordinate.

@doesitblend
Copy link
Collaborator

@cmcmarrow I believe this issue comes from some unresolved dependencies with the gitdb and gitdb2 libraries not being installed properly. I worked through this and was eventually able to solve by uninstall GitPython, gitdb, and gitdb2. Then I installed the latest version of GitPython.

These steps were taken according to the information I found here.

@cmcmarrow
Copy link
Contributor

@ronak2303 I heard Ken was able to help you with your problem. For now I will close the issue but if you still need help you I believe you can reopen it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cannot-reproduce cannot be replicated with info/context provided
Projects
None yet
Development

No branches or pull requests

4 participants