Skip to content

testing a fix for the scramble of the path opens - #881

Closed
entlein wants to merge 1 commit into
kubescape:mainfrom
k8sstormcenter:fix/openspathprefix
Closed

entlein wants to merge 1 commit into
kubescape:mainfrom
k8sstormcenter:fix/openspathprefix

Conversation

@entlein

@entlein entlein commented Aug 4, 2026

Copy link
Copy Markdown
Contributor

Looks like it could be as simple as this, currently testing for various side effects as tag= sbob-rc5s-osp -> Edit: its only half the rent, there is more to the story. This current patch does help, but I havnt had time to check where those scrambled lookups were introduced.
More info can be found here:
k8sstormcenter/bob#183

Summary by CodeRabbit

  • Bug Fixes

    • Improved path handling when full paths are unresolved or contain stale relative fragments.
    • Prevented invalid path fragments from being treated as valid absolute paths.
    • Added fallback behavior to use the available filename when a resolved full path is unavailable.
  • Tests

    • Added coverage for relative, absolute, root, and process-related path formats.

Signed-off-by: entlein <einentlein@gmail.com>
@coderabbitai

coderabbitai Bot commented Aug 4, 2026

Copy link
Copy Markdown

Review Change Stack

📝 Walkthrough

Walkthrough

Changes

Resolved full-path handling

Layer / File(s) Summary
Resolved path validation
pkg/utils/path.go, pkg/utils/resolved_full_path_test.go
Adds IsResolvedFullPath and tests absolute, relative, root, proc, empty, and stale fragment values.
GetFullPath fallback
pkg/utils/datasource_event.go
Uses IsResolvedFullPath before normalization and falls back to fname for unresolved values.

Estimated code review effort: 2 (Simple) | ~10 minutes

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly describes testing a fix for path-open scrambling, which matches the pull request objectives and main changes.
✨ Finishing Touches 💡 1
🛠️ Fix failing CI checks 💡
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@entlein

entlein commented Aug 12, 2026

Copy link
Copy Markdown
Contributor Author

Closing in favor of #889

@entlein entlein closed this Aug 12, 2026
@matthyx matthyx moved this from WIP to To Archive in KS PRs tracking Aug 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

2 participants