Open
Conversation
added 2 commits
January 17, 2022 23:38
If someone attempts to follow the Quickstart guide without realising that the HTML needs to be available as a resource the exception thrown (NullPointerException) is misleading. It should be a MissingResourceException.
tomoharu-fujita
added a commit
to Connecty/enlive
that referenced
this pull request
Jan 28, 2026
Major changes: - Fix all reflection warnings for modern JVM compatibility (cgrand#158, PR cgrand#152) - Update jsoup from 1.7.2 to 1.18.3 - Add missing HTML5 void elements: col, embed, keygen, param, source, track, wbr (cgrand#140) - JSoup parser now supports Reader input (enables html-snippet) (cgrand#90) - Improve error message for missing resources with MissingResourceException (cgrand#154, PR cgrand#155) - Migrate from Leiningen to tools.deps (deps.edn) - Replace Travis CI with GitHub Actions (Java 11/17/21 matrix) - Remove obsolete build.xml (Ant) See CHANGELOG.md for full details.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The Quickstart proved misleading (#154) and didn't adequately signal that the word resource meant a Java resource. It looks a lot like a file path.
This PR improves the exception thrown from
NullPointerExceptiontoMissingResourceExceptionand adds a hint to the error message with more context.it assumes that people are more likely to run into this failure mode when they follow the Quickstart int he README.