Select to view content in your preferred language

publishing tile package does not 'publish tiles' for tile layer

05-11-2017 07:24 PM
New Contributor

I started using ArcGIS API for Python since yesterday. Today I found there is a problem publishing tiles automatically. The following is my script,

from arcgis.gis import GIS
gis = GIS("", "username", "password")
cm = gis.content
data = r"something.tpk"
item = cm.add({}, data=data)
if item != None:
     tiledServiceItem = item.publish()
     if tiledServiceItem != None:

It successfully created a tile package and a tile layer in ArcGIS Online but 'publish tiles' didn't work.

I've tried manually uploading the tile package and publishing it and it worked perfectly. I tracked the network requests and found the manual process had a 'edit' map service to update minScale, maxScale and sourceItemId properties. Not sure if it is a bug or my coding error. Any suggestion?

0 Kudos
0 Replies