Skip to content

Commit f921ce8

Browse files
committed
chore(output_window): remove debugging code
1 parent def1d10 commit f921ce8

File tree

2 files changed

+1
-29
lines changed

2 files changed

+1
-29
lines changed

lua/opencode/ui/output_window.lua

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -69,10 +69,6 @@ function M.get_buf_line_count()
6969
return vim.api.nvim_buf_line_count(state.windows.output_buf)
7070
end
7171

72-
--- FIXME: remove debugging code
73-
M._lines_set = 0
74-
M._set_calls = 0
75-
7672
---Set the output buffer contents
7773
---@param lines string[] The lines to set
7874
---@param start_line? integer The starting line to set, defaults to 0
@@ -90,17 +86,7 @@ function M.set_lines(lines, start_line, end_line)
9086
return
9187
end
9288

93-
--- FIXME: remove debugging code
94-
if vim.tbl_isempty(lines) then
95-
M._lines_set = 0
96-
M._set_calls = 0
97-
else
98-
M._lines_set = M._lines_set + #lines
99-
M._set_calls = M._set_calls + 1
100-
end
101-
10289
vim.api.nvim_set_option_value('modifiable', true, { buf = windows.output_buf })
103-
-- vim.notify(vim.inspect(lines))
10490
vim.api.nvim_buf_set_lines(windows.output_buf, start_line, end_line, false, lines)
10591
vim.api.nvim_set_option_value('modifiable', false, { buf = windows.output_buf })
10692
end

tests/manual/renderer_replay.lua

Lines changed: 1 addition & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -354,21 +354,7 @@ function M.start(opts)
354354
or event.partID
355355
or event.messageID
356356
or ''
357-
vim.notify(
358-
'Event '
359-
.. index
360-
.. '/'
361-
.. count
362-
.. ': '
363-
.. type
364-
.. ' '
365-
.. id
366-
.. ' lines_set: '
367-
.. output_window._lines_set
368-
.. ' set_calls: '
369-
.. output_window._set_calls,
370-
vim.log.levels.INFO
371-
)
357+
vim.notify('Event ' .. index .. '/' .. count .. ': ' .. type .. ' ' .. id, vim.log.levels.INFO)
372358
end
373359

374360
state.event_manager:subscribe('session.updated', function(event)

0 commit comments

Comments
 (0)