Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

bug: E565: Not allowed to c hange text or change window #1434

Open
mvillafuertem opened this issue Feb 28, 2025 · 0 comments
Open

bug: E565: Not allowed to c hange text or change window #1434

mvillafuertem opened this issue Feb 28, 2025 · 0 comments
Labels
bug Something isn't working

Comments

@mvillafuertem
Copy link

mvillafuertem commented Feb 28, 2025

Describe the bug

Using Alpha as the start screen in Neovim. However, when I open Avante while still in Alpha and try to open another buffer, I encounter the following error.

Additionally, I'm not sure if this is related to the previous issue, but I'm experiencing the following issue as well. When Avante suggests code and I try to apply it by pressing <A>, nothing happens - the code suggested isn't being applied.

Error executing lua callback: ...e/.local/share/nvim/lazy/nui.nvim/lua/nui/split/init.lua:301: E565: Not allowed to c
hange text or change window
stack traceback:
        [C]: in function 'nvim_buf_delete'
        ...e/.local/share/nvim/lazy/nui.nvim/lua/nui/split/init.lua:301: in function '_buf_destroy'
        ...e/.local/share/nvim/lazy/nui.nvim/lua/nui/split/init.lua:321: in function 'unmount'
        ...local/share/nvim/lazy/avante.nvim/lua/avante/sidebar.lua:86: in function 'reset'
        ...local/share/nvim/lazy/avante.nvim/lua/avante/sidebar.lua:2955: in function <...local/share/nvim/lazy/avant
e.nvim/lua/avante/sidebar.lua:2954>

To reproduce

  1. Set Alpha as the start screen in Neovim
  2. Open Avante while Alpha is still active
  3. Try to open another buffer

Expected behavior

No response

Installation method

Use lazy.nvim:

{
  "yetone/avante.nvim",
  event = "VeryLazy",
  lazy = false,
  version = false, -- set this if you want to always pull the latest change
  opts = {
    -- add any opts here
  },
  -- if you want to build from source then do `make BUILD_FROM_SOURCE=true`
  build = "make",
  -- build = "powershell -ExecutionPolicy Bypass -File Build.ps1 -BuildFromSource false" -- for windows
  dependencies = {
    "nvim-treesitter/nvim-treesitter",
    "stevearc/dressing.nvim",
    "nvim-lua/plenary.nvim",
    "MunifTanjim/nui.nvim",
  },
}

Environment

nvim --version
NVIM v0.10.4
Build type: Release
LuaJIT 2.1.1713773202
Run "nvim -V1 -v" for more info

Repro

{
    "yetone/avante.nvim",
    event = "VeryLazy",
    lazy = false,
      version = false, -- Set this to "*" to always pull the latest release version, or set it to false to update to the latest code changes.
    opts = {
      provider = "copilot",
    },
    build = "make", -- This is optional, recommended tho. Also note that this will block the startup for a bit since we are compiling bindings in Rust.
    dependencies = {
      "nvim-treesitter/nvim-treesitter",
      "stevearc/dressing.nvim",
      "nvim-lua/plenary.nvim",
      "MunifTanjim/nui.nvim",
      --- The below dependencies are optional,
      "hrsh7th/nvim-cmp",
      "nvim-tree/nvim-web-devicons", -- or echasnovski/mini.icons
      "zbirenbaum/copilot.lua",    -- for providers='copilot'
      {
        -- support for image pasting
        "HakonHarnes/img-clip.nvim",
        event = "VeryLazy",
        opts = {
          -- recommended settings
          default = {
            embed_image_as_base64 = false,
            prompt_for_file_name = false,
            drag_and_drop = {
              insert_mode = true,
            },

            -- required for Windows users
            use_absolute_path = true,
          },
        },
      },
      {
        -- Make sure to setup it properly if you have lazy=true
        "MeanderingProgrammer/render-markdown.nvim",
        opts = {
          file_types = { "markdown", "Avante" },
        },
        ft = { "markdown", "Avante" },
      },
    },
  }
@mvillafuertem mvillafuertem added the bug Something isn't working label Feb 28, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant