Skip to content

feat(logs): add log4net integration - #5172

Merged
jamescrosswell merged 18 commits into
mainfrom
feat/logs-log4net
Jul 16, 2026
Merged

feat(logs): add log4net integration#5172
jamescrosswell merged 18 commits into
mainfrom
feat/logs-log4net

Update src/Sentry.Log4Net/SentryAppender.cs

4236d5f
Select commit
Loading
Failed to load commit list.
@sentry/warden / warden: find-bugs completed Jul 16, 2026 in 0s

1 issue

find-bugs: Found 1 issue (1 low)

Low

Potential NullReferenceException when loggingEvent.Level is null - `src/Sentry.Log4Net/LevelMapping.cs:38`

The >= comparison operators will throw a NullReferenceException if loggingEvent.Level is null, unlike the existing ToSentryLevel and ToBreadcrumbLevel methods that use null-safe == comparisons. Consider adding a null check: var level when level is null => null, as the first pattern.


⏱ 7m 39s · 1.8M in / 72.5k out · $4.60