Skip to content

fix: include config file path in missing config error#821

Merged
ryanfowler merged 1 commit into
mainfrom
fix-config-file-error-context
Jul 2, 2026
Merged

fix: include config file path in missing config error#821
ryanfowler merged 1 commit into
mainfrom
fix-config-file-error-context

Conversation

@ryanfowler

Copy link
Copy Markdown
Owner

When --config /nonexistent/path was specified, the error was a bare OS error with no file context:

error: No such file or directory (os error 2)

Now the error includes which config file was not found, matching the pattern used by other file-path errors like --proto-file:

error: config file '/nonexistent/config.ini': No such file or directory (os error 2)

Validation: The change is a 1-line addition in get_config_file — wraps the std::fs::read_to_string error with a FetchError::Message including the file path.

Previously, --config /nonexistent/path produced a bare OS error with no
context. Now the error shows which config file was missing.
@ryanfowler ryanfowler force-pushed the fix-config-file-error-context branch from d607ee2 to d555985 Compare July 2, 2026 00:24
@ryanfowler ryanfowler enabled auto-merge July 2, 2026 00:27
@ryanfowler ryanfowler merged commit de5de6d into main Jul 2, 2026
4 checks passed
@ryanfowler ryanfowler deleted the fix-config-file-error-context branch July 2, 2026 00:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant