Python 用于检索位置ID的官方Softlayer脚本不起作用

Python 用于检索位置ID的官方Softlayer脚本不起作用,python,ibm-cloud-infrastructure,Python,Ibm Cloud Infrastructure,我曾经使用以下脚本检索不同的位置ID,以创建VSI订单: 具体而言: def getAllLocations(self): mask = "mask[id,locations[id,name]]" result = self.client['SoftLayer_Location_Group_Pricing'].getAllObjects(mask=mask); pp(result) 不幸的是,它同时引发以下异常: Traceback (most recent call

我曾经使用以下脚本检索不同的位置ID,以创建VSI订单:

具体而言:

def getAllLocations(self):
    mask = "mask[id,locations[id,name]]"
    result = self.client['SoftLayer_Location_Group_Pricing'].getAllObjects(mask=mask);
    pp(result)
不幸的是,它同时引发以下异常:

Traceback (most recent call last):
  File "new.py", line 59, in <module>
    main.getAllLocations()
  File "new.py", line 52, in getAllLocations
    result = self.client['SoftLayer_Location_Group_Pricing'].getAllObjects(mask=mask);
  File "/usr/local/lib/python2.7/site-packages/SoftLayer/API.py", line 392, in call_handler
    return self(name, *args, **kwargs)
  File "/usr/local/lib/python2.7/site-packages/SoftLayer/API.py", line 360, in call
    return self.client.call(self.name, name, *args, **kwargs)
  File "/usr/local/lib/python2.7/site-packages/SoftLayer/API.py", line 263, in call
    return self.transport(request)
  File "/usr/local/lib/python2.7/site-packages/SoftLayer/transports.py", line 195, in __call__
   raise _ex(ex.faultCode, ex.faultString)
SoftLayer.exceptions.SoftLayerAPIError: SoftLayerAPIError(SOAP-ENV:Server): Internal Error
回溯(最近一次呼叫最后一次):
文件“new.py”,第59行,在
main.getAllLocations()
文件“new.py”,第52行,在getAllLocations中
结果=self.client['SoftLayer\u Location\u Group\u Pricing'].getAllObjects(mask=mask);
文件“/usr/local/lib/python2.7/site packages/SoftLayer/API.py”,第392行,在call\u handler中
返回自我(名称,*args,**kwargs)
文件“/usr/local/lib/python2.7/site packages/SoftLayer/API.py”,第360行,调用中
返回self.client.call(self.name,name,*args,**kwargs)
文件“/usr/local/lib/python2.7/site packages/SoftLayer/API.py”,第263行,在调用中
返回自动传输(请求)
文件“/usr/local/lib/python2.7/site packages/SoftLayer/transports.py”,第195行,在调用中__
raise_ex(ex.faultCode,ex.faultString)
SoftLayer.exceptions.SoftLayerAPIError:SoftLayerAPIError(SOAP-ENV:Server):内部错误

函数中是否有需要更改的内容?

不,您的代码没有问题。问题是,这是该方法的问题,该方法不起作用。我将报告该问题,或者如果您需要,您可以打开软件层的票证,自己报告该问题

昨天修复了此服务的getAllObjects方法的问题。请重试该请求