claude-code - 💡(How to fix) Fix [Bug] System prompts and persona constraints not being applied during session [1 participants]

Official PRs (…)
ON THIS PAGE

Recommended Tools

×6

Utilities matched from this issue’s tags and category — try them while you read without losing context.

GitHub issue graph ai analysis

Paste a GitHub issue URL. We fetch that issue, discover linked issues from bodies/comments/timeline, collect linked pull requests, and produce a structured English report.

The report is written in English Markdown for sharing and archival.

Helpful · Quick feedback

Loading…
GitHub stats
anthropics/claude-code#47078Fetched 2026-04-13 05:42:05
View on GitHub
Comments
0
Participants
1
Timeline
4
Reactions
0
Participants
Timeline (top)
labeled ×4

Error Message

[{"error":"Error: EISDIR: illegal operation on a directory, read 'C:\Users\Admin\OneDrive\Obsidian\Daily Vault\Chief of Staff\Session Logs'\n at L4H (B:/~BUN/root/src/entrypoints/cli.js:3993:15399)\n at processTicksAndRejections (native:7:39)","timestamp":"2026-04-12T16:33:25.357Z"},{"error":"Error: ENOENT: no such file or directory, unlink 'C:\Users\Admin\AppData\Local\Temp\claude\C--Users-Admin-OneDrive-Obsidian-Daily-Vault\2b169b45-f6c6-4157-9e05-b275882e8dc7\tasks\a114c308ed5f6aff0.output'\n at async <anonymous> (B:/~BUN/root/src/entrypoints/cli.js:7823:299)","timestamp":"2026-04-12T17:22:53.545Z"},{"error":"Error: File does not exist. Note: your current working directory is C:\Users\Admin\OneDrive\Obsidian\Daily Vault.\n at call (B:/~BUN/root/src/entrypoints/cli.js:4509:7632)\n at processTicksAndRejections (native:7:39)","timestamp":"2026-04-12T17:26:18.453Z"},{"error":"MaxFileReadTokenExceededError: File content (18292 tokens) exceeds maximum allowed tokens (10000). Use offset and limit parameters to read specific portions of the file, or search for specific content instead of reading the whole file.\n at KO_ (B:/~BUN/root/src/entrypoints/cli.js:4500:12874)\n at processTicksAndRejections (native:7:39)","timestamp":"2026-04-12T17:26:58.317Z"},{"error":"Error: ENOENT: no such file or directory, unlink 'C:\Users\Admin\AppData\Local\Temp\claude\C--Users-Admin-OneDrive-Obsidian-Daily-Vault\2b169b45-f6c6-4157-9e05-b275882e8dc7\tasks\a385b75565d423db9.output'\n at async <anonymous> (B:/~BUN/root/src/entrypoints/cli.js:7823:299)","timestamp":"2026-04-12T17:33:45.330Z"}]

Code Example

[{"error":"Error: EISDIR: illegal operation on a directory, read 'C:\\Users\\Admin\\OneDrive\\Obsidian\\Daily Vault\\Chief of Staff\\Session Logs'\n    at L4H (B:/~BUN/root/src/entrypoints/cli.js:3993:15399)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-12T16:33:25.357Z"},{"error":"Error: ENOENT: no such file or directory, unlink 'C:\\Users\\Admin\\AppData\\Local\\Temp\\claude\\C--Users-Admin-OneDrive-Obsidian-Daily-Vault\\2b169b45-f6c6-4157-9e05-b275882e8dc7\\tasks\\a114c308ed5f6aff0.output'\n    at async <anonymous> (B:/~BUN/root/src/entrypoints/cli.js:7823:299)","timestamp":"2026-04-12T17:22:53.545Z"},{"error":"Error: File does not exist. Note: your current working directory is C:\\Users\\Admin\\OneDrive\\Obsidian\\Daily Vault.\n    at call (B:/~BUN/root/src/entrypoints/cli.js:4509:7632)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-12T17:26:18.453Z"},{"error":"MaxFileReadTokenExceededError: File content (18292 tokens) exceeds maximum allowed tokens (10000). Use offset and limit parameters to read specific portions of the file, or search for specific content instead of reading the whole file.\n    at KO_ (B:/~BUN/root/src/entrypoints/cli.js:4500:12874)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-12T17:26:58.317Z"},{"error":"Error: ENOENT: no such file or directory, unlink 'C:\\Users\\Admin\\AppData\\Local\\Temp\\claude\\C--Users-Admin-OneDrive-Obsidian-Daily-Vault\\2b169b45-f6c6-4157-9e05-b275882e8dc7\\tasks\\a385b75565d423db9.output'\n    at async <anonymous> (B:/~BUN/root/src/entrypoints/cli.js:7823:299)","timestamp":"2026-04-12T17:33:45.330Z"}]
RAW_BUFFERClick to expand / collapse

