fix(profiles): use allowlist for default profile export, add symlinks=True - #58468
Closed
arc-butler wants to merge 1 commit into
Closed
fix(profiles): use allowlist for default profile export, add symlinks=True#58468arc-butler wants to merge 1 commit into
arc-butler wants to merge 1 commit into
Conversation
…=True - Replace _DEFAULT_EXPORT_EXCLUDE_ROOT (blocklist) with _DEFAULT_EXPORT_ALLOW_ROOT (allowlist) so only known profile artifacts are exported -- fixes crash when HERMES_HOME is the cwd (Docker) and contains unrelated files with broken symlinks - Add symlinks=True to shutil.copytree as a second line of defense against stale symlinks in the source tree - Closes NousResearch#58394
Collaborator
Duplicate of #58445 (the earlier, still-open twin). Both rewrite the default profile export to an allowlist ( |
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.
Summary
Fixes two issues with the default profile export:
Allowlist filtering:
DEFAULT_EXPORT_ALLOW_ROOTnow only includes known profile artifacts (skills, cron, scripts, sessions, plugins, memories, config.yaml, SOUL.md, contribute-tracker.json). Everything else is ignored.symlinks=True: Passed to
shutil.copytree()so stale symlinks are preserved as-is instead of raising an error during export.Changes
hermes_cli/profiles.py: Filter default export to an explicit allowlist; addsymlinks=Trueto copytree call.Co-authored-by: ARC arc345.assistant@gmail.com