Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Question] 在V3的版本中,没法控制当前异常是否发送报告 #48

Closed
shuqingzai opened this issue Aug 19, 2023 · 5 comments
Closed
Assignees

Comments

@shuqingzai
Copy link

Is your feature request related to a problem? Please describe.

V3 版本似乎会把所有异常上报,当然是可以从 config 中配置,但是用户有时候需要的是同一个异常(可能是一个业务通用异常,但是按不同的 code 或 message 区分)进行不同的逻辑处理,甚至不需要上报这个异常,比如:Symfony\Component\HttpKernel\Exception\HttpException::class http 响应异常,在 httpStatusCode >= 500 我才需要上传,一些 500 以下,比如参数验证错误,客户端请求参数错误,这些我无需上报,这在目前是没法实现

Describe the solution you'd like

希望 V3 可以把异常上报的主动权交还给用户,就像以前 V2 版,我自己在 app/Exceptions/Handler.php 中决定,不是由扩展包对我的业务做决定

Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.

Additional context
Add any other context or screenshots about the feature request here.

@create-issue-branch
Copy link

@shuqingzai
Copy link
Author

shuqingzai commented Aug 19, 2023

是否可以把

protected function extendExceptionHandler(): self
这个特性做成配置项??? @guanguans

@Issues-translate-bot
Copy link

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


Is it possible to make the feature of

protected function extendExceptionHandler(): self
a configuration item? ? ?

@guanguans
Copy link
Owner

guanguans commented Aug 19, 2023

是否可以把

protected function extendExceptionHandler(): self
这个特性做成配置项??? @guanguans

我看看改一下。

@Issues-translate-bot
Copy link

Bot detected the issue body's language is not English, translate it automatically. 👯👭🏻🧑‍🤝‍🧑👫🧑🏿‍🤝‍🧑🏻👩🏾‍🤝‍👨🏿👬🏿


Is it possible to make the feature of

protected function extendExceptionHandler(): self
a configuration item? ? ? @guanguans

OK, let me check it out.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants