Esri/arcgis-python-api

AttributeError: 'Server' object has no attribute 'services'

Closed this issue · 1 comments

Describe the bug
When trying to list the services of a single-machine ArcGIS Enterprise deployment, the services attribute of the Server object does not exist.

To Reproduce
Steps to reproduce the behavior:

gis = GIS(...)
server = gis.admin.servers.get(role="HOSTING_SERVER")[0]
print(server.services.list())

error:

---------------------------------------------------------------------------
AttributeError                            Traceback (most recent call last)
In  [19]:
Line 3:     print(server.services.list())

File C:\Program Files\ArcGIS\Pro\bin\Python\envs\arcgispro-py3\lib\site-packages\arcgis\gis\server\_common\_base.py, in __getattr__:
Line 104:   raise AttributeError(

AttributeError: 'Server' object has no attribute 'services'
---------------------------------------------------------------------------

Expected behavior
I am looking to get a ServiceManager object.

Platform (please complete the following information):

  • OS: Windows X
  • ArcGIS Pro 3.2.2

Additional context
I get the same issue logging into an ArcGIS Enterprise 10.6.1 deployment with an AD username and password as well as using IWA on a 10.9.1 ArcGIS Enterprise deployment. I had no issues using the arcgis library installed with ArcGIS Pro 2.9.2 to the same servers.

@nheick I just tested this, and cannot reproduce with the latest releases Given this, I would do the following:

  • update to the latest Python API version.
  • Ensure the user has permissions to do what they are doing.
  • Verify that your openssl3 supports the security method you are using

2.3.0, which is being released this month also does not show the error.

In regards to 10.6.1. is considered retired and newer version of the Python API are not guaranteed to be supported. Please see: https://support.esri.com/en-us/products/arcgis-enterprise/life-cycle