Note: This is a beta release of Red Hat Bugzilla 5.0. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Also email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback here.
Bug 1008666 - API call system.scheduleSyncPackagesWithSystem seems to be broken.
Summary: API call system.scheduleSyncPackagesWithSystem seems to be broken.
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Red Hat Satellite 5
Classification: Red Hat
Component: API
Version: 560
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
Assignee: Tomas Lestach
QA Contact: Red Hat Satellite QA List
URL:
Whiteboard:
Depends On:
Blocks: sat560-triage
TreeView+ depends on / blocked
 
Reported: 2013-09-16 19:41 UTC by Dimitar Yordanov
Modified: 2013-09-17 12:41 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-09-17 12:41:46 UTC


Attachments (Terms of Use)

Description Dimitar Yordanov 2013-09-16 19:41:57 UTC
Description of problem:
API call system.scheduleSyncPackagesWithSystem seems to be broken.

Version-Release number of selected component (if applicable):
spacewalk-java-2.0.2-31

How reproducible:
100%

Steps to Reproduce:
1.Let's have systems S with system id Sid and system T with system id Tid.
2. System S has installed package microcode_ctl:
{'installtime': <DateTime '20130912T16:54:19' at 2ad0830>, 'epoch': '1', 'version': '1.17', 'release': '15.el6_4', 'arch': 'AMD64', 'id': 257, 'name': 'microcode_ctl'}

System T does not have the package "microcode_ctl" installed.

date=client.system.searchByName(key,'\w')[0]['last_checkin']

client.system.scheduleSyncPackagesWithSystem(key,Tid,Sid,[257],date)
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/lib64/python2.7/xmlrpclib.py", line 1224, in __call__
    return self.__send(self.__name, args)
  File "/usr/lib64/python2.7/xmlrpclib.py", line 1578, in __request
    verbose=self.__verbose
  File "/usr/lib64/python2.7/xmlrpclib.py", line 1264, in request
    return self.single_request(host, handler, request_body, verbose)
  File "/usr/lib64/python2.7/xmlrpclib.py", line 1297, in single_request
    return self.parse_response(response)
  File "/usr/lib64/python2.7/xmlrpclib.py", line 1473, in parse_response
    return u.close()
  File "/usr/lib64/python2.7/xmlrpclib.py", line 793, in close
    raise Fault(**self._stack[0])
xmlrpclib.Fault: <Fault 1213: 'redstone.xmlrpc.XmlRpcFault: No packages to sync'>


Actual results:
No action  is scheduled.

Expected results:
Package install action is scheduled.


Additional info:

Comment 1 Tomas Lestach 2013-09-17 09:42:33 UTC
I followed the reproducer and the missing package (zsh in my case) was correctly scheduled to be installed.

Among the Pending Events I see:
Summary:	Package Synchronization scheduled by admin
Details:	This action will be executed after 09/17/13 1:58:19 PM AFT.

Btw. What is the reason for specifying the last checkin time as the schedule date?


Would you, please, enhance the reproducer?


Note You need to log in before you can comment on or make changes to this bug.