If you install python-jenkins in parallel to jenkins-webapi (via pip) you receive an error by calling one of the jenkins-makejob-* scripts.
Traceback (most recent call last):
File "/usr/local/bin/jenkins-makejobs-git", line 9, in
load_entry_point('jenkins-autojobs==0.17.4', 'console_scripts', 'jenkins-makejobs-git')()
File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 337, in load_entry_point
return get_distribution(dist).load_entry_point(group, name)
File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 2279, in load_entry_point
return ep.load()
File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 1989, in load
entry = import(self.module_name, globals(),globals(), ['name'])
File "/usr/local/lib/python2.7/dist-packages/jenkins_autojobs/git.py", line 16, in
from . import job, main, utils
File "/usr/local/lib/python2.7/dist-packages/jenkins_autojobs/main.py", line 19, in
from jenkins import Jenkins, JenkinsError
ImportError: No module named jenkins
Quick Solution:
'pip uninstall python-jenkins && pip uninstall jenkins-webapi'
check if /usr/local/lib/python2.7/dist-packages/ has no entries for jenkins-webapi or python-jenkins left.
'pip install jenkins-webapi'
then it worked here.
If you install python-jenkins in parallel to jenkins-webapi (via pip) you receive an error by calling one of the jenkins-makejob-* scripts.
Traceback (most recent call last): File "/usr/local/bin/jenkins-makejobs-git", line 9, in
load_entry_point('jenkins-autojobs==0.17.4', 'console_scripts', 'jenkins-makejobs-git')()
File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 337, in load_entry_point
return get_distribution(dist).load_entry_point(group, name)
File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 2279, in load_entry_point
return ep.load()
File "/usr/lib/python2.7/dist-packages/pkg_resources.py", line 1989, in load
entry = import(self.module_name, globals(),globals(), ['name'])
File "/usr/local/lib/python2.7/dist-packages/jenkins_autojobs/git.py", line 16, in
from . import job, main, utils
File "/usr/local/lib/python2.7/dist-packages/jenkins_autojobs/main.py", line 19, in
from jenkins import Jenkins, JenkinsError
ImportError: No module named jenkins
Quick Solution: 'pip uninstall python-jenkins && pip uninstall jenkins-webapi' check if /usr/local/lib/python2.7/dist-packages/ has no entries for jenkins-webapi or python-jenkins left. 'pip install jenkins-webapi' then it worked here.