#3096 hub: document packageListRemove method
Merged 2 years ago by tkopecek. Opened 2 years ago by ktdreyer.

file modified
+17 -4
@@ -1018,12 +1018,25 @@ 

  

  

  def pkglist_remove(taginfo, pkginfo, force=False):

-     """Remove package from the list for tag

+     """Remove a package from a tag's package list

  

-     Most of the time you really want to use the block or unblock functions

+     One reason to remove an entry like this is to remove an override so that

+     the package data can be inherited from elsewhere.

+ 

+     Alternatively you can use the block or unblock functions.

+ 

+     This method always returns None, even if the package does not exist in the

+     tag.

  

-     The main reason to remove an entry like this is to remove an override so

-     that the package data can be inherited from elsewhere.

+     :param int|str taginfo: tag id or name to remove the package

+     :param int|str pkginfo: package id or name to remove

+     :param bool force: If False (default), Koji will check this

+                        operation against the package_list hub policy. If hub

+                        policy does not allow the current user to remove

+                        packages from this tag, then this method will raise

+                        an error.

+                        If True, then this method will bypass hub policy

+                        settings. Only admin users can set force to True.

      """

      _direct_pkglist_remove(taginfo, pkginfo, force, policy=True)

  

Update the packageListRemove RPC docstring to describe all parameters and the return value.

Remove the statement about prefering the block and unblock functions. In many cases it's simpler and faster to put fewer packages into a tag than to block many extraneous packages in a tag.

Commit f5552da fixes this pull-request

Pull-Request has been merged by tkopecek

2 years ago
Metadata