org.zkoss.poi.openxml4j.exceptions.PartAlreadyExistsException: A part with the name '/xl/media/image2.png' already exists : Packages shall not contain equivalent part names and package implementers shall neither create nor recognize packages with equivalent part names. [M1.12]

ZK-Tracker | hawk | 3 years ago
  1. 0

    h3. Problem Description: Inserting a picture after deleting first picture causes an exception h3. Reproducing Steps: # start a Spreadsheet # insert first & second picture # delete first picture # insert third picture *Expected:* The third picture is inserted without errors. *Actual:* An exception is thrown. {quote} >>org.zkoss.poi.openxml4j.exceptions.PartAlreadyExistsException: A part with the name '/xl/media/image2.png' already exists : Packages shall not contain equivalent part names and package implementers shall neither create nor recognize packages with equivalent part names. [M1.12] >> at org.zkoss.poi.openxml4j.opc.OPCPackage.createPart(OPCPackage.java:735) >> at org.zkoss.poi.openxml4j.opc.OPCPackage.createPart(OPCPackage.java:699) >> at org.zkoss.poi.POIXMLDocumentPart.createRelationship(POIXMLDocumentPart.java:350) >> at org.zkoss.poi.xssf.usermodel.XSSFWorkbook.addPicture(XSSFWorkbook.java:447) >> at org.zkoss.zssex.model.impl.DrawingManagerImpl.addPicture(DrawingManagerImpl.java:386) >> at org.zkoss.zss.model.sys.impl.XRangeImpl.addPicture(XRangeImpl.java:2332) >> at org.zkoss.zss.api.impl.RangeImpl.addPicture(RangeImpl.java:735) >> at org.zkoss.zss.api.SheetOperationUtil.addPicture(SheetOperationUtil.java:103) >> at org.zkoss.zss.api.SheetOperationUtil.addPicture(SheetOperationUtil.java:89) >> at org.zkoss.zss.api.SheetOperationUtil.addPicture(SheetOperationUtil.java:75) >> at org.zkoss.zss.essential.PictureComposer.add(PictureComposer.java:47) {quote}

    ZK-Tracker | 3 years ago | hawk
    org.zkoss.poi.openxml4j.exceptions.PartAlreadyExistsException: A part with the name '/xl/media/image2.png' already exists : Packages shall not contain equivalent part names and package implementers shall neither create nor recognize packages with equivalent part names. [M1.12]
  2. 0

    h3. Problem Description: Inserting a picture after deleting first picture causes an exception h3. Reproducing Steps: # start a Spreadsheet # insert first & second picture # delete first picture # insert third picture *Expected:* The third picture is inserted without errors. *Actual:* An exception is thrown. {quote} >>org.zkoss.poi.openxml4j.exceptions.PartAlreadyExistsException: A part with the name '/xl/media/image2.png' already exists : Packages shall not contain equivalent part names and package implementers shall neither create nor recognize packages with equivalent part names. [M1.12] >> at org.zkoss.poi.openxml4j.opc.OPCPackage.createPart(OPCPackage.java:735) >> at org.zkoss.poi.openxml4j.opc.OPCPackage.createPart(OPCPackage.java:699) >> at org.zkoss.poi.POIXMLDocumentPart.createRelationship(POIXMLDocumentPart.java:350) >> at org.zkoss.poi.xssf.usermodel.XSSFWorkbook.addPicture(XSSFWorkbook.java:447) >> at org.zkoss.zssex.model.impl.DrawingManagerImpl.addPicture(DrawingManagerImpl.java:386) >> at org.zkoss.zss.model.sys.impl.XRangeImpl.addPicture(XRangeImpl.java:2332) >> at org.zkoss.zss.api.impl.RangeImpl.addPicture(RangeImpl.java:735) >> at org.zkoss.zss.api.SheetOperationUtil.addPicture(SheetOperationUtil.java:103) >> at org.zkoss.zss.api.SheetOperationUtil.addPicture(SheetOperationUtil.java:89) >> at org.zkoss.zss.api.SheetOperationUtil.addPicture(SheetOperationUtil.java:75) >> at org.zkoss.zss.essential.PictureComposer.add(PictureComposer.java:47) {quote}

    ZK-Tracker | 3 years ago | hawk
    org.zkoss.poi.openxml4j.exceptions.PartAlreadyExistsException: A part with the name '/xl/media/image2.png' already exists : Packages shall not contain equivalent part names and package implementers shall neither create nor recognize packages with equivalent part names. [M1.12]
  3. 0

    h3. Problem Description: Insert a chart after deleting first chart causes an exception h3. Reproducing Steps: # run {{zss.test}} project, {{issue/326-insertCharts.zul}} to reproduce or # display attached Excel file # select data table # insert first & second chart # delete first chart # insert third chart *Expected:* The third chart is inserted without errors. *Actual:* An exception is thrown. {code} >>org.zkoss.poi.openxml4j.exceptions.PartAlreadyExistsException: A part with the name '/xl/charts/chart2.xml' already exists : Packages shall not contain equivalent part names and package implementers shall neither create nor recognize packages with equivalent part names. [M1.12] >> at org.zkoss.poi.openxml4j.opc.OPCPackage.createPart(OPCPackage.java:735) >> at org.zkoss.poi.openxml4j.opc.OPCPackage.createPart(OPCPackage.java:699) >> at org.zkoss.poi.POIXMLDocumentPart.createRelationship(POIXMLDocumentPart.java:350) >> at org.zkoss.poi.POIXMLDocumentPart.createRelationship(POIXMLDocumentPart.java:334) >> at org.zkoss.poi.xssf.usermodel.XSSFDrawing.createChart(XSSFDrawing.java:203) >> at org.zkoss.poi.xssf.usermodel.XSSFDrawing.createChart(XSSFDrawing.java:214) >> at org.zkoss.poi.xssf.usermodel.XSSFDrawing.createChart(XSSFDrawing.java:1) >> at org.zkoss.zssex.model.impl.DrawingManagerImpl.addChartX(DrawingManagerImpl.java:304) >> at org.zkoss.zss.model.sys.impl.XRangeImpl.addChart(XRangeImpl.java:2249) >> at org.zkoss.zss.api.impl.RangeImpl.addChart(RangeImpl.java:729) >> at org.zkoss.zss.api.SheetOperationUtil.addChart(SheetOperationUtil.java:135) >> at org.zkoss.zssex.ui.DefaultExUserActionHandler.doChart(DefaultExUserActionHandler.java:278) >> at org.zkoss.zssex.ui.DefaultExUserActionHandler.doColumnChart(DefaultExUserActionHandler.java:285) >> at org.zkoss.zssex.ui.DefaultExUserActionHandler.dispatchAction(DefaultExUserActionHandler.java:188) >> at org.zkoss.zss.ui.DefaultUserActionHandler.onEvent(DefaultUserActionHandler.java:1412) >> at org.zkoss.zssex.ui.DefaultExUserActionHandler.onEvent(DefaultExUserActionHandler.java:56) >> at org.zkoss.zss.ui.Spreadsheet$3.onEvent(Spreadsheet.java:343) {code}

    ZK-Tracker | 4 years ago | hawk
    org.zkoss.poi.openxml4j.exceptions.PartAlreadyExistsException: A part with the name '/xl/charts/chart2.xml' already exists : Packages shall not contain equivalent part names and package implementers shall neither create nor recognize packages with equivalent part names. [M1.12]
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    h3. Problem Description: Insert a chart after deleting first chart causes an exception h3. Reproducing Steps: # run {{zss.test}} project, {{issue/326-insertCharts.zul}} to reproduce or # display attached Excel file # select data table # insert first & second chart # delete first chart # insert third chart *Expected:* The third chart is inserted without errors. *Actual:* An exception is thrown. {code} >>org.zkoss.poi.openxml4j.exceptions.PartAlreadyExistsException: A part with the name '/xl/charts/chart2.xml' already exists : Packages shall not contain equivalent part names and package implementers shall neither create nor recognize packages with equivalent part names. [M1.12] >> at org.zkoss.poi.openxml4j.opc.OPCPackage.createPart(OPCPackage.java:735) >> at org.zkoss.poi.openxml4j.opc.OPCPackage.createPart(OPCPackage.java:699) >> at org.zkoss.poi.POIXMLDocumentPart.createRelationship(POIXMLDocumentPart.java:350) >> at org.zkoss.poi.POIXMLDocumentPart.createRelationship(POIXMLDocumentPart.java:334) >> at org.zkoss.poi.xssf.usermodel.XSSFDrawing.createChart(XSSFDrawing.java:203) >> at org.zkoss.poi.xssf.usermodel.XSSFDrawing.createChart(XSSFDrawing.java:214) >> at org.zkoss.poi.xssf.usermodel.XSSFDrawing.createChart(XSSFDrawing.java:1) >> at org.zkoss.zssex.model.impl.DrawingManagerImpl.addChartX(DrawingManagerImpl.java:304) >> at org.zkoss.zss.model.sys.impl.XRangeImpl.addChart(XRangeImpl.java:2249) >> at org.zkoss.zss.api.impl.RangeImpl.addChart(RangeImpl.java:729) >> at org.zkoss.zss.api.SheetOperationUtil.addChart(SheetOperationUtil.java:135) >> at org.zkoss.zssex.ui.DefaultExUserActionHandler.doChart(DefaultExUserActionHandler.java:278) >> at org.zkoss.zssex.ui.DefaultExUserActionHandler.doColumnChart(DefaultExUserActionHandler.java:285) >> at org.zkoss.zssex.ui.DefaultExUserActionHandler.dispatchAction(DefaultExUserActionHandler.java:188) >> at org.zkoss.zss.ui.DefaultUserActionHandler.onEvent(DefaultUserActionHandler.java:1412) >> at org.zkoss.zssex.ui.DefaultExUserActionHandler.onEvent(DefaultExUserActionHandler.java:56) >> at org.zkoss.zss.ui.Spreadsheet$3.onEvent(Spreadsheet.java:343) {code}

    ZK-Tracker | 4 years ago | hawk
    org.zkoss.poi.openxml4j.exceptions.PartAlreadyExistsException: A part with the name '/xl/charts/chart2.xml' already exists : Packages shall not contain equivalent part names and package implementers shall neither create nor recognize packages with equivalent part names. [M1.12]

    Root Cause Analysis

    1. org.zkoss.poi.openxml4j.exceptions.PartAlreadyExistsException

      A part with the name '/xl/media/image2.png' already exists : Packages shall not contain equivalent part names and package implementers shall neither create nor recognize packages with equivalent part names. [M1.12]

      at org.zkoss.poi.openxml4j.opc.OPCPackage.createPart()
    2. org.zkoss.poi
      XSSFWorkbook.addPicture
      1. org.zkoss.poi.openxml4j.opc.OPCPackage.createPart(OPCPackage.java:735)
      2. org.zkoss.poi.openxml4j.opc.OPCPackage.createPart(OPCPackage.java:699)
      3. org.zkoss.poi.POIXMLDocumentPart.createRelationship(POIXMLDocumentPart.java:350)
      4. org.zkoss.poi.xssf.usermodel.XSSFWorkbook.addPicture(XSSFWorkbook.java:447)
      4 frames
    3. org.zkoss.zssex
      DrawingManagerImpl.addPicture
      1. org.zkoss.zssex.model.impl.DrawingManagerImpl.addPicture(DrawingManagerImpl.java:386)
      1 frame
    4. org.zkoss.zss
      PictureComposer.add
      1. org.zkoss.zss.model.sys.impl.XRangeImpl.addPicture(XRangeImpl.java:2332)
      2. org.zkoss.zss.api.impl.RangeImpl.addPicture(RangeImpl.java:735)
      3. org.zkoss.zss.api.SheetOperationUtil.addPicture(SheetOperationUtil.java:103)
      4. org.zkoss.zss.api.SheetOperationUtil.addPicture(SheetOperationUtil.java:89)
      5. org.zkoss.zss.api.SheetOperationUtil.addPicture(SheetOperationUtil.java:75)
      6. org.zkoss.zss.essential.PictureComposer.add(PictureComposer.java:47)
      6 frames