- A+
对于19.5及以上版本,更新后,部分或者全部节点超时,请按照以下操作即可解决,测试有效。或者替换clash老核心。
Windows:
对于0.19.4及以下用户,无需更改
对于0.19.5及以上用户,请点击Settings-Profiles-Parsers-Edit(设置-配置-预处理配置-编辑),删除默认的 parsers: #array ,并粘贴以下内容
parsers:
- reg: '^.*$'
code: |
module.exports.parse = async (raw, { axios, yaml, notify, console }, { name, url, interval, selected }) => {
const obj = yaml.parse(raw)
obj.proxies.forEach( v => {
if (v.network === 'ws' && !v['ws-opts'] && v['ws-path'] && !v['ws-headers']) {
const opts = {}
opts.path = v['ws-path']
v['ws-opts'] = opts
delete v['ws-path']
}
if (v.network === 'ws' && !v['ws-opts'] && v['ws-path'] && v['ws-headers']) {
const opts = {}
opts.path = v['ws-path']
opts.headers = v['ws-headers']
v['ws-opts'] = opts
delete v['ws-path']
delete v['ws-headers']
}
})
return yaml.stringify(obj)
}
然后更新订阅(注意,parsers内容仅在更新订阅时生效,一定要更新一次订阅)