Spun off from PR #2807 (Reviewer A round-3 non-blocking nit).
Problem
In `cli/lucli/Module.cfc::runUpgradeCheck()`, the advisory-1 suppression guard reads only `config/settings.cfm`:
```cfm
var settingsFile = variables.projectRoot & "/config/settings.cfm";
if (fileExists(settingsFile)) {
underscoreFlagAlreadySet = reFindNoCase(
"useUnderscoreReferenceColumns\s*=\s*true",
stripCfmlComments(fileRead(settingsFile))
) > 0;
}
```
But advisory #2 scans all of `config/` for the same pattern:
```cfm
arrayAppend(checks, {
description: "useUnderscoreReferenceColumns=true is set — confirm legacy migrations don't conflict",
severity: "advisory",
pattern: "useUnderscoreReferenceColumns\s*=\s*true",
scanDir: "config",
extensions: "cfm,cfc",
...
});
```
Impact
If a user sets the flag in an environment-specific override file (e.g., `config/production/settings.cfm`, `config/development/settings.cfm`), the pre-check on the root `settings.cfm` will return false, advisory #1 will fire ("opt into the flag!"), AND advisory #2 will also fire ("the flag is set!"). Same contradiction the round-1 fix was trying to prevent.
Low impact because:
- Per-environment flag overrides for this setting are unusual
- Both advisories are `severity: "advisory"` — they never gate CI
Suggested fix
Expand the pre-check to scan all of `config/` recursively (matching advisory #2's scope), not just the root `settings.cfm`. Existing helper pattern at `Module.cfc:3995` (the grep loop) shows how to do recursive scanning.
Alternatively: simplify by letting the bucketing handle the contradiction — e.g., if advisory #2 fires, suppress advisory #1 even if its guard didn't catch the flag.
Good first issue for someone wanting to touch the CLI without a deep dive.
Spun off from PR #2807 (Reviewer A round-3 non-blocking nit).
Problem
In `cli/lucli/Module.cfc::runUpgradeCheck()`, the advisory-1 suppression guard reads only `config/settings.cfm`:
```cfm
var settingsFile = variables.projectRoot & "/config/settings.cfm";
if (fileExists(settingsFile)) {
underscoreFlagAlreadySet = reFindNoCase(
"useUnderscoreReferenceColumns\s*=\s*true",
stripCfmlComments(fileRead(settingsFile))
) > 0;
}
```
But advisory #2 scans all of `config/` for the same pattern:
```cfm
arrayAppend(checks, {
description: "useUnderscoreReferenceColumns=true is set — confirm legacy migrations don't conflict",
severity: "advisory",
pattern: "useUnderscoreReferenceColumns\s*=\s*true",
scanDir: "config",
extensions: "cfm,cfc",
...
});
```
Impact
If a user sets the flag in an environment-specific override file (e.g., `config/production/settings.cfm`, `config/development/settings.cfm`), the pre-check on the root `settings.cfm` will return false, advisory #1 will fire ("opt into the flag!"), AND advisory #2 will also fire ("the flag is set!"). Same contradiction the round-1 fix was trying to prevent.
Low impact because:
Suggested fix
Expand the pre-check to scan all of `config/` recursively (matching advisory #2's scope), not just the root `settings.cfm`. Existing helper pattern at `Module.cfc:3995` (the grep loop) shows how to do recursive scanning.
Alternatively: simplify by letting the bucketing handle the contradiction — e.g., if advisory #2 fires, suppress advisory #1 even if its guard didn't catch the flag.
Good first issue for someone wanting to touch the CLI without a deep dive.