apache / apache/maven-enforcer

enforceBytecodeVersion: exclude is broken without include

Closed
#985 0 comments 0 reactions 0 assignees View on GitHub
bug
Dominant language
Java
Stars
161
Forks
180
Avg merge
1d 20m
Merged PRs (30d)
8

Description

### Affected version

3.6.3

### Bug description

The new rule is broken in respect of being "true drop in". If there are excludes but no includes, it totally messes up filtering.

Workaround: if you need exclude, you must set also include, at least for `*:*` (all).
Example: https://github.com/maveniverse/toolbox/pull/401/changes

Contributor guide

No contributing guide indexed for this repository

Research direction

Start at the enforceBytecodeVersion rule and reproduce filtering with excludes configured but no includes, then compare it with the documented *:* workaround and the linked pull request changes. Done means excludes work correctly without requiring an include pattern, with regression coverage for the no-include case.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
build-system
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.