I am updating some existing tools to leave out username and password from the GIS() method due to the the issue with IWA and OpenSSL 3.0 in ArcGIS Pro 3.0 (detailed here: https://support.esri.com/en/Technical-Article/000028494). When I do that, however, I get a 401 error and can't authenticate.
Here's an example where I'm just trying to update an item's summary and description (the service is on a federated server):
portal_url = r"https://portalurl.com/portal"
gis = GIS(portal_url)
upd_str = "Test string"
portal_item = gis.content.get(target_item)
print("Target item title: {}".format(portal_item.title))
portal_item.update(item_properties={'snippet': upd_str, 'description': upd_str})
print("Item summary and description updated")
Using that code I get the item title printed out, but then get "HTTP Error 401. The requested resource requires user authentication." It seems like this may be an issue with authenticating with the server, which is why I am able to get the item title but not update its properties.
Environment:
- ArcGIS Enterprise 10.9.1 configured with Windows Authentication (IWA)
- ArcGIS Pro 3.0.2
- ArcGIS API for Python version 2.0.1
These tools worked perfectly when username and password were specified in the GIS() method. Anyone else come across this issue too or have any ideas?