Description of the problem, including code/CLI snippet
Currently, getting the trace from a job obtained through a pipeline requires an extra request. This works, but I don't see any reason for ProjectPipelineJob not to have the trace() method as well, since all it requires is the job's ID.
The same goes for all the other methods on ProjectJob.
Code for current API
import gitlab
g = gitlab.Gitlab("https://gitlab.example.com/")
project = g.projects.get("example/example")
pipeline = project.pipelines.latest()
jobs = pipeline.jobs.list(iterator=True)
job = project.jobs.get(next(jobs).id)
trace = job.trace()
Code for desired API
import gitlab
g = gitlab.Gitlab("https://gitlab.example.com/")
project = g.projects.get("example/example")
pipeline = project.pipelines.latest()
jobs = pipeline.jobs.list(iterator=True)
trace = next(jobs).trace()
Specifications
- python-gitlab version: 7.1.0
- Gitlab server version (or gitlab.com): gitlab.com
Description of the problem, including code/CLI snippet
Currently, getting the trace from a job obtained through a pipeline requires an extra request. This works, but I don't see any reason for ProjectPipelineJob not to have the
trace()method as well, since all it requires is the job's ID.The same goes for all the other methods on
ProjectJob.Code for current API
Code for desired API
Specifications