Repository navigation
[TUI] Wiring tui traffic watch - #232
Conversation
|
Gitar analyzes/fixes CI failures, runs prompts as workflows and addresses comments starting with ⚙️ Options:
|
| tw.checkForNewContent() | ||
| case <-tw.resumeCh: | ||
| // Manual resume signal - check immediately | ||
| tw.checkForNewContent() |
There was a problem hiding this comment.
I would lift the calls to checkForNewContent out of the select{} for better initial reactivity.
There was a problem hiding this comment.
But here the call is to be able to resume or get new data if any of those channels trigger
|
Some issues I found:
|
|
Wiring overall looks reasonable to me. There are some minor issues I see on presentation such as
I think the models directory needs an overhaul. I can take that in a stacked PR. But overall this looks good to me to work on top of in terms of wiring and code layout. So, IMO, feel free to merge to the traffic-tui branch. |
* add traffic inspect command (#225) * add traffic inspect command * add support for wait and reword messages * fix pr comments * Skeleton TUI (#226) * skeleton tui * fix escape logs * only update if have too * make sure by default nothing is selected * move between panes and tabs with arrow * fix wrong re-render caused by map * use utility for setting up status * update mock to contain routing key * fix help menu and clear status * center empty states * add viewport for right panel * make sure right pane occupy more width * add basic paginator for left pane * make sure left pane scroll move between pages * make short help aware of context * [TUI] Wiring tui traffic watch (#232) * skeleton tui * fix escape logs * only update if have too * make sure by default nothing is selected * move between panes and tabs with arrow * fix wrong re-render caused by map * use utility for setting up status * update mock to contain routing key * fix help menu and clear status * center empty states * add viewport for right panel * make sure right pane occupy more width * add basic paginator for left pane * make sure left pane scroll move between pages * make short help aware of context * remove model mock files * add lipgloss dependency * add simple watcher and use libconnect type: * replace bufferred channel with non * replace round with ceiling * fix build * load absolute meta, request and response * rename symbol * rename symbol * pass record dir and meta format * fix build * fix yaml support * add tui call from the inspect * add tui flag in record * make sure inspect look for json * remove hardcoded path * rename tui flag to inspect * remove tui cmd * remove models directory and move loader to utils (#234) * use pointers for http.{Request,Response} * make sure width is valid for logs * disable logs temporarily * add basic error handling for filemanager (#236) * add basic error handling for filemanager * make sure error message is displayed * remove sprintf from status render * pass pointer instead of copy on linemessages * make union type for scanner
* add traffic inspect command (#225) * add traffic inspect command * add support for wait and reword messages * fix pr comments * Skeleton TUI (#226) * skeleton tui * fix escape logs * only update if have too * make sure by default nothing is selected * move between panes and tabs with arrow * fix wrong re-render caused by map * use utility for setting up status * update mock to contain routing key * fix help menu and clear status * center empty states * add viewport for right panel * make sure right pane occupy more width * add basic paginator for left pane * make sure left pane scroll move between pages * make short help aware of context * [TUI] Wiring tui traffic watch (#232) * skeleton tui * fix escape logs * only update if have too * make sure by default nothing is selected * move between panes and tabs with arrow * fix wrong re-render caused by map * use utility for setting up status * update mock to contain routing key * fix help menu and clear status * center empty states * add viewport for right panel * make sure right pane occupy more width * add basic paginator for left pane * make sure left pane scroll move between pages * make short help aware of context * remove model mock files * add lipgloss dependency * add simple watcher and use libconnect type: * replace bufferred channel with non * replace round with ceiling * fix build * load absolute meta, request and response * rename symbol * rename symbol * pass record dir and meta format * fix build * fix yaml support * add tui call from the inspect * add tui flag in record * make sure inspect look for json * remove hardcoded path * rename tui flag to inspect * remove tui cmd * remove models directory and move loader to utils (#234) * use pointers for http.{Request,Response} * make sure width is valid for logs * disable logs temporarily * add logs viewer * fix regression and make sure logs render ok
* add traffic inspect command (#225) * add traffic inspect command * add support for wait and reword messages * fix pr comments * Skeleton TUI (#226) * skeleton tui * fix escape logs * only update if have too * make sure by default nothing is selected * move between panes and tabs with arrow * fix wrong re-render caused by map * use utility for setting up status * update mock to contain routing key * fix help menu and clear status * center empty states * add viewport for right panel * make sure right pane occupy more width * add basic paginator for left pane * make sure left pane scroll move between pages * make short help aware of context * [TUI] Wiring tui traffic watch (#232) * skeleton tui * fix escape logs * only update if have too * make sure by default nothing is selected * move between panes and tabs with arrow * fix wrong re-render caused by map * use utility for setting up status * update mock to contain routing key * fix help menu and clear status * center empty states * add viewport for right panel * make sure right pane occupy more width * add basic paginator for left pane * make sure left pane scroll move between pages * make short help aware of context * remove model mock files * add lipgloss dependency * add simple watcher and use libconnect type: * replace bufferred channel with non * replace round with ceiling * fix build * load absolute meta, request and response * rename symbol * rename symbol * pass record dir and meta format * fix build * fix yaml support * add tui call from the inspect * add tui flag in record * make sure inspect look for json * remove hardcoded path * rename tui flag to inspect * remove tui cmd * remove models directory and move loader to utils (#234) * use pointers for http.{Request,Response} * make sure width is valid for logs * disable logs temporarily * add logs viewer * fix regression and make sure logs render ok * stay on logs on incoming * clear logs logic and add some coloring * add cosmetic visual for rendering * make sure render properly * constraint width for requests
This is a stack PR #226