You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
internal/config imports internal/tui/styles - upward dependency violation. The config package (foundational infrastructure layer) depends on the tui/styles package (presentation layer) because Config.Schemes uses styles.ColorScheme. Lower-layer packages must not import from higher UI layers. The ColorScheme type should be defined in config or a shared types package, with tui/styles importing it from there.
internal/copilot (external API client) imports internal/data (local data store) - cross-layer coupling. The copilot Client struct holds a *data.Store reference and tool handlers in tools.go query the session store directly. This makes the API client layer tightly coupled to the local database layer; a service/mediator above both packages should own that coordination.
Application version (tui.Version) is defined in internal/tui and set via ldflags on that package. Version is application metadata, not a TUI concern - it should live in a dedicated internal/version package or cmd/dispatch, not embedded in the presentation layer. Currently cmd/dispatch, magefile.go, and .goreleaser.yml all reference the version through the TUI package path.
architecture review
internal/configimportsinternal/tui/styles- upward dependency violation. The config package (foundational infrastructure layer) depends on the tui/styles package (presentation layer) becauseConfig.Schemesusesstyles.ColorScheme. Lower-layer packages must not import from higher UI layers. TheColorSchemetype should be defined inconfigor a shared types package, withtui/stylesimporting it from there.internal/copilot(external API client) importsinternal/data(local data store) - cross-layer coupling. The copilot Client struct holds a*data.Storereference and tool handlers intools.goquery the session store directly. This makes the API client layer tightly coupled to the local database layer; a service/mediator above both packages should own that coordination.tui.Version) is defined ininternal/tuiand set via ldflags on that package. Version is application metadata, not a TUI concern - it should live in a dedicatedinternal/versionpackage orcmd/dispatch, not embedded in the presentation layer. Currentlycmd/dispatch,magefile.go, and.goreleaser.ymlall reference the version through the TUI package path.Automated analysis - 3 finding(s)