Bug 140910 - Blank XLSX file generated with OpenXML SDK
Summary: Blank XLSX file generated with OpenXML SDK
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: LibreOffice (show other bugs)
Version:
(earliest affected)
7.1.1.2 release
Hardware: All All
: low normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: MSO-External-Producers
  Show dependency treegraph
 
Reported: 2021-03-09 09:28 UTC by JohnR
Modified: 2023-10-19 02:44 UTC (History)
8 users (show)

See Also:
Crash report or crash signature:


Attachments
its a xlsx file with 5 rows (20.17 KB, application/vnd.openxmlformats-officedocument.spreadsheetml.sheet)
2021-03-09 09:59 UTC, JohnR
Details
the file repaired by Excel 2016 (10.81 KB, application/vnd.openxmlformats-officedocument.spreadsheetml.sheet)
2021-03-09 10:53 UTC, himajin100000
Details
New file with one row (6.74 KB, application/vnd.openxmlformats-officedocument.spreadsheetml.sheet)
2021-03-09 13:34 UTC, JohnR
Details
smaller reproducible document ( with freezed pane ) (9.16 KB, application/vnd.openxmlformats-officedocument.spreadsheetml.sheet)
2021-03-09 14:02 UTC, himajin100000
Details

Note You need to log in before you can comment on or make changes to this bug.
Description JohnR 2021-03-09 09:28:51 UTC
Description:
I have generated xlsx file using Open XML SDK structure and file is loaded blank. If you try to open it in Microsoft Excel it shows data, and if you just save it, it can be also read by LibreOffice. Seems like structure of generated XML is not readable by Libre, but im not sure.

Steps to Reproduce:
1. Open XLSX file


Actual Results:
Blank file

Expected Results:
Loaded file with 5 rows of data


Reproducible: Always


User Profile Reset: No



Additional Info:
I can send example of docs if needed.
Comment 1 JohnR 2021-03-09 09:59:43 UTC
Created attachment 170364 [details]
its a xlsx file with 5 rows

File has 5 rows not readable by libre
Comment 2 himajin100000 2021-03-09 10:40:35 UTC
according to Excel, some cell information needed repairing.

when I load the repaired file in LibreOffice, I can see the contents.
Comment 3 himajin100000 2021-03-09 10:41:47 UTC
Version: 7.2.0.0.alpha0+ (x64) / LibreOffice Community
Build ID: dc3b64dcbfb0a49c0be65bd8d73ed4e6d3828a21
CPU threads: 4; OS: Windows 10.0 Build 19042; UI render: default; VCL: win
Locale: ja-JP (ja_JP); UI: en-US
Calc: CL
Comment 4 himajin100000 2021-03-09 10:53:31 UTC
Created attachment 170365 [details]
the file repaired by Excel 2016
Comment 5 JohnR 2021-03-09 12:59:44 UTC
Yes, its repaired when open in Excel and save. But do you know what cell need reparation ?

I've loaded xlsx in OOXML viwer and difference is in app.xml auto generated by SDK where 

Difference in app.xml:
Repaired file:

<TitlesOfParts>
    <vt:vector size="1" baseType="lpstr">
      <vt:lpstr>
        Sheet1
      </vt:lpstr>
    </vt:vector>
  </TitlesOfParts>

    <AppVersion>
    14.0300
   </AppVersion>

Original file:
 <TitlesOfParts>
    <vt:vector size="1" baseType="lpstr">
      <vt:lpstr>
        anton
      </vt:lpstr>
    </vt:vector>
  </TitlesOfParts>

   <AppVersion>
    16.0300
  </AppVersion>


Other difference in SharedStrings.xml (self closing tag)
Original file:
  <si>
    <t></t>
  </si>

Repaired file:
 <si>
    <t/>
  </si>
Comment 6 JohnR 2021-03-09 13:34:27 UTC
Created attachment 170371 [details]
New file with one row

I've added a new file, with one row. Excel didnt display any problem about corrupted cells or problem with contetn. But its blank in Libre.

Thanks for reply
Comment 7 himajin100000 2021-03-09 14:02:18 UTC Comment hidden (obsolete)
Comment 8 himajin100000 2021-03-09 14:03:35 UTC Comment hidden (obsolete)
Comment 9 himajin100000 2021-03-09 18:40:39 UTC
just a guess (possible cause?)

case-sensitiveness of the filename "sheet1.xml" and "Sheet1.xml"
Comment 10 himajin100000 2021-03-09 19:08:13 UTC
possible source code pointer?

https://opengrok.libreoffice.org/xref/core/oox/source/core/xmlfilterbase.cxx?r=99bc040b#395
Comment 11 JohnR 2021-03-10 11:31:58 UTC
Yes thats the problem. Even if pointer in workbook is Sheet1 it can't be read unless its lower case.

Thank you for solving this issue!
Comment 12 Roman Kuznetsov 2021-03-11 12:06:28 UTC
(In reply to himajin100000 from comment #2)
> according to Excel, some cell information needed repairing.
> 
> when I load the repaired file in LibreOffice, I can see the contents.

Are we sure it's LO's problem?
Comment 13 JohnR 2021-03-11 12:32:50 UTC
After I've replaced xl/worksheets/Sheet1.xml to xl/worksheets/sheet1.xml content is loaded normal in Libre, even stylings and filters are displayed. Im not sure why there is check for LO, maybe some convention...
Comment 14 Julien Nabet 2021-03-13 18:31:52 UTC
(In reply to himajin100000 from comment #10)
> possible source code pointer?
> 
> https://opengrok.libreoffice.org/xref/core/oox/source/core/xmlfilterbase.
> cxx?r=99bc040b#395

Yes it's related but the pb is LO uses one of these:
- [Content_Types].xml
- xl/_rels/workbook.xml.rels
Indeed, if you unzip the xlsx, you'll see:
sheet1.xml

So the simplest thing would be to fix Open-XML-SDK so it would be coherent and about this bugtracker, I would put NOTOURBUG/NOTABUG but just my opinion.

László: any thoughts here?
Comment 15 Xisco Faulí 2021-04-30 09:57:35 UTC
This looks similar to bug 100084.

@Balazs Varga, I thought you might be interested in this issue
Comment 16 Timur 2023-10-18 10:05:47 UTC
Since there were no more traction here, I close as proposed.
Comment 17 Aron Budea 2023-10-19 02:44:37 UTC
Excel opens the file and shows it as expected, and since that is the reference for OOXML files, Calc should do the same, regardless whether the file conforms to the standard or not.