fix: guard volume file browser against non-mountable driver types#2364
Merged
kmendell merged 2 commits intogetarcaneapp:mainfrom Apr 13, 2026
Merged
Conversation
volumes created with type=none (or other custom driver options) can't be mounted inside a helper container — Docker fails with 'no such device'. check the volume options before spinning up the temp container and return a clear error instead of a confusing daemon message. fixes getarcaneapp#2359
Member
✅ Snyk checks have passed. No issues have been found so far.
💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse. |
review pointed out the guard only caught type=none but missed volumes configured with o=bind (no explicit type key). extend the check to cover both cases with a single strings.Contains on the o option.
kmendell
approved these changes
Apr 13, 2026
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.
What
Volumes created with
type=none(or other custom local driver options likeo=bind,device=...) cannot be mounted inside a helper container — Docker fails withfailed to mount local volume: no such device.Before this fix, the error bubbled up as a confusing daemon-level message. Now the volume options are checked upfront and a clear, user-friendly error is returned instead of trying to spin up a temp container that was never going to work.
Changes
isBrowsableVolumeInternalhelper involume_service.gothat inspects the volume's driver options before mountingListDirectory,GetFileContent,DownloadFileTesting
Create a volume with the advanced driver options
type=none,o=bind,device=/some/path. Navigate to the Browser tab — you'll now get a clear error instead of a daemon stacktrace.Fixes #2359
Disclaimer Greptiles Reviews use AI, make sure to check over its work.
To better help train Greptile on our codebase, if the comment is useful and valid Like the comment, if its not helpful or invalid Dislike
To have Greptile Re-Review the changes, mention
greptileai.Greptile Summary
This PR adds a
isBrowsableVolumeInternalguard that inspects a volume's driver options before spinning up a helper container, returning a user-friendly error fortype=nonevolumes that would otherwise produce a confusing daemon-level "no such device" failure. The guard is correctly wired into all three browsing entry points (ListDirectory,GetFileContent,DownloadFile) and follows the repo's naming and error-wrapping conventions.Confidence Score: 5/5
Safe to merge — the fix is targeted, correct for the reported bug, and all remaining feedback is P2.
No P0 or P1 findings. The nil-map access on
vol.Optionsis safe in Go. Error wrapping follows idiomatic patterns. The only suggestion is broadening the guard condition to cover additional bind-variant configurations, which is a non-blocking improvement.No files require special attention.
Prompt To Fix All With AI
Reviews (1): Last reviewed commit: "fix: guard volume browser against non-mo..." | Re-trigger Greptile