Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
f9fef437
Commit
f9fef437
authored
Jun 01, 2021
by
Sean McGivern
Committed by
Quang-Minh Nguyen
Jun 02, 2021
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Apply 3 suggestion(s) to 2 file(s)
parent
8d3d6410
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
3 deletions
+4
-3
lib/gitlab/error_tracking.rb
lib/gitlab/error_tracking.rb
+2
-1
lib/gitlab/error_tracking/processor/sanitizer_processor.rb
lib/gitlab/error_tracking/processor/sanitizer_processor.rb
+2
-2
No files found.
lib/gitlab/error_tracking.rb
View file @
f9fef437
...
...
@@ -33,6 +33,7 @@ module Gitlab
config
.
environment
=
Gitlab
.
config
.
sentry
.
environment
config
.
before_send
=
method
(
:before_send
)
config
.
background_worker_threads
=
0
config
.
send_default_pii
=
true
yield
config
if
block_given?
end
...
...
@@ -106,7 +107,7 @@ module Gitlab
def
process_exception
(
exception
,
sentry:
false
,
logging:
true
,
extra
:)
context_payload
=
Gitlab
::
ErrorTracking
::
ContextPayloadGenerator
.
generate
(
exception
,
extra
)
# There is a possiblity that this method is called before Sentry is
# There is a possib
i
lity that this method is called before Sentry is
# configured. Since Sentry 4.0, some methods of Sentry are forwarded to
# to `nil`, hence we have to check the client as well.
if
sentry
&&
::
Sentry
.
get_current_client
&&
::
Sentry
.
configuration
.
dsn
...
...
lib/gitlab/error_tracking/processor/sanitizer_processor.rb
View file @
f9fef437
...
...
@@ -8,8 +8,8 @@ module Gitlab
SANITIZED_ATTRIBUTES
=
%i[user contexts extra tags]
.
freeze
# This processor removes sensitive fields or headers from the event
# before sending Sentry versions above 4.0 don't support
# sanitized_fi
le
ds and sanitized_http_headers anymore. The official
# before sending
.
Sentry versions above 4.0 don't support
# sanitized_fi
el
ds and sanitized_http_headers anymore. The official
# document recommends using before_send instead.
#
# For more information, please visit:
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment