Skip to content

Conversation

@garyschulte
Copy link
Contributor

PR description

native-image compilation builds and runtime fail when using BesuVersionUtils due to missing runtime metadata, like class, package and classpath causing NPE.

Rather than hacking graal apps, this PR makes the version utils fail/fallback gracefully.

Fixed Issue(s)

Thanks for sending a pull request! Have you done the following?

  • Checked out our contribution guidelines?
  • Considered documentation and added the doc-change-required label to this PR if updates are required.
  • Considered the changelog and included an update if required.
  • For database changes (e.g. KeyValueSegmentIdentifier) considered compatibility and performed forwards and backwards compatibility tests

Locally, you can run these tests to catch failures early:

  • spotless: ./gradlew spotlessApply
  • unit tests: ./gradlew build
  • acceptance tests: ./gradlew acceptanceTest
  • integration tests: ./gradlew integrationTest
  • reference tests: ./gradlew ethereum:referenceTests:referenceTests
  • hive tests: Engine or other RPCs modified?

Signed-off-by: garyschulte <garyschulte@gmail.com>
Signed-off-by: garyschulte <garyschulte@gmail.com>
Signed-off-by: garyschulte <garyschulte@gmail.com>
Copy link
Contributor

@macfarla macfarla left a comment

Choose a reason for hiding this comment

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

I guess null/null is better than NPE. idk what would be better defaults in that case.

@garyschulte garyschulte enabled auto-merge (squash) October 22, 2025 13:27
@garyschulte garyschulte merged commit 130ffc8 into hyperledger:main Oct 22, 2025
46 checks passed
@garyschulte garyschulte deleted the bugfix/graal-safe-version-utils branch October 22, 2025 14:01
jflo pushed a commit to jflo/besu that referenced this pull request Nov 17, 2025
* make BesuVersionUtils graal-safe

Signed-off-by: garyschulte <garyschulte@gmail.com>
pinges pushed a commit to pinges/besu that referenced this pull request Dec 15, 2025
* make BesuVersionUtils graal-safe

Signed-off-by: garyschulte <garyschulte@gmail.com>
Signed-off-by: stefan.pingel@consensys.net <stefan.pingel@consensys.net>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants