pFad - Phone/Frame/Anonymizer/Declutterfier! Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

URL: http://github.com/python-gitlab/python-gitlab/blob/refs/heads/main/docs/gl_objects/milestones.rst

igin="anonymous" media="all" rel="stylesheet" href="https://github.githubassets.com/assets/github-f825c0edd7ad57f8.css" /> python-gitlab/docs/gl_objects/milestones.rst at refs/heads/main · python-gitlab/python-gitlab · GitHub
Skip to content

Latest commit

 

History

History
109 lines (69 loc) · 2.65 KB

File metadata and controls

109 lines (69 loc) · 2.65 KB

Milestones

Project milestones

Reference

Examples

List the milestones for a project or a group:

p_milestones = project.milestones.list(get_all=True)
g_milestones = group.milestones.list(get_all=True)

You can filter the list using the following parameters:

  • iids: unique IDs of milestones for the project
  • state: either active or closed
  • search: to search using a string
p_milestones = project.milestones.list(state='closed', get_all=True)
g_milestones = group.milestones.list(state='active', get_all=True)

Get a single milestone:

p_milestone = project.milestones.get(milestone_id)
g_milestone = group.milestones.get(milestone_id)

Create a milestone:

milestone = project.milestones.create({'title': '1.0'})

Edit a milestone:

milestone.description = 'v 1.0 release'
milestone.save()

Change the state of a milestone (activate / close):

# close a milestone
milestone.state_event = 'close'
milestone.save()

# activate a milestone
milestone.state_event = 'activate'
milestone.save()

Promote a project milestone:

milestone.promote()

List the issues related to a milestone:

issues = milestone.issues()

List the merge requests related to a milestone:

merge_requests = milestone.merge_requests()

Milestone events

Resource milestone events keep track of what happens to GitLab issues and merge requests.

Reference

Examples

Get milestones for a resource (issue, merge request):

milestones = resource.resourcemilestoneevents.list(get_all=True)

Get a specific milestone for a resource:

milestone = resource.resourcemilestoneevents.get(milestone_id)
pFad - Phonifier reborn

Pfad - The Proxy pFad © 2024 Your Company Name. All rights reserved.





Check this box to remove all script contents from the fetched content.



Check this box to remove all images from the fetched content.


Check this box to remove all CSS styles from the fetched content.


Check this box to keep images inefficiently compressed and original size.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy