fix(runner): align target archive detection#58
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 8832f97d3b
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
| return false; | ||
| } | ||
| String lower = name.toLowerCase(Locale.ROOT); | ||
| return lower.endsWith(".class") || lower.endsWith(".jar") || lower.endsWith(".zip"); |
There was a problem hiding this comment.
Honor archive-only folders before runner resolution
When the selected/resolved output folder contains only archives, such as a folder of JARs/ZIPs, the VS Code resolver returns NO_CLASS_TARGETS before this Java resolver runs: src/workspace/analysisTargetResolver.ts calls hasClassTargets, and src/workspace/outputResolver.ts only treats .class entries as evidence inside directories. As a result, the new recursive .zip target support is unreachable for archive-only folder/project analysis unless a loose class file is present alongside the archive.
Useful? React with 👍 / 👎.
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 1bdfa8503c
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
| for (const entry of entries) { | ||
| if (entry.isFile()) { | ||
| if (entry.name.toLowerCase().endsWith('.class')) { | ||
| if (isBytecodeTarget(entry.name)) { |
There was a problem hiding this comment.
Keep source-file resolution from accepting archive-only roots
When analyzing a .java file, this archive match now lets hasClassTargets(outputPath) succeed for an output directory that contains only a JAR/ZIP, so analysisTargetResolver returns an OK source-file target. The backend still receives the original .java path, and TargetResolver.addTargetsForJavaFile only looks for matching loose .class files by relative path or basename, never archives, so that path produces zero SpotBugs targets and a failed/no-response analysis instead of either analyzing the archive or reporting no class targets.
Useful? React with 👍 / 👎.
No description provided.