Export Server not configured for Highcharts-export-server

Viewed 1342

I'm using highcharts-export-server to save images of the charts and attached results when generating PDF. It was working before but now it seems to be broken. I tried to update the node.js and version of npm that I am using and it keeps giving me an error "Export Server not configured." I run node buid.js and install globally the highcharts-expert server but it still gives me the same error.

Package install: Node - 14.6.0 NPM - 7.6.3 Highcharts-export-server - 2.1.0

enter image description here

3 Answers

Check if you have the highcharts-export-server installed globally (you can do it with the npm list -g -depth 0 highcharts-export-server) and if you have, uninstall it (npm uninstall -g highcharts-export-server). After that, try to run the following command: highcharts-export-server --nologo 1 --logLevel 4 --infile ./basic.json --outfile ./chart.png --type png --width 500 and if it fails ('highcharts-export-server' is not recognized), try this one: npx ./node_modules/highcharts-export-server/bin/cli.js --nologo 1 --logLevel 4 --infile ./basic.json --outfile ./chart.png --type png --width 500. Please provide here the final results (attach the generated PNG).

In my case, I configure out that this issue cause by wrong input at the step to confirm the CND.

At CDN step, just press ENTER instead of input 'Y'. Then all the dependencies will pull from the CDN.

Run the node program, image will be generated correctly.

enter image description here

Configure the package by running commandline as follows at nodejs project root

 node node_modules/highcharts-export-server/build.js

I recommend first, export this two environment variable, export ACCEPT_HIGHCHARTS_LICENSE=1 and export HIGHCHARTS_VERSION=9.0, them run npm install.

Related