Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,13 @@
# Changelog

## Unreleased

### Dependencies

- Bump Sentry SDK from v8.22.0 to v8.25.0 ([#198](https://github.com/getsentry/sentry-maven-plugin/pull/198))
- [changelog](https://github.com/getsentry/sentry-java/blob/main/CHANGELOG.md#8250)
- [diff](https://github.com/getsentry/sentry-java/compare/8.22.0...8.25.0)

## 0.9.0

### Dependencies
Expand Down
2 changes: 1 addition & 1 deletion src/main/resources/sentry-sdk.properties
Original file line number Diff line number Diff line change
@@ -1 +1 @@
sdk_version = 8.22.0
sdk_version = 8.25.0
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Bug: Missing sentry-sdk.properties causes NullPointerException during Maven build.
Severity: CRITICAL | Confidence: 0.95

🔍 Detailed Analysis

The SdkVersionInfo.getSentryVersion() method attempts to load /sentry-sdk.properties using SentryInstaller.class.getResourceAsStream(). If this file is missing, getResourceAsStream() returns null. Subsequently, sdkProperties.load(null) is called, which triggers an NullPointerException. This exception is not caught by the catch (IOException e) block, leading to an uncaught exception during the Maven build lifecycle. This prevents the Sentry auto-installation feature from functioning.

💡 Suggested Fix

Ensure src/main/resources/sentry-sdk.properties exists and contains sdk_version = 8.25.0. Verify the update script scripts/update-sentry-sdk.sh correctly generates and commits this file.

🤖 Prompt for AI Agent
Review the code at the location below. A potential bug has been identified by an AI
agent.
Verify if this is a real issue. If it is, propose a fix; if not, explain why it's not
valid.

Location: src/main/resources/sentry-sdk.properties#L1

Potential issue: The `SdkVersionInfo.getSentryVersion()` method attempts to load
`/sentry-sdk.properties` using `SentryInstaller.class.getResourceAsStream()`. If this
file is missing, `getResourceAsStream()` returns `null`. Subsequently,
`sdkProperties.load(null)` is called, which triggers an `NullPointerException`. This
exception is not caught by the `catch (IOException e)` block, leading to an uncaught
exception during the Maven build lifecycle. This prevents the Sentry auto-installation
feature from functioning.

Did we get this right? 👍 / 👎 to inform future reviews.