Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

TypeError next(@ag-grid-community/csv-export/dist/package/main.esm) #7805

Closed
n19htz opened this issue Apr 2, 2024 · 4 comments
Closed

TypeError next(@ag-grid-community/csv-export/dist/package/main.esm) #7805

n19htz opened this issue Apr 2, 2024 · 4 comments

Comments

@n19htz
Copy link

n19htz commented Apr 2, 2024

I'm submitting a ... (check one with "x")

[x] bug report => see 'Providing a Reproducible Scenario'
[] feature request => do not use Github for feature requests, see 'Customers of AG Grid'
[] support request => see 'Requesting Community Support'

Providing a Reproducible Scenario
No any special reproduction required

Current behavior
error happens as provided on the screenshots.

Screenshot 2024-04-02 at 17 06 19 Screenshot 2024-04-02 at 17 08 24

raw:

TypeError: undefined is not a constructor (evaluating 'new window.CompressionStream("deflate-raw")')
at next(node_modules/@ag-grid-community/csv-export/dist/package/main.esm.mjs:1144:37)
at generatorResume([native code])
at executor(node_modules/@ag-grid-community/csv-export/dist/package/main.esm.mjs:47:61)
at new ZoneAwarePromise(node_modules/zone.js/fesm2015/zone.js:1425:21)
at __async(node_modules/@ag-grid-community/csv-export/dist/package/main.esm.mjs:31:14)
at next(node_modules/@ag-grid-community/csv-export/dist/package/main.esm.mjs:1156:13)
at generatorResume([native code])
at executor(node_modules/@ag-grid-community/csv-export/dist/package/main.esm.mjs:47:61)
at new ZoneAwarePromise(node_modules/zone.js/fesm2015/zone.js:1425:21)
at __async(node_modules/@ag-grid-community/csv-export/dist/package/main.esm.mjs:31:14)
at next(node_modules/@ag-grid-community/csv-export/dist/package/main.esm.mjs:1174:26)
at generatorResume([native code])
at executor(node_modules/@ag-grid-community/csv-export/dist/package/main.esm.mjs:47:61)
at new ZoneAwarePromise(node_modules/zone.js/fesm2015/zone.js:1425:21)
at __async(node_modules/@ag-grid-community/csv-export/dist/package/main.esm.mjs:31:14)
at next(node_modules/@ag-grid-community/csv-export/dist/package/main.esm.mjs:1355:30)
at generatorResume([native code])
at fulfilled(node_modules/@ag-grid-community/csv-export/dist/package/main.esm.mjs:34:24)
at zone._inner.onInvoke(node_modules/@angular/core/fesm2022/core.mjs:14882:33)
at Zone.run(node_modules/zone.js/fesm2015/zone.js:130:43)
at invokeTask(node_modules/zone.js/fesm2015/zone.js:1260:36)
at zone._inner.onInvokeTask(node_modules/@angular/core/fesm2022/core.mjs:14869:33)
at Zone.runTask(node_modules/zone.js/fesm2015/zone.js:174:47)
at drainMicroTaskQueue(node_modules/zone.js/fesm2015/zone.js:582:35)
at ZoneTask.invokeTask(node_modules/zone.js/fesm2015/zone.js:488:21)
at invokeTask(node_modules/zone.js/fesm2015/zone.js:1645:18)
at globalCallback(node_modules/zone.js/fesm2015/zone.js:1688:33)

Expected behavior
No error should be happening.

  • AG Grid version: X.X.X
    "@ag-grid-community/angular": "31.2.0",
    "@ag-grid-community/client-side-row-model": "31.2.0",
    "@ag-grid-community/csv-export": "31.2.0",
    "@ag-grid-community/styles": "31.2.0",
    "@ag-grid-enterprise/clipboard": "31.2.0",
    "@ag-grid-enterprise/column-tool-panel": "31.2.0",
    "@ag-grid-enterprise/excel-export": "31.2.0",
    "@ag-grid-enterprise/filter-tool-panel": "31.2.0",
    "@ag-grid-enterprise/master-detail": "31.2.0",
    "@ag-grid-enterprise/menu": "31.2.0",
    "@ag-grid-enterprise/multi-filter": "31.2.0",
    "@ag-grid-enterprise/range-selection": "31.2.0",
    "@ag-grid-enterprise/rich-select": "31.2.0",
    "@ag-grid-enterprise/row-grouping": "31.2.0",
    "@ag-grid-enterprise/set-filter": "31.2.0",
    "@ag-grid-enterprise/status-bar": "31.2.0",

  • Browser:
    Safari Version:16.1

  • Language:
    angular@17.3.2
    typescript@5.4.3

@AG-Zoheil
Copy link

Hi @n19htz,

Thank you for reporting this.

We'd be happy to look into this, but a screenshot from Sentry will not allow us to investigate this properly. The most efficient way for us to do so would be for you to provide a live example reproducing the issue so we can see the configuration of your grid.

Please send us a live plunker sample which shows the issue. You can use one of the examples from our website as a starting point. Do let us know if you need further guidance on this.

We're looking forward to your response.

Kind regards,
Zoheil

@n19htz
Copy link
Author

n19htz commented Apr 4, 2024

Trying to reproduce, but no luck yet. Meanwhile I got another sentry error related to this issue. Here is a screenshot:
Screenshot 2024-04-04 at 11 09 46

@daryakalenik
Copy link

Bug seems to be related to the browser version. Users experiencing the issue are using older versions of browsers such as Yandex Browser 22.7.5 and Safari 16.1 (both released in 2022). The error does not occur in newer browser versions when performing similar actions. I was able to reproduce it using Yandex 22.7.5, but I assume the behavior would be similar with Safari.

Steps to Reproduce:

  1. Download an older version of the browser (Yandex 22.7.5, Safari 16.1)
  2. Navigate to the page https://ag-grid.com/angular-data-grid/excel-export/
  3. Click on the "Export to Excel" button
  4. In the console, the following error occurs: "Error: Uncaught (in promise): TypeError: Failed to construct 'CompressionStream' ..."

@AG-Zoheil
Copy link

Hi @daryakalenik & @n19htz,

This occurs due to a dependency on compressionStream since AG Grid v31.1.

Please either upgrade your Safari version to 16.4 or above (as that's when compressionStream was added to Safari) or if you need to rely on an older version of Safari please use AG Grid v31.0 as compression for Excel files is the default behaviour from v31.1 onwards.

Kind regards,
Zoheil

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants