Script that copies data from ArcGIS Online to Portal

545
6
03-08-2021 07:13 AM
JacobRougeaux
New Contributor III

I have a Python script that is designed to take feature layers from ArcGIS Online and move them to Portal.  All the inputs work fine until the last part where it attempts the copy.  Here's a screen snip of the script and the output.  The script is correctly identifying the feature to copy but then prints there was an error.  I'm having trouble determining what is causing the feature not to copy.

Any help or advice is much appreciated!

feature layer copy.PNG

 

6 Replies
MichaelVolz
Esteemed Contributor

What version of ArcGIS Enterprise do you have your Portal a part of?

0 Kudos
JacobRougeaux
New Contributor III
Hi Michael,
I'm using Enterprise 10.8.
Jake
0 Kudos
MichaelVolz
Esteemed Contributor

I've been told by ESRI tech support that AGOL is 2 versions ahead of Portal.  Would this make a workflow of copying data from AGOL to Portal not possible, although copying data from Portal to AGOL would work?

0 Kudos
JacobRougeaux
New Contributor III

I reversed the workflow and told it to copy from Portal to AGOL.  That worked.  So it appears the versions being different and trying to copy from old (Portal) to new (AGOL) could be the source of the problem?

0 Kudos
DanPatterson
MVP Esteemed Contributor

why not have the functions that you create called within your try-except block, or check within your print statement that "li" actually has any values.  only itemId is checked


... sort of retired...
0 Kudos
JacobRougeaux
New Contributor III

Dan, thanks for the suggestion.  I had it print "li" and confirmed that it contains the appropriate value.

0 Kudos