kendo-ui-core icon indicating copy to clipboard operation
kendo-ui-core copied to clipboard

Support for latest version of jsZip

Open KirilNN opened this issue 7 years ago • 8 comments

Currently we are using a relatively old version 2.6.0 , while 3.1.3 is the latest one. Maybe we should consider an upgrade? There are a few breaking changes though:

https://stuk.github.io/jszip/documentation/upgrade_guide.html

cc @tsvetomir @mishoo

KirilNN avatar Oct 17 '16 07:10 KirilNN

The breaking change that affects us is that the generate() method has been replaced by generateAsync(). The upgrade will introduce a breaking change in toDataUrl, making it asynchronous. I believe we could maintain backwards compatibility with jsZip 2, with a feature detection on generateAsync.

gyoshev avatar Oct 17 '16 07:10 gyoshev

I think the Workbook.toDataURL is the only method that relies on jsZip and is synchronous.

We can replace it with an asynchronous version of the method that will work with any version of jsZip. The old one will stay, but will require jsZip < 3.

tsvetomir avatar Dec 22 '16 09:12 tsvetomir

Also reported in ticket with id 1125537.

TsvetinaIvanova avatar Aug 17 '17 07:08 TsvetinaIvanova

Kendo UI 2018.3.1017 is using jsZip 2.6.1 . No update to 3.1.3 was done.

Dimitar-Goshev avatar Nov 14 '18 09:11 Dimitar-Goshev

Is this planned for the future?

I stumble across an issue where exporting to excel failed because it is using a lot of memory and jszip v3 seems to have some fix about this. Stuk/jszip#446

fugaku avatar Apr 21 '19 14:04 fugaku

Reopening this as there is also a known vulnerability with jsZip versions prior to 3.7: https://security.snyk.io/vuln/SNYK-JS-JSZIP-1251497

veselints avatar Jan 31 '22 15:01 veselints

Better late than never. We'll need to:

  • Replace all usages toDataURL with toDataURLAsync, most notably in the Spreadsheet. This method works with both jsZip 2 and 3.
  • Update the bundled version of jsZip to 3.7.1
  • Test that everything that has to deal with jsZip still works.

tsvetomir avatar Jan 31 '22 16:01 tsvetomir

rising priority as it has been asked for again

veselints avatar Mar 29 '22 12:03 veselints

rising priority as it has been asked for again

veselints avatar Jan 05 '23 11:01 veselints

Raising again 1594128

gdenchevprog avatar Jan 19 '23 09:01 gdenchevprog

Also reported in 1595850.

IvanDanchev avatar Feb 01 '23 12:02 IvanDanchev

I am using react-export-excel package in my project which internally uses jszip 3.8.0. With this version of jszip the export functionality is not working and giving me below error:

   Uncaught Error: This method has been removed in JSZip 3.0, please check the upgrade guide.
at r.generate (jszip.min.js:13:16610)
at xlsx.js:11863:27
at Object.Vu [as write] (xlsx.js:11874:19)
at t.value (ExcelFile.js:104:34)
at Object.m (react-dom.production.min.js:15:205)
at S (react-dom.production.min.js:15:359)
at react-dom.production.min.js:16:35
at k (react-dom.production.min.js:16:236)
at M (react-dom.production.min.js:17:224)
at T (react-dom.production.min.js:17:57)

I know this is a known issue with jszip 3.X.X. Do we have any solution yet?

ericjai avatar Feb 15 '23 07:02 ericjai

Veracode scan detect vulnerabilities. Is it planned to add the compatibility with the last version of jszip soon ?

T4YoO avatar Mar 22 '23 17:03 T4YoO

+1

sgc-fireball avatar Aug 31 '23 12:08 sgc-fireball

Better late than never. We'll need to:

  • Replace all usages toDataURL with toDataURLAsync, most notably in the Spreadsheet. This method works with both jsZip 2 and 3.
  • Update the bundled version of jsZip to 3.7.1
  • Test that everything that has to deal with jsZip still works.

Correct way to workaround the issue available in this Dojo

StoyanGoranov avatar Oct 03 '23 11:10 StoyanGoranov

When this item is completed the message:

  • As of the current release, the Excel Export feature supports JSZip 2.* and 3.* versions. Kendo UI releases prior to current provided Excel export only of JSZip 2.* versions.

should be added back to the following files:

  • kendo\docs\framework\excel\get-started.md
  • kendo\docs-aspnet\installation\system-requirements\export-support.md

StoyanGoranov avatar Oct 04 '23 08:10 StoyanGoranov

Kendo UI for jQuery/MVC/Core(Exporting) is compatible with JSZip 3.x starting v2023.3.1114 (R3 2023 SP1).

gdenchevprog avatar Nov 30 '23 11:11 gdenchevprog

R3 2023 SP1 and jsZip 3.10.1 still throws error when using Spreadsheet widget and the "fromFile" method. Should this also work? I expected this to be also resolved...

odin568 avatar Jan 15 '24 14:01 odin568

Hi, @odin568 ,

We are aware of this bug and a fix was recently deployed. The patch should be available with the upcoming release.

We apologize about the caused inconvenience.

gdenchevprog avatar Jan 15 '24 14:01 gdenchevprog

Hi, @odin568 ,

We are aware of this bug and a fix was recently deployed. The patch should be available with the upcoming release.

We apologize about the caused inconvenience.

What's a rough ETA on this upcoming release if I may ask?

binaryn3xus avatar Jan 16 '24 16:01 binaryn3xus

Hey, @binaryn3xus ,

The release is currently scheduled for the 31st of January.

gdenchevprog avatar Jan 16 '24 16:01 gdenchevprog