Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GH-85: Do not crash if source roots are missing #88

Merged
merged 2 commits into from
Feb 4, 2024

Conversation

ascopes
Copy link
Owner

@ascopes ascopes commented Feb 4, 2024

Fixes a bug where the plugin would crash if the directory for protobuf source roots did not exist.

The plugin will now emit a message saying that no sources are found, and then exit successfully.

This prevents build failures if the plugin is accidentally inherited from a parent POM into a project that lacks any source roots.

Fixes GH-85.

@ascopes ascopes added bug Something isn't working java labels Feb 4, 2024
@ascopes ascopes self-assigned this Feb 4, 2024
Copy link

codecov bot commented Feb 4, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Comparison is base (fbff0d0) 86.85% compared to head (ee236fe) 84.23%.
Report is 2 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main      #88      +/-   ##
==========================================
- Coverage   86.85%   84.23%   -2.61%     
==========================================
  Files          21       21              
  Lines         631      634       +3     
  Branches       54       55       +1     
==========================================
- Hits          548      534      -14     
- Misses         58       77      +19     
+ Partials       25       23       -2     
Files Coverage Δ
...rotobufmavenplugin/source/ProtoSourceResolver.java 76.79% <100.00%> (+1.32%) ⬆️

... and 4 files with indirect coverage changes

@ascopes ascopes force-pushed the bugfix/GH-85-empty-source-roots branch from ee236fe to 356605f Compare February 4, 2024 11:36
@ascopes ascopes merged commit a9dafc9 into main Feb 4, 2024
3 checks passed
@ascopes ascopes deleted the bugfix/GH-85-empty-source-roots branch February 4, 2024 11:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Non-existent source roots raise an unwanted IOException.
1 participant