Skip to content

Fix jsonschema.json ignore not taking effect given positional arguments#768

Merged
jviotti merged 2 commits into
mainfrom
extension-config-bug
Jun 4, 2026
Merged

Fix jsonschema.json ignore not taking effect given positional arguments#768
jviotti merged 2 commits into
mainfrom
extension-config-bug

Conversation

@jviotti

@jviotti jviotti commented Jun 4, 2026

Copy link
Copy Markdown
Member

Signed-off-by: Juan Cruz Viotti jv@jviotti.com

…uments

Signed-off-by: Juan Cruz Viotti <jv@jviotti.com>
@jviotti jviotti marked this pull request as ready for review June 4, 2026 15:15
@augmentcode

augmentcode Bot commented Jun 4, 2026

Copy link
Copy Markdown
🤖 Augment PR Summary

Summary: This PR fixes configuration-defined ignore/extension behavior not taking effect when inputs are provided as positional arguments.

Changes:

  • Teach for_each_json() to load a shared jsonschema.json configuration (when a single config is detected) and pass it into parse_extensions so directory traversal honors configured extensions.
  • Continue merging configuration-derived ignore paths for each discovered configuration file in positional-argument mode.
  • Add a new lint test to ensure a configured extension list filters directory scans correctly.
  • Update many existing tests’ verbose output expectations to include the now-emitted “Using extension: …” lines.

Technical Notes: Extension matching for directory recursion now becomes configuration-aware for positional inputs when the configuration file is unambiguous.

🤖 Was this summary useful? React with 👍 or 👎

@augmentcode augmentcode Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Review completed. 1 suggestion posted.

Fix All in Augment

Comment augment review to trigger a new review at any time.

Comment thread src/input.h Outdated
const auto extensions{parse_extensions(options, std::nullopt)};
std::optional<sourcemeta::blaze::Configuration> shared_configuration{
std::nullopt};
if (seen_configurations.size() == 1) {

@augmentcode augmentcode Bot Jun 4, 2026

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

When positional arguments resolve to multiple different jsonschema.json files, merge_configuration_ignore merges ignore rules from all of them but parse_extensions will fall back to std::nullopt (so per-directory configured extension filtering won’t apply for directory traversal). Is that behavior intended, or should extension configuration also be applied when multiple configurations are in play?

Severity: medium

Fix This in Augment

🤖 Was this useful? React with 👍 or 👎, or 🚀 if it prevented an incident/outage.

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

1 issue found across 28 files

Reply with feedback, questions, or to request a fix.

Re-trigger cubic

Comment thread src/input.h Outdated
Signed-off-by: Juan Cruz Viotti <jv@jviotti.com>
@jviotti jviotti merged commit f270679 into main Jun 4, 2026
15 checks passed
@jviotti jviotti deleted the extension-config-bug branch June 4, 2026 15:47
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.

1 participant