Commit 8746502
authored
[LOGS-1] PLU-557: Less verbose error logs (#1208)
## TL;DR
This PR enhances error handling for GraphQL requests:
- Adds special handling for `INTERNAL_SERVER_ERROR` responses to prevent leaking sensitive server details to the frontend
## How to test?
- [ ] Force an error, ensure that the generic 'An error has occurred' toast is thrown on the frontend
- [ ] Console should not show any additional information about queries
- [ ] If the query has a custom message, it should be shown in the toast in the frontend. for example, when attempting to transfer a pipe to a user that does not exist in Plumber
## Screenshots

1 parent 17bbb48 commit 8746502
File tree
2 files changed
+32
-6
lines changed- packages
- backend/src/helpers
- frontend/src/components/ApolloProvider
2 files changed
+32
-6
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1 | 1 | | |
| 2 | + | |
2 | 3 | | |
3 | 4 | | |
4 | 5 | | |
5 | 6 | | |
6 | 7 | | |
7 | 8 | | |
8 | 9 | | |
| 10 | + | |
9 | 11 | | |
10 | 12 | | |
11 | 13 | | |
| |||
86 | 88 | | |
87 | 89 | | |
88 | 90 | | |
89 | | - | |
90 | | - | |
91 | | - | |
92 | | - | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
| 95 | + | |
| 96 | + | |
| 97 | + | |
| 98 | + | |
| 99 | + | |
| 100 | + | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
| 108 | + | |
| 109 | + | |
| 110 | + | |
| 111 | + | |
| 112 | + | |
| 113 | + | |
| 114 | + | |
93 | 115 | | |
94 | 116 | | |
95 | 117 | | |
96 | | - | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
97 | 121 | | |
98 | 122 | | |
99 | 123 | | |
100 | 124 | | |
101 | 125 | | |
102 | | - | |
| 126 | + | |
103 | 127 | | |
104 | 128 | | |
105 | 129 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
| 18 | + | |
| 19 | + | |
18 | 20 | | |
19 | 21 | | |
20 | 22 | | |
| |||
0 commit comments