smaica
Posts: 4
Joined: Sat Oct 08, 2022 11:11 am

Unable to export Chart with up to 10 series - 500 error

Hi,

in my next.js 14 app I'm trying to export a charts on the client side to .png format with

Code: Select all

import Highcharts from "highcharts/highstock";

import exportingOption from 'highcharts/modules/exporting';
import offlineOption from 'highcharts/modules/offline-exporting';
exportingOption(Highcharts);
offlineOption(Highcharts);
I get a 500 server error when I do this with a chart that has more then 4 series.
As soon as I remove some of them, it doesn't matter which, I can export the chart.

Is this a known error? Does anyone have an idea?
Thank you very much!
smaica
Posts: 4
Joined: Sat Oct 08, 2022 11:11 am

Re: Unable to export Chart with up to 10 series - 500 error

So I found what caused the error. I disabled datagrouping in my options:

Code: Select all

plotOptions: {
    series: {
        dataGrouping:{
            enabled: false
        },
     },
  },

when I remove these lines, the chart can be exported without problems. All of my charts with multiple series actually.

Still I don't know exactly what happend when disabling but somehow the server gets overloaded or something?
jakub.s
Site Moderator
Posts: 1378
Joined: Fri Dec 16, 2022 11:45 am

Re: Unable to export Chart with up to 10 series - 500 error

Hi,

Thanks for the question!

From this topic: viewtopic.php?t=52554 I conclude that most likely the export is online, through our Export Server. The offline-exporting module, for some reason that I cannot really diagnose without looking at a minimal reproducible example, seems to not be taken into account in your export.

If that's the case, the issue that you're most likely encountering is the following one: https://github.com/highcharts/node-expo ... issues/490 which has already been solved on our Export Server repository and will be a part of the upcoming major release (v4.0.0).

Let me know if you have any more questions about any of this.

Best regards!
Jakub
Highcharts Developer

Return to “Highcharts Usage”