Hi all, I'm trying to use the v2.0.0 API for branch versioning and I'm hitting an unexpected issue. I can create and open a version without any issues, but my edit() call against the version is failing. I expect I'm passing in an incorrect object somewhere but haven't seen any samples using the edit() call.
Here's my current code:
versionName = f"test_ver"
qualVersionName = f"{GIS_USERNAME}.{versionName}"
createSuccess = versionManager.create(versionName)
with versionManager.get(qualVersionName, mode="edit") as version:
featureLayer = version.layers[0]
update = {"attributes": {"OBJECTID": 1, "TEST_ATTR": 1}}
editResult = version.edit(featureLayer, updates=[update])When it hits the edit() call, I get this error from _connection.py, caught at line 1032:
'Multipart Encoder' object has no attribute 'decode'
I've tried not using the context manager with version, as well as explicitly making start_editing() calls and setting the mode property, get the same result regardless. I've also tried passing in a feature layer object that I opened in the normal fashion rather than the one from the version, also the same result.
I've created the Python environment by cloning my ArcGIS Pro environment (with v1.9.1) and then using the command line to upgrade the Python API version (conda install -c esri arcgis=2.0.0). There were no errors, I haven't seen anything to indicate there are any issues with the environment, and I've been able to make other API calls like queries, etc., without issue.
Let me know if you've run into anything like this, or if anything in my code looks unusual. Thanks!