laptop and a wrench

Error

Updating the item data with the BytesIO object returns the error message "Error 409: Item with file already exists".

ArcGIS API for Python
Número de ID del error BUG-000161855
EnviadoOctober 4, 2023
Última modificaciónJune 5, 2024
Relacionado conArcGIS API for Python
Versión encontradaN/A
Sistema operativoWindows Server
Versión de sistema operativoN/A
EstadoNon-Reproducible

Información adicional

This issue is not reproducible.

Solución alternativa

Currently, the fileName is resolved as follows in src/arcgis/gis/__init__.py:14909

           if data is not None and isinstance(data, (io.StringIO, io.BytesIO)):

               if item_properties is None:

                   item_properties =

               if not "type" in item_properties:

                   item_properties["type"] = self.type

               if not "fileName" in item_properties:

                   fileName = self.name

                   item_properties["fileName"] = fileName

Consider using a random filename, or appending a timestamp to the end of the itemId as a filename.

           if data is not None and isinstance(data, (io.StringIO, io.BytesIO)):

               if item_properties is None:

                   item_properties =

               if not "type" in item_properties:

                   item_properties["type"] = self.type

               if not "fileName" in item_properties:

                   fileName = f"self.name_str(round((datetime.now()).timestamp()))"

                   item_properties["fileName"] = fileName

Pasos para reproducir

ID del error: BUG-000161855

Software:

  • ArcGIS API for Python

Recibir notificaciones cuando cambie el estado de un error

Descargar la aplicación de soporte de Esri

Descubrir más sobre este tema

Obtener ayuda de expertos en ArcGIS

Contactar con el soporte técnico

Descargar la aplicación de soporte de Esri

Ir a opciones de descarga