v2fly / v2ray-core

A platform for building proxies to bypass network restrictions.
https://v2fly.org
MIT License
29.6k stars 4.66k forks source link

JsonV5设置timeout中的ConnectionIdle/handshake等参数无法启动 #2206

Closed U-Insane closed 1 year ago

U-Insane commented 1 year ago

What version of V2Ray are you using?

V5.1.0 X86-64 Linux

What's your scenario of using V2Ray?

What problems have you encountered?

配置中加入如下内容调整本地策略中的超时策略时出现无法启动的情况,和 https://github.com/v2fly/v2ray-core/issues/1591 情况类似

What's your expectation?

Please attach your configuration here

Server configuration:

// Please attach your server configuration here.

Client configuration:

// Please attach your client configuration here.
{
    "services": {
        "policy":{
            "level": {
                "0":{
                "timeout":{
                       "connectionIdle": 60 //"handshake": 60
                       }
                    }
                 }  
        }
    }
  }

Please attach error logs here

Server error log:

// Please attach your server error log here.

Client error log:

// Please attach your client error log here.
v2ray run -config /etc/v2ray/config.json -format jsonv5
V2Ray 5.1.0 (V2Fly, a community-driven edition of V2Ray.)
A unified platform for anti-censorship.
Failed to start: main/commands: failed to load config: [/etc/v2ray/config.json] > infra/conf/v5cfg: unable to build config > common/registry: unable to parse json content > json: cannot unmarshal number into Go value of type map[string]json.RawMessage

Please attach access log here

// Please attach your server access log here.

Other configurations (such as Nginx) and logs here

If V2Ray cannot start up, please attach output from --test command

v2ray run -config /etc/v2ray/config.json -format jsonv5 V2Ray 5.1.0 (V2Fly, a community-driven edition of V2Ray.) A unified platform for anti-censorship. Failed to start: main/commands: failed to load config: [/etc/v2ray/config.json] > infra/conf/v5cfg: unable to build config > common/registry: unable to parse json content > json: cannot unmarshal number into Go value of type map[string]json.RawMessage

If V2Ray service is abnormal, please attach journal log here

github-actions[bot] commented 1 year ago

This issue is stale because it has been open 120 days with no activity. Remove stale label or comment or this will be closed in 5 days