javascript-tutorial/server

Cannot start server

tarasyyyk opened this issue · 4 comments

This issue ocurrs when trying to start server:

└─[$]> PORT=1236 ./edit uk
[12:58:01] Using gulpfile ~/projects/translations/javascript-tutorial/server/gulpfile.js
[12:58:01] Starting 'edit'...
[12:58:01] Starting 'webpack'...
[12:58:01] Starting 'engine:koa:tutorial:importWatch'...
[12:58:01] Starting 'livereload'...
[12:58:01] Starting 'server'...
(node:2711) Warning: Accessing non-existent property 'lineno' of module exports inside circular dependency
(Use `node --trace-warnings ...` to show where the warning was created)
(node:2711) Warning: Accessing non-existent property 'column' of module exports inside circular dependency
(node:2711) Warning: Accessing non-existent property 'filename' of module exports inside circular dependency
(node:2711) Warning: Accessing non-existent property 'lineno' of module exports inside circular dependency
(node:2711) Warning: Accessing non-existent property 'column' of module exports inside circular dependency
(node:2711) Warning: Accessing non-existent property 'filename' of module exports inside circular dependency
Livereload server listening

... Uhoh. Got error listen EADDRINUSE: address already in use :::35729 ...
Error: listen EADDRINUSE: address already in use :::35729
    at Server.setupListenHandle [as _listen2] (net.js:1314:16)
    at listenInCluster (net.js:1362:12)
    at Server.listen (net.js:1448:7)
    at Server.listen (/Users/tarasyyyk/projects/translations/javascript-tutorial/server/node_modules/tiny-lr/src/server.js:264:19)
    at Function.exports.listen (/Users/tarasyyyk/projects/translations/javascript-tutorial/server/node_modules/gulp-livereload/index.js:97:18)
    at module.exports (/Users/tarasyyyk/projects/translations/javascript-tutorial/server/tasks/livereload.js:12:14)
    at /Users/tarasyyyk/projects/translations/javascript-tutorial/server/modules/engine/gulp/requireModuleTasks.js:11:12
    at livereload (/Users/tarasyyyk/projects/translations/javascript-tutorial/server/node_modules/undertaker/lib/set-task.js:13:15)
    at bound (domain.js:429:14)
    at runBound (domain.js:442:12)
    at asyncRunner (/Users/tarasyyyk/projects/translations/javascript-tutorial/server/node_modules/async-done/index.js:55:18)
    at processTicksAndRejections (internal/process/task_queues.js:79:11)

You already have a server listening on 35729
You should stop it and try again.

09:58:02.992Z  INFO application: Boot complete
[12:58:02] 'webpack' errored after 1.49 s
[12:58:02] ValidationError: Invalid options object. Ignore Plugin has been initialized using an options object that does not match the API schema.
 - options should be one of these:
   object { contextRegExp?, resourceRegExp? } | object { checkResource? }
   Details:
    * options has an unknown property 'checkResource'. These properties are valid:
      object { contextRegExp?, resourceRegExp? }
    * options has an unknown property 'checkContext'. These properties are valid:
      object { contextRegExp?, resourceRegExp? }
    * options has an unknown property 'checkContext'. These properties are valid:
      object { checkResource? }
    at validate (/Users/tarasyyyk/projects/translations/javascript-tutorial/server/node_modules/webpack/node_modules/schema-utils/dist/validate.js:104:11)
    at new IgnorePlugin (/Users/tarasyyyk/projects/translations/javascript-tutorial/server/node_modules/webpack/lib/IgnorePlugin.js:20:3)
    at Object.module.exports [as webpack] (/Users/tarasyyyk/projects/translations/javascript-tutorial/server/modules/config/webpack.js:272:7)
    at /Users/tarasyyyk/projects/translations/javascript-tutorial/server/tasks/webpack.js:7:36
    at new Promise (<anonymous>)
    at module.exports (/Users/tarasyyyk/projects/translations/javascript-tutorial/server/tasks/webpack.js:6:9)
    at /Users/tarasyyyk/projects/translations/javascript-tutorial/server/modules/engine/gulp/requireModuleTasks.js:11:12
    at webpack (/Users/tarasyyyk/projects/translations/javascript-tutorial/server/node_modules/undertaker/lib/set-task.js:13:15)
    at bound (domain.js:429:14)
    at runBound (domain.js:442:12)
    at asyncRunner (/Users/tarasyyyk/projects/translations/javascript-tutorial/server/node_modules/async-done/index.js:55:18)
    at processTicksAndRejections (internal/process/task_queues.js:79:11)
[12:58:02] 'edit' errored after 1.5 s

I see an error You already have a server listening on 35729. But I specifically changed port in env variable.
Also, I checked this port with command sudo lsof -i -n -P | grep 35729 and it port isn't using in my system.

System info:
node v.14.2
macOS 10.14.6

@iliakan I removed old directory with server and cloned fresh repositories today.

Please do it again (fixed).

Works now