fix: symlink telegram state into openclaw-data#981
fix: symlink telegram state into openclaw-data#981WuKongAI-CMU wants to merge 2 commits intoNVIDIA:mainfrom
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
✅ Files skipped from review due to trivial changes (1)
🚧 Files skipped from review as they are similar to previous changes (1)
📝 WalkthroughWalkthroughThe Dockerfile now prepares a writable Telegram state directory at Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@Dockerfile`:
- Around line 137-139: The current RUN step uses ln -sfn
/sandbox/.openclaw-data/telegram /sandbox/.openclaw/telegram which will place a
symlink inside /sandbox/.openclaw/telegram if that path is an existing
directory; before creating the symlink remove or replace the destination
directory to ensure it is replaced atomically. Modify the RUN sequence around
mkdir/chown and the ln invocation to explicitly remove the existing target
(e.g., rm -rf or rmdir as appropriate) for /sandbox/.openclaw/telegram before
calling ln -sfn so the symlink reliably replaces any prior directory or file.
In `@test/dockerfile-telegram-state.test.js`:
- Around line 17-19: The test currently only checks DOCKERFILE includes the
symlink string "ln -sfn /sandbox/.openclaw-data/telegram
/sandbox/.openclaw/telegram" but not that it appears before the locking step;
update the test to assert ordering by finding the index of that symlink string
in DOCKERFILE and the index of the lock command used in the Dockerfile (e.g.,
the locking token you use elsewhere such as "flock /sandbox/.openclaw.lock" or
the exact lock command present) and expect symlinkIndex < lockIndex so the
symlink line occurs before the lock line.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: 31692211-b723-4917-9fe0-77a1104e7df8
📒 Files selected for processing (2)
Dockerfiletest/dockerfile-telegram-state.test.js
|
Addressing the two CodeRabbit comments in b292eae:
@coderabbitai review |
|
✅ Actions performedReview triggered.
|
Summary
/sandbox/.openclaw-data/telegram/sandbox/.openclaw/telegraminto.openclaw-databefore locking.openclawFixes #975.
Summary by CodeRabbit
Tests
Chores