laptop and a wrench

Bug

The PortalFolder settings are not honored when publishing a map image layer from ArcGIS Pro to Portal for ArcGIS using the ArcPy MapImageSharingDraft class.

Last Published: July 4, 2022 ArcGIS Pro
Bug ID Number BUG-000122626
SubmittedMay 28, 2019
Last ModifiedFebruary 18, 2025
Applies toArcGIS Pro
Version found2.3.3
Operating SystemN/A
Operating System VersionN/A
StatusAs Designed

Additional Information

MapImageSharingDraft honors only a folder that already exists in the portal.

Workaround

Include the Python API .move() function to the script function to move the published content to an existing folder in Portal for ArcGIS 10.7:

From arcgis.gis import GIS

gis = GIS("https://supt0008374.esri.com/portal", "xxxxxx", "xxxxx")

portal_item = gis.content.search(query ='title:"TomThomson_1"')

print (portal_item)

first_item = portal_item[0]

first_item1 = portal_item[1]

itemlist = [first_item, first_item1]

for item in itemlist:

item_id = item.id;

getitem = gis.content.get(item_id);

getitem.move(folder='Layers_Test')

Refer to this documentation: https://esri.github.io/arcgis-python-api/apidoc/html/arcgis.gis.toc.html?highlight=item%20upload#arcgis.gis.Item.move.

 

Steps to Reproduce

Bug ID: BUG-000122626

Software:

  • ArcGIS Pro

Get notified when the status of a bug changes

Download the Esri Support App

Discover more on this topic

Get help from ArcGIS experts

Contact technical support

Download the Esri Support App

Go to download options