catamphetamine / read-excel-file

Read *.xlsx files in a browser or Node.js. Parse to JSON with a strict schema.
https://catamphetamine.gitlab.io/read-excel-file/
MIT License
301 stars 52 forks source link

"sharedStrings.xml" file not found in the *.xlsx file #79

Closed alur222 closed 4 years ago

alur222 commented 4 years ago

Hi, please help.

i just encountered a weird issue. I am not sure how this file was generated but I got this error from console in production environment.

2020-05-20 10:28:16,879 ERROR 73272 nodejs.unhandledRejectionError: "sharedStrings.xml" file not found in the *.xlsx file
    at parseFileNames (/OMITTED/node_modules/read-excel-file/commonjs/readXlsx.js:559:11)
    at readXlsx (/OMITTED/node_modules/read-excel-file/commonjs/readXlsx.js:50:19)
    at readXlsxFileContents (/OMITTED/node_modules/read-excel-file/commonjs/readXlsxFileContents.js:22:38)
    at /OMITTED/node_modules/read-excel-file/commonjs/readXlsxFileNode.js:33:47
    at process._tickCallback (internal/process/next_tick.js:68:7)

any ideas?

catamphetamine commented 4 years ago

I guess the file was generated incorrectly or something. Maybe it only contains numbers, not strings. There's no clear spec saying whether sharedStrings.xml is supposed to always be present or not.

alur222 commented 4 years ago

Thank you. I really dont know why but xlsx.js was able to parse it.