Bug Description Claude is not following any persona, rules, gates hooks - nothing this entire session

Environment Info

  • Platform: win32
  • Terminal: mingw64
  • Version: 2.1.101
  • Feedback ID: f17f6bf7-34df-4508-b0e0-d975e0dbbb36

Errors

[{"error":"Error: EISDIR: illegal operation on a directory, read 'C:\\Users\\Admin\\OneDrive\\Obsidian\\Daily Vault\\Chief of Staff\\Session Logs'\n    at L4H (B:/~BUN/root/src/entrypoints/cli.js:3993:15399)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-12T16:33:25.357Z"},{"error":"Error: ENOENT: no such file or directory, unlink 'C:\\Users\\Admin\\AppData\\Local\\Temp\\claude\\C--Users-Admin-OneDrive-Obsidian-Daily-Vault\\2b169b45-f6c6-4157-9e05-b275882e8dc7\\tasks\\a114c308ed5f6aff0.output'\n    at async <anonymous> (B:/~BUN/root/src/entrypoints/cli.js:7823:299)","timestamp":"2026-04-12T17:22:53.545Z"},{"error":"Error: File does not exist. Note: your current working directory is C:\\Users\\Admin\\OneDrive\\Obsidian\\Daily Vault.\n    at call (B:/~BUN/root/src/entrypoints/cli.js:4509:7632)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-12T17:26:18.453Z"},{"error":"MaxFileReadTokenExceededError: File content (18292 tokens) exceeds maximum allowed tokens (10000). Use offset and limit parameters to read specific portions of the file, or search for specific content instead of reading the whole file.\n    at KO_ (B:/~BUN/root/src/entrypoints/cli.js:4500:12874)\n    at processTicksAndRejections (native:7:39)","timestamp":"2026-04-12T17:26:58.317Z"},{"error":"Error: ENOENT: no such file or directory, unlink 'C:\\Users\\Admin\\AppData\\Local\\Temp\\claude\\C--Users-Admin-OneDrive-Obsidian-Daily-Vault\\2b169b45-f6c6-4157-9e05-b275882e8dc7\\tasks\\a385b75565d423db9.output'\n    at async <anonymous> (B:/~BUN/root/src/entrypoints/cli.js:7823:299)","timestamp":"2026-04-12T17:33:45.330Z"}]

extent analysis

TL;DR

Check file paths and permissions to resolve directory and file access errors.

Guidance

  • Verify that the application has the necessary permissions to read and write files in the specified directories, such as C:\\Users\\Admin\\OneDrive\\Obsidian\\Daily Vault\\Chief of Staff\\Session Logs.
  • Check that the file paths are correct and the files exist, as errors indicate issues with file access, such as ENOENT: no such file or directory.
  • Consider using the offset and limit parameters to read specific portions of large files, as the MaxFileReadTokenExceededError suggests that the file content exceeds the maximum allowed tokens.
  • Review the current working directory and ensure it is set correctly, as some errors reference the current working directory.

Example

No specific code example is provided, as the issue seems to be related to file system access and permissions rather than code syntax.

Notes

The errors suggest issues with file system access, permissions, and large file handling. Resolving these issues may require adjustments to the application's configuration, file system permissions, or handling of large files.

Recommendation

Apply workaround: Adjust file paths, permissions, and large file handling to resolve the errors, as the issue seems to be related to environment and configuration rather than a version-specific bug.

Vote matrix · Quick signals

Works
Did the solution work? Tap to confirm.
Easy Fix
Was it a quick fix?
Time Saver
Did it save you time?
Blocking
Was it severely blocking?
Common Issue
Are others likely hitting this too?
Flaky / Intermittent
Is it intermittent?
Verified / Reproducible
Can you reproduce it reliably?
Loading…

Still need to ship something?

×6

Another batch ranked right after the header list — different links, same matching logic.

Back to top recommendations

TRENDING

claude-code - 💡(How to fix) Fix [Bug] System prompts and persona constraints not being applied during session [1 participants]