pomelo icon indicating copy to clipboard operation
pomelo copied to clipboard

start server error

Open disemboltura opened this issue 8 years ago • 11 comments

npm 卸载pomelo ,再重新安装 run command : pomelo --verion // 2.2.5 use command: pomelo init to create project directory layouts run command on windows 7 : npm-install.bat
goto game-server directory , run : pomelo start

(pomelo init 选择通信方式的时候,选择的是2: socket.io)

errors: [2017-02-13 17:29:32.674] [ERROR] console - Option path is not valid. Please refer to the README. [2017-02-13 17:29:32.675] [ERROR] console - Option close timeout is not valid. Please refer to the README. [2017-02-13 17:29:32.675] [ERROR] console - Option heartbeats is not valid. Please refer to the README. [2017-02-13 17:29:32.675] [ERROR] console - Option log level is not valid. Please refer to the README

这是从项目的game-server\node_modules\socket.io\lib\index.js 中找到的源码: `/**

  • Old settings for backwards compatibility */

var oldSettings = { "transports": "transports", "heartbeat timeout": "pingTimeout", "heartbeat interval": "pingInterval", "destroy buffer size": "maxHttpBufferSize" };

/**

  • Backwards compatibility.
  • @api public */

Server.prototype.set = function(key, val){ if ('authorization' == key && val) { this.use(function(socket, next) { val(socket.request, function(err, authorized) { if (err) return next(new Error(err)); if (!authorized) return next(new Error('Not authorized')); next(); }); }); } else if ('origins' == key && val) { this.origins(val); } else if ('resource' == key) { this.path(val); } else if (oldSettings[key] && this.eio[oldSettings[key]]) { this.eio[oldSettings[key]] = val; } else { console.error('Option %s is not valid. Please refer to the README.', key); }

return this; };`

请问是什么情况

disemboltura avatar Feb 13 '17 09:02 disemboltura

have same issue...

falqs avatar Mar 12 '17 07:03 falqs

同样的问题,pomelo哪个node版本支持的最好?

codeorg avatar Mar 17 '17 03:03 codeorg

node 7 版本出现一样的问题,然后请求出错。所以先回退吧

zyf0330 avatar Mar 21 '17 02:03 zyf0330

I have the same issue

ighack avatar Apr 01 '17 05:04 ighack

I have the same issue

albus01 avatar Apr 18 '17 03:04 albus01

这个是sioconnect.js 使用socketio时传入了 不支持的参数 估计是因为升级但是有些接口没去修改引起的

应该 不影响执行 但是希望能尽快修复下

zmox avatar Apr 18 '17 07:04 zmox

[2017-04-20 08:53:33.375] [INFO] pomelo - 377: [/root/WebstormProjects/treasures/game-server/node_modules/pomelo/lib/application.js] "gate-server-1" enter after start...
[2017-04-20 08:53:33.722] [ERROR] console - Option path is not valid. Please refer to the README.
[2017-04-20 08:53:33.723] [ERROR] console - Option close timeout is not valid. Please refer to the README.
[2017-04-20 08:53:33.723] [ERROR] console - Option heartbeats is not valid. Please refer to the README.
[2017-04-20 08:53:33.723] [ERROR] console - Option log level is not valid. Please refer to the README.
[2017-04-20 08:53:33.723] [INFO] console - sio Server listening at port 3015

@zmox 你说的太好了 请官方的人看一下这个错误 @fantasyni @py8765

源码

app.configure('production|development', 'gate', function () {
    app.set('connectorConfig', {
        connector: pomelo.connectors.sioconnector
    });
});

SteveCruise avatar Apr 20 '17 01:04 SteveCruise

 目测官方不维护?都写游戏挣 钱去了?

codeorg avatar Apr 20 '17 05:04 codeorg

Actually i'm upgrading to pomelo 2.2.5 to avoid: https://github.com/NetEase/pomelo/issues/903

And i find myself in this issue... Did someone avoid this?

frabaglia avatar Jun 20 '17 20:06 frabaglia

http://nodejs.netease.com/topic/5880dee5489e266d5b187381#59094805489e266d5b459fb3

robertwang1987 avatar Sep 06 '17 02:09 robertwang1987

It's due to the changes in this commit: https://github.com/NetEase/pomelo/commit/cbbf1585acf85e53a07d858a2ec170f0ff413a91

Socket.IO 1.7.x doesn't have these properties "path", "close timeout", "heartbeats", "log level"

baochungit avatar Sep 03 '18 15:09 baochungit