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

[Bug]: Some app's errors are treated as server errors #560

Open
shiipou opened this issue Mar 21, 2024 · 2 comments · May be fixed by #588
Open

[Bug]: Some app's errors are treated as server errors #560

shiipou opened this issue Mar 21, 2024 · 2 comments · May be fixed by #588
Assignees
Labels
bug Something isn't working

Comments

@shiipou
Copy link
Contributor

shiipou commented Mar 21, 2024

What happened?

As you can see on this sentry issue : https://lenra-br.sentry.io/issues/4984414382/?project=5633085

Some app errors are redirected to server as server's errors because of error in pattern matching in Elixir.
We need to change that so this error will be redirected to the app and not to our server's notifications.

What browsers are you seeing the problem on?

No response

Version

1.5.3

Relevant log output

[__exception__: true, __struct__: LenraCommon.Errors.TechnicalError, message: "Internal server error.", metadata: "Access token is undefined or empty.\t\t\t\t\t\tPlease provide a valid token.\t\t\t\t\t\tFor more help - https://github.com/microsoftgraph/msgraph-sdk-javascript/blob/dev/docs/CustomAuthenticationProvider.md

\n\tlib/services/application_services.ex:380 Elixir.ApplicationRunner.ApplicationServices.response/2\n\tlib/services/application_services.ex:74 Elixir.ApplicationRunner.ApplicationServices.run_listener/5\n\tlib/event_handler.ex:105 Elixir.ApplicationRunner.EventHandler.handle_call/3\n\tgen_server.erl:721 gen_server.try_handle_call/4\n\tgen_server.erl:750 gen_server.handle_msg/6\n\tproc_lib.erl:226 proc_lib.init_p_do_apply/3", reason: :error_500, status_code: 500]
@shiipou shiipou added the bug Something isn't working label Mar 21, 2024
@jonas-martinez
Copy link
Collaborator

It seems that this error occurs when the application returns an error 500 on its side. What I mean by that is for the example used in this issue, the application tries to connect to msgraph but fails and msgraph returns a 500 error.

Then, the application sends this 500 back to the application_runner.

The problem with this, is that we cannot determine whether the application failed on our side or on the side of the app developer.

I don't really know how to handle this, I'm looking into it.

@taorepoara
Copy link
Member

Might be linked to #563

@taorepoara taorepoara self-assigned this Sep 3, 2024
@taorepoara taorepoara linked a pull request Sep 4, 2024 that will close this issue
11 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Status: 🔵 In Review
Development

Successfully merging a pull request may close this issue.

3 participants