-
Notifications
You must be signed in to change notification settings - Fork 1
Open
Description
Problem
The Config.Validate() method always returns nil, making it a no-op.
Evidence
config.go:150-157
func (c *Config) Validate() error {
if _, err := os.Stat(c.ProjectsDir); os.IsNotExist(err) {
return nil // Not an error - returns nil even when dir doesn't exist
}
return nil // Always nil
}The method is named Validate but doesn't validate anything - it always returns nil regardless of input.
Impact
- Misleading API - callers expect validation to occur
- Future maintainers might add calls to
Validate()expecting it to work - Defensive programming relies on validation actually validating
Suggested Fix
Either:
- Make it validate something useful, such as:
- Check if
ClaudeBinexists and is executable - Verify
DBPathparent directory is writable - Validate
Backendis a known value
- Check if
- Remove the method entirely if validation isn't needed
Files: internal/config/config.go:150-157
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels