Hi All,
i have an issue when i try to run the sample code from the orionsdk-python in particular from this page:https://github.com/solarwinds/orionsdk-python/blob/master/samples/ncm_execute_script.py
i get this error unable to connect to polling engine, we have 3 pollers, i tried all 3 pollers its the same result


here is the code i am using with slight editing
import re
import requests
from orionsdk import SwisClient
from time import sleep
import os
requests.packages.urllib3.disable_warnings()
npm_server = os.environ.get('SW_SERVER')
username = os.environ.get('SW_USERNAME')
password = os.environ.get('SW_PASSWD')
def main():
npm_server = os.environ.get('SW_SERVER')
username = os.environ.get('SW_USERNAME')
password = os.environ.get('SW_PASSWD')
swis = SwisClient(npm_server, username, password)
ip = 'x.x.x.x'
data = swis.query('SELECT NodeID FROM Cirrus.Nodes WHERE AgentIP = @ip';, ip=ip)['results']
nodeId = data[0]['NodeID']
script = 'show clock'
print (nodeId)
swis.invoke('Cirrus.ConfigArchive', 'Execute', [nodeId], script, username)
transferId = '{{{0}}}:{1}:ExecuteScript'.format(nodeId, username)
print(transferId)
status = 'Queued'
while status != 'Complete' and status != 'Error':
sleep(1)
data = swis.query('SELECT T.Status, T.Error FROM Cirrus.TransferQueue T WHERE T.TransferID=@transfer';, transfer=transferId)['results']
status = data[0]['Status']
print(status)
data = swis.query('SELECT T.Log FROM Cirrus.TransferQueue T WHERE T.TransferID=@transfer';, transfer=transferId)['results']
output = data[0]['Log']
print(output)
main()