pycontribs / jenkinsapi

A Python API for accessing resources and configuring Hudson & Jenkins continuous-integration servers
http://pypi.python.org/pypi/jenkinsapi
MIT License
859 stars 485 forks source link

get_downstream_jobs() does not differentiate between jobs with the same name #678

Closed jwlarocque closed 5 years ago

jwlarocque commented 5 years ago
ISSUE TYPE
Jenkinsapi 0.3.7
Jenkins 2.141
SUMMARY

In jenkinsapi/job.py, line 585:
<job>.get_downstream_jobs() sometimes returns the wrong job when there is another job with the same name but not downstream.

For example, with this structure:

server = Jenkins(URL, username=USER, password=TOKEN)
for job in server["Create Desktop Test Jobs"].get_downstream_jobs():
    print job.url
EXPECTED RESULTS
<server url>/job/Desktop/job/Login
ACTUAL RESULTS
<server url>/job/Mobile/job/Login
lechat commented 5 years ago

I assume that structure above is made using Folders plugin and there is no full support for that plugin in this library. I am open for contributions.

stale[bot] commented 5 years ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

stale[bot] commented 5 years ago

Closed due to inactivity