Repository navigation
Conversation
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Want reviews to match your repository better? Bugbot Learning can learn team-specific rules from PR activity. A team admin can enable Learning in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 158ead9. Configure here.
On Python 3.12, Path.is_file() raises PermissionError for a symlink into an unreadable directory, so one such file under references/ (or anywhere in the skill for the test-file check) aborted the whole scan. Python 3.14 already returns False there. Move the references loop's is_file() inside the existing OSError handling, and use a small _is_file() helper for the reference_files listing and the test-file auto-discovery walk. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

scan_skill.pyscanned only the.mdfiles directly underreferences/.Files in subfolders such as
references/guides/setup.mdnever got theprompt-injection, obfuscation, secret, or URL checks, and
structure.reference_filesleft them out too, so a skill could come backclean while most of its reference text was never read.
This walks
references/withrglob("*.md")and reports each file by itspath relative to
references/(references/guides/setup.md:3), in thefindings and in
structure.reference_files. Output is unchanged for skillswithout nested folders.
Path.rglobdoes not descend into directorysymlinks, so symlink loops and links to directories outside the skill are not
traversed. A file symlink under
references/is still read, even when itpoints outside the skill, which is what the scanner already does for top-level
reference files. The existing symlink check still reports every link.
Tested locally:
references/guides/nested.mdnow reports a critical finding at
references/guides/nested.md:3. Beforethe change it reported nothing for that file.
before and after.
files, mostly nested), the scan goes from 1 high finding to 1 critical and
64 high findings.
Fixes #186
Also skip unreadable paths (e.g. a symlink into a permission-denied directory) instead of aborting the scan on Python 3.12 (3.13 not tested), including the pre-existing test-file discovery walk.