I am trying to publish a feature layer to AGOL through python. I have a script and have successfully done this many times with this script in the past few weeks. All of a sudden, I am getting an error that says "Exception: Overwrite unsuccessful. Check that editing capabilities are enabled on your service."
When this is happening, a File Geodatabase is published to my AGOL, which I can manually go click on and hit "Publish" and get the feature layer I was originally trying to get.
I've tested on a few different datasets (some from my local computer, also tried to grab a simple feature layer from AGOL and republish), but I am getting the same error every time. I have updated the arcgis module and all the modules I am using in my script currently (although this error came up before I did any updates).
Just wondering if anyone else has experienced this lately and/or if there are any solutions?
I am able to otherwise successfully pull in feature layers, truncate, update, etc. But just running into this issue when initially publishing?
feature_layer = census_map.spatial.to_featurelayer('Test')
Thanks in advance for any help or advice.
Solved! Go to Solution.
Hi all - I just found out the solution. It was a problem with the version of the arcgis python package. When I updated ArcGIS Pro last, it updated the package to the newest version and it wasn't working anymore. Once I downgraded the arcgis package to 2.2.X (and pandas to 2.1.X), it is working fine now!
Getting the same issue when publishing a service definition file I have uploaded
Sarah / Joseph - I just ran into this today - I have been using this snippet for months, and now all I get is the gdb and the failure - did you find a solution? Thank you!
Hi all - I just found out the solution. It was a problem with the version of the arcgis python package. When I updated ArcGIS Pro last, it updated the package to the newest version and it wasn't working anymore. Once I downgraded the arcgis package to 2.2.X (and pandas to 2.1.X), it is working fine now!