Error messages after "npm start"

Hello,

after typing “npm start” I get the following messages. After that the sample files can not be opened. The circle stops at the half.

Best regards,
Ralph

> @pdftron/pdfjs-express-viewer@8.4.0 start /var/www/html/moodle4/pdftest
> npm run samples


> @pdftron/pdfjs-express-viewer@8.4.0 samples /var/www/html/moodle4/pdftest
> npm run server samples


> @pdftron/pdfjs-express-viewer@8.4.0 server /var/www/html/moodle4/pdftest
> node server.js $* "samples"

Listening at localhost:3000 (http://80.239.207.213:3000)
(node:437667) UnhandledPromiseRejectionWarning: Error: Exited with code 3
    at ChildProcess.cp.once.code (/var/www/html/moodle4/pdftest/node_modules/opn/index.js:85:13)
    at Object.onceWrapper (events.js:286:20)
    at ChildProcess.emit (events.js:198:13)
    at maybeClose (internal/child_process.js:982:16)
    at Socket.stream.socket.on (internal/child_process.js:389:11)
    at Socket.emit (events.js:198:13)
    at Pipe._handle.close (net.js:607:12)
(node:437667) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
(node:437667) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.

Hello Ralph,

I was unable to reproduce this issue, here are the steps I took:

  1. I downloaded the latest Zip file from here: PDF.js Express Viewer Download & Integration | Documentation
  2. I extracted the Zip file
  3. I ran npm install
  4. I then ran npm run start

Do these steps work for you?
What version of Node are you using?
What steps do you take to reproduce this issue?

Best regards,
Tyler Gordon
Web Development Support Engineer
PDFTron

Hi Tyler,

unfortunately I do not know node etc. at all. My only concern is to make it easier to work with PDF files.

How can I find out which version node has?

Here again the complete and reproducible message after calling “npm run start”.

root@ods13:/var/www/html/moodle4/pdftest# npm run start

> @pdftron/pdfjs-express-viewer@8.4.0 start /var/www/html/moodle4/pdftest
> npm run samples


> @pdftron/pdfjs-express-viewer@8.4.0 samples /var/www/html/moodle4/pdftest
> npm run server samples


> @pdftron/pdfjs-express-viewer@8.4.0 server /var/www/html/moodle4/pdftest
> node server.js $* "samples"

Listening at localhost:3000 (http://80.239.207.213:3000)
(node:465681) UnhandledPromiseRejectionWarning: Error: Exited with code 3
    at ChildProcess.cp.once.code (/var/www/html/moodle4/pdftest/node_modules/opn/index.js:85:13)
    at Object.onceWrapper (events.js:286:20)
    at ChildProcess.emit (events.js:198:13)
    at maybeClose (internal/child_process.js:982:16)
    at Socket.stream.socket.on (internal/child_process.js:389:11)
    at Socket.emit (events.js:198:13)
    at Pipe._handle.close (net.js:607:12)
(node:465681) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
(node:465681) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.

Best regards,
Ralph

Hi Tyler,

Unfortunately I do not know node etc. at all. My only concern is to make it easier to work with PDF files.

How can I find out which version node has?

Here again the complete and reproducible message after calling “npm run start”.

root@ods13:/var/www/html/moodle4/pdftest# npm run start

> @pdftron/pdfjs-express-viewer@8.4.0 start /var/www/html/moodle4/pdftest
> npm run samples


> @pdftron/pdfjs-express-viewer@8.4.0 samples /var/www/html/moodle4/pdftest
> npm run server samples


> @pdftron/pdfjs-express-viewer@8.4.0 server /var/www/html/moodle4/pdftest
> node server.js $* "samples"

Listening at localhost:3000 (http://80.239.207.213:3000)
(node:465681) UnhandledPromiseRejectionWarning: Error: Exited with code 3
    at ChildProcess.cp.once.code (/var/www/html/moodle4/pdftest/node_modules/opn/index.js:85:13)
    at Object.onceWrapper (events.js:286:20)
    at ChildProcess.emit (events.js:198:13)
    at maybeClose (internal/child_process.js:982:16)
    at Socket.stream.socket.on (internal/child_process.js:389:11)
    at Socket.emit (events.js:198:13)
    at Pipe._handle.close (net.js:607:12)
(node:465681) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 1)
(node:465681) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.

Best regards,
Ralph

Hi Tyler,

look there. I can not write my answer.

Ralph

Hello Ralph,

You can check your node version with node -v
Did you try the steps I outlined previously?

Best regards
Tyler Gordon
Web Development Support Engineer
PDFTron