Hi,
I am attempting to use the copy_feature_layer_collection in a Notebook on ArcGIS Online (Python 3). Previously this worked fine (possibly when AGOL was using an older version of the python?). Now it fails.
newHab = habItem.copy_feature_layer_collection(service_name = habName, layers = layer_ids_h, tables = table_ids_h, folder = folderName)
The error given looks like this:
---------------------------------------------------------------------------
AttributeError Traceback (most recent call last)
/tmp/ipykernel_19/1373826970.py in <cell line: 0>()
---> 19 newHab = habItem.copy_feature_layer_collection(service_name = habName, layers = layer_ids_h, tables = table_ids_h, folder = folderName)
/opt/conda/lib/python3.11/site-packages/arcgis/gis/__init__.py in copy_feature_layer_collection(self, service_name, layers, tables, folder, description, snippet, owner)
> 13848 fs = FeatureLayerCollection(url=copied_item.url, gis=self._gis)
13849 fs_manager = fs.manager
13850 add_defs = {"layers": [], "tables": []}
AttributeError: 'NoneType' object has no attribute 'url' I have tested the item and all the input parameters - all seem valid.
ANy ideas why this might have happended? We used this to replace the clone_items() that also changed behavior after python updates.
thanks!
Joe