arcgis-python-api icon indicating copy to clipboard operation
arcgis-python-api copied to clipboard

clone_item() hosted feature service referencing to source portal

Open stwrr opened this issue 1 year ago • 1 comments

Describe the bug When I use clone_item() on a hosted feature service, even after it has been cloned into the target portal, it still references the source portal. So when I try to use the cloned content in the target portal, a pop-up appears asking me to connect to the source portal in order to use the content in my target portal.

I even tried setting the copy_data parameter to true but it doesn't change anything.

To Reproduce To clone my content I have used two differents methods (but both doesn't work as intended) :

1st method :

  • using this script : https://github.com/Esri/arcgis-python-api/blob/conference_talks/talks/DevSummit2023/Cloning_Migrating_and_Promoting_Content_with_the_API_for_Python/Cloning%20via%20Backup.ipynb

2nd method :

dashboard = source.content.get(itemId)
dash_clone = target.content.clone_items(items = [dashboard], search_existing_items = True)

Expected behavior I expect to be able to use the cloned content in my target portal, without needing to connect to the source portal.

Platform (please complete the following information):

  • OS: Windows 11
  • Browser chrome
  • Python API Version 2.1.0.5

stwrr avatar Jul 17 '24 13:07 stwrr

@stwrr have you tried using the latest version of the Python API? This is an older version and there have been various improvements since then

nparavicini7 avatar Aug 05 '24 17:08 nparavicini7

Closing due to inactivity, please reopen if necessary

nanaeaubry avatar Jan 07 '25 17:01 nanaeaubry