Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

High CPU Usage - MacOS/Neovim #429

Closed
Labels
bugSomething isn't working
@wilkinson4

Description

@wilkinson4

Bug report

  • I confirm this is a bug with Supabase, not with my own application.
  • I confirm I have searched theDocs, GitHubDiscussions, andDiscord.

Describe the bug

Hello! I have recently been experimenting with postgres-language-server in my neovim config on neovim 0.11.1, and MacOS Sequoia 15.5. I am usingvim-dadbod-ui to manage my database connections and nvim-lsp to run the postgres-language-server when I am editing a sql buffer. I started noticing excessive battery drain on my 2023 Macbook Pro, and I realized thepostgres-tools process was consistently running at 100% CPU usage.

To Reproduce

  1. Setup vim dadbod and vim dadbod ui per the docs
  2. I have the following lsp lua config for postgres lsp:
localfunctionon_attach(client,bufnr)vim.api.nvim_buf_set_option(bufnr,'omnifunc','v:lua.vim.lsp.omnifunc')localfunctionbuf_keymap(mode,lhs,rhs)vim.keymap.set(mode,lhs,rhs, {buffer=true,silent=true })endifclient.name=='eslint'thenclient.server_capabilities.documentFormattingProvider=trueclient.server_capabilities.documentRangeFormattingProvider=trueendbuf_keymap('n','K',function()vim.lsp.buf.hover()end)buf_keymap('n','gd',function()vim.lsp.buf.definition()end)buf_keymap('n','1gd',function()vim.cmd('vsplit')vim.lsp.buf.definition()end)buf_keymap('n','<c-]>',function()vim.lsp.buf.declaration()end)buf_keymap('n','gD',function()vim.lsp.buf.implementation()end)buf_keymap('n','<c-k>',function()vim.lsp.buf.signature_help()end)buf_keymap('n','1gD',function()vim.lsp.buf.type_definition()end)buf_keymap('n','sr',function()vim.lsp.buf.references()end)buf_keymap('n','gW',function()vim.lsp.buf.workspace_symbol()end)buf_keymap('n','gA',function()vim.lsp.buf.code_action()end)buf_keymap('v','gA',function()vim.lsp.buf.range_code_action()end)buf_keymap('n','sd',function()vim.diagnostic.open_float()end)buf_keymap('n','<f4>',function()vim.lsp.buf.format({async=true,filter=function(client)returnclient.name~="typescript-tools"end })end)buf_keymap('v','<f4>',function()vim.lsp.buf.range_formatting({})end)buf_keymap('n','<f3>',function()vim.lsp.buf.rename()end)endlocalcapabilities=vim.lsp.protocol.make_client_capabilities()localservers= {'postgres_lsp'}localconfigs= {}for_,lspinipairs(servers)dolocalconfig=configs[lsp]or {}config.on_attach=on_attachconfig.capabilities=capabilitiesvim.lsp.config[lsp]=configvim.lsp.enable(lsp)end
  1. Add a database connection via vim-dadbod-ui and open a new sql buffer

System information

MacOS Sequoia 15.5, 2023 Macbook Pro, Neovim 11.1

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions


      [8]ページ先頭

      ©2009-2025 Movatter.jp