alibaba / alibaba/anyproxy

希望在合并用户规则和默认规则时考虑原型

Open
#542 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
7.9k
Forks
1.2k
PR merge metrics
No merged PRs in 30d

Description

Plese fill the template when you reporting a new issue, thanks!

在使用用户配置的时候,我将用户配置的生成过程写入一个类,也就是说`beforeSendResponse`等方法的实现事实上是在rule参数提供的对象的`prototype`中。在AnyProxy处理用户配置的时候,将userRule与default_rule对象合并而没有考虑原型,从而导致我的回调函数丢失。希望能在之后的版本更新中考虑原型的情况。谢谢!

#### Which platform are you running AnyProxy

Windows 10 1909

#### The version of the AnyProxy

4.1.0

Contributor guide

No contributing guide indexed for this repository

Research direction

Start by tracing how AnyProxy merges the userRule and default_rule objects, focusing on the beforeSendResponse callback and the prototype mentioned in the report. Reproduce the configuration behavior on AnyProxy 4.1.0, then verify that callbacks defined on the rule object's prototype remain available after merging.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, nodejs
Domain
networking
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.