You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
node.get_response_time(), node.get_temp_path() and some other functions can't get right value.why unittests are passed? Did unittests run?
I can fix this if this is sure a bug.
EXPECTED RESULTS
node.get_response_time() will get NODE_DATA['monitorData']['hudson.node_monitors.ResponseTimeMonitor']'[average']
ACTUAL RESULTS
KeyError: 'average'
USEFUL INFORMATION
These functions all invoke get_monitor(<monitor_name>), with default parameter poll_monitor=True. We firstly get monitor_data, and then get the subitem value.
While the source code tree did not has subitem info, so Jenkins api will not return subitems data.
if poll_monitor:
# polling as monitors like response time can be updated
monitor_data = self.poll(tree=monitor_data_key)[monitor_data_key]
for example, following code,
value of monitor_data is 'hudson.node_monitors.ResponseTimeMonitor$Data', no subitems data.
def get_response_time(self):
"""
Returns the node's average response time.
"""
monitor_data = self.get_monitor('ResponseTimeMonitor')
return monitor_data['average']
The text was updated successfully, but these errors were encountered:
ISSUE TYPE
Jenkinsapi 0.3.11
Jenkins 2.229
SUMMARY
node.get_response_time()
,node.get_temp_path()
and some other functions can't get right value.why unittests are passed? Did unittests run?I can fix this if this is sure a bug.
EXPECTED RESULTS
node.get_response_time()
will getNODE_DATA['monitorData']['hudson.node_monitors.ResponseTimeMonitor']'[average']
ACTUAL RESULTS
KeyError: 'average'
USEFUL INFORMATION
These functions all invoke
get_monitor(<monitor_name>)
, with default parameter poll_monitor=True. We firstly get monitor_data, and then get the subitem value.While the source code tree did not has subitem info, so Jenkins api will not return subitems data.
for example, following code,
value of monitor_data is
'hudson.node_monitors.ResponseTimeMonitor$Data'
, no subitems data.The text was updated successfully, but these errors were encountered: