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

using in Windows system get error "cannot load module 'libsqlite3'" #63

Closed
Liampor opened this issue Jul 26, 2022 · 13 comments
Closed

using in Windows system get error "cannot load module 'libsqlite3'" #63

Liampor opened this issue Jul 26, 2022 · 13 comments

Comments

@Liampor
Copy link

Liampor commented Jul 26, 2022

Hello

I am using neovim 0.7.2 in Windows 10, sqlite installed via scoop

Installed via

use {
  "nvim-telescope/telescope-frecency.nvim",
  config = function()
    require"telescope".load_extension("frecency")
  end,
  requires = {"tami5/sqlite.lua"}
}

But when I run, I always got

E5108: Error executing lua ...ta\site\pack\packer\start\sqlite.lua/lua/sqlite/defs.lua:31: cannot load module 'libsqlite3': <d5>Ҳ<bb><b5><bd><b6><a8><b5><c4>ģ<bf>顣

stack traceback:

        [builtin#203]: at 0x7ff9657a6340
        ...ta\site\pack\packer\start\sqlite.lua/lua/sqlite/defs.lua:31: in main chunk
        [C]: in function 'require'
        ...a\site\pack\packer\start\sqlite.lua/lua/sqlite/utils.lua:252: in function '__index'
        ...data\site\pack\packer\start\sqlite.lua/lua/sqlite/db.lua:662: in main chunk
        [C]: in function 'require'
        ...ta\site\pack\packer\start\sqlite.lua/lua/sqlite/init.lua:66: in function '__index'
        ....nvim/lua/telescope/_extensions/frecency/sql_wrapper.lua:46: in function 'bootstrap'
        ...cy.nvim/lua/telescope/_extensions/frecency/db_client.lua:92: in function 'init'
        ...ope-frecency.nvim/lua/telescope/_extensions/frecency.lua:285: in function 'setup'
        ...\start\telescope.nvim/lua/telescope/_extensions/init.lua:20: in function '__index'
        [string ":lua"]:1: in main chunk

How can I fix this ?

@Liampor
Copy link
Author

Liampor commented Jul 26, 2022

Ah okay found a solution

  1. replace the tami5/sqlite.lua with kkharji/sqlite.lua
  2. follow the instruction in kkhariji/sqlite, Download sqlite3 precompiled and set let g:sqlite_clib_path = path/to/sqlite3.dll (note: /)

for me I put vim.g.sqlite_clib_path = "C:\\xxxxxx\\sqlite3\\sqlite3.dll" in my user init.lua file

@WendaoLee
Copy link

Ah okay found a solution

  1. replace the tami5/sqlite.lua with kkharji/sqlite.lua
  2. follow the instruction in kkhariji/sqlite, Download sqlite3 precompiled and set let g:sqlite_clib_path = path/to/sqlite3.dll (note: /)

for me I put vim.g.sqlite_clib_path = "C:\\xxxxxx\\sqlite3\\sqlite3.dll" in my user init.lua file

It also works for me.Thanks a lot!😘

@NerdyBoyCool
Copy link

I have encountered similar cases.
I am using an M2 MacbookAir and was getting an error trying to read the files under /opt/homebrew in sqlite.

So I used homebrew and did the following, which solved the problem.

$ which sqlite3
/usr/bin/sqlite3

$ brew install sqlite
$ echo 'export PATH="/opt/homebrew/opt/sqlite/bin:$PATH"' >> ~/.zshrc
$ source ~/.zshrc
$ brew link sqlite3 --force
$ which sqlite3
/opt/homebrew/opt/sqlite/bin/sqlite3

@IceShuttle
Copy link

Hello

I am using neovim 0.7.2 in Windows 10, sqlite installed via scoop

Installed via

use {
  "nvim-telescope/telescope-frecency.nvim",
  config = function()
    require"telescope".load_extension("frecency")
  end,
  requires = {"tami5/sqlite.lua"}
}

But when I run, I always got

E5108: Error executing lua ...ta\site\pack\packer\start\sqlite.lua/lua/sqlite/defs.lua:31: cannot load module 'libsqlite3': <d5>Ҳ<bb><b5><bd><b6><a8><b5><c4>ģ<bf>顣

stack traceback:

        [builtin#203]: at 0x7ff9657a6340
        ...ta\site\pack\packer\start\sqlite.lua/lua/sqlite/defs.lua:31: in main chunk
        [C]: in function 'require'
        ...a\site\pack\packer\start\sqlite.lua/lua/sqlite/utils.lua:252: in function '__index'
        ...data\site\pack\packer\start\sqlite.lua/lua/sqlite/db.lua:662: in main chunk
        [C]: in function 'require'
        ...ta\site\pack\packer\start\sqlite.lua/lua/sqlite/init.lua:66: in function '__index'
        ....nvim/lua/telescope/_extensions/frecency/sql_wrapper.lua:46: in function 'bootstrap'
        ...cy.nvim/lua/telescope/_extensions/frecency/db_client.lua:92: in function 'init'
        ...ope-frecency.nvim/lua/telescope/_extensions/frecency.lua:285: in function 'setup'
        ...\start\telescope.nvim/lua/telescope/_extensions/init.lua:20: in function '__index'
        [string ":lua"]:1: in main chunk

How can I fix this ?

The Exact same error happened to me also. I am on Ubuntu 22.04 LTS ,neovim installed through nix

@WendaoLee
Copy link

Hello

I am using neovim 0.7.2 in Windows 10, sqlite installed via scoop

Installed via

use {
  "nvim-telescope/telescope-frecency.nvim",
  config = function()
    require"telescope".load_extension("frecency")
  end,
  requires = {"tami5/sqlite.lua"}
}

But when I run, I always got

E5108: Error executing lua ...ta\site\pack\packer\start\sqlite.lua/lua/sqlite/defs.lua:31: cannot load module 'libsqlite3': <d5>Ҳ<bb><b5><bd><b6><a8><b5><c4>ģ<bf>顣

stack traceback:

        [builtin#203]: at 0x7ff9657a6340
        ...ta\site\pack\packer\start\sqlite.lua/lua/sqlite/defs.lua:31: in main chunk
        [C]: in function 'require'
        ...a\site\pack\packer\start\sqlite.lua/lua/sqlite/utils.lua:252: in function '__index'
        ...data\site\pack\packer\start\sqlite.lua/lua/sqlite/db.lua:662: in main chunk
        [C]: in function 'require'
        ...ta\site\pack\packer\start\sqlite.lua/lua/sqlite/init.lua:66: in function '__index'
        ....nvim/lua/telescope/_extensions/frecency/sql_wrapper.lua:46: in function 'bootstrap'
        ...cy.nvim/lua/telescope/_extensions/frecency/db_client.lua:92: in function 'init'
        ...ope-frecency.nvim/lua/telescope/_extensions/frecency.lua:285: in function 'setup'
        ...\start\telescope.nvim/lua/telescope/_extensions/init.lua:20: in function '__index'
        [string ":lua"]:1: in main chunk

How can I fix this ?

The Exact same error happened to me also. I am on Ubuntu 22.04 LTS ,neovim installed through nix

Hello,have you installed sqlite3 in your ubuntu? Please find the README of your plugin's 'requires' to check the environment require.As for me,I use '        requires = {"kkharji/sqlite.lua"}',and in its document,I must install sqlite in my device before,using 'sudo apt-get install sqlite3'.

@IceShuttle
Copy link

Hello
I am using neovim 0.7.2 in Windows 10, sqlite installed via scoop
Installed via

use {
  "nvim-telescope/telescope-frecency.nvim",
  config = function()
    require"telescope".load_extension("frecency")
  end,
  requires = {"tami5/sqlite.lua"}
}

But when I run, I always got

E5108: Error executing lua ...ta\site\pack\packer\start\sqlite.lua/lua/sqlite/defs.lua:31: cannot load module 'libsqlite3': <d5>Ҳ<bb><b5><bd><b6><a8><b5><c4>ģ<bf>顣

stack traceback:

        [builtin#203]: at 0x7ff9657a6340
        ...ta\site\pack\packer\start\sqlite.lua/lua/sqlite/defs.lua:31: in main chunk
        [C]: in function 'require'
        ...a\site\pack\packer\start\sqlite.lua/lua/sqlite/utils.lua:252: in function '__index'
        ...data\site\pack\packer\start\sqlite.lua/lua/sqlite/db.lua:662: in main chunk
        [C]: in function 'require'
        ...ta\site\pack\packer\start\sqlite.lua/lua/sqlite/init.lua:66: in function '__index'
        ....nvim/lua/telescope/_extensions/frecency/sql_wrapper.lua:46: in function 'bootstrap'
        ...cy.nvim/lua/telescope/_extensions/frecency/db_client.lua:92: in function 'init'
        ...ope-frecency.nvim/lua/telescope/_extensions/frecency.lua:285: in function 'setup'
        ...\start\telescope.nvim/lua/telescope/_extensions/init.lua:20: in function '__index'
        [string ":lua"]:1: in main chunk

How can I fix this ?

The Exact same error happened to me also. I am on Ubuntu 22.04 LTS ,neovim installed through nix

Hello,have you installed sqlite3 in your ubuntu? Please find the README of your plugin's 'requires' to check the environment require.As for me,I use ' requires = {"kkharji/sqlite.lua"}',and in its document,I must install sqlite in my device before,using 'sudo apt-get install sqlite3'.

I tried running "sudo apt-get install sqlite3" but the problem still persisted but strangely Telescope.nvim still kinda works

@WendaoLee
Copy link

Hello
I am using neovim 0.7.2 in Windows 10, sqlite installed via scoop
Installed via

use {
  "nvim-telescope/telescope-frecency.nvim",
  config = function()
    require"telescope".load_extension("frecency")
  end,
  requires = {"tami5/sqlite.lua"}
}

But when I run, I always got

E5108: Error executing lua ...ta\site\pack\packer\start\sqlite.lua/lua/sqlite/defs.lua:31: cannot load module 'libsqlite3': <d5>Ҳ<bb><b5><bd><b6><a8><b5><c4>ģ<bf>顣

stack traceback:

        [builtin#203]: at 0x7ff9657a6340
        ...ta\site\pack\packer\start\sqlite.lua/lua/sqlite/defs.lua:31: in main chunk
        [C]: in function 'require'
        ...a\site\pack\packer\start\sqlite.lua/lua/sqlite/utils.lua:252: in function '__index'
        ...data\site\pack\packer\start\sqlite.lua/lua/sqlite/db.lua:662: in main chunk
        [C]: in function 'require'
        ...ta\site\pack\packer\start\sqlite.lua/lua/sqlite/init.lua:66: in function '__index'
        ....nvim/lua/telescope/_extensions/frecency/sql_wrapper.lua:46: in function 'bootstrap'
        ...cy.nvim/lua/telescope/_extensions/frecency/db_client.lua:92: in function 'init'
        ...ope-frecency.nvim/lua/telescope/_extensions/frecency.lua:285: in function 'setup'
        ...\start\telescope.nvim/lua/telescope/_extensions/init.lua:20: in function '__index'
        [string ":lua"]:1: in main chunk

How can I fix this ?

The Exact same error happened to me also. I am on Ubuntu 22.04 LTS ,neovim installed through nix

Hello,have you installed sqlite3 in your ubuntu? Please find the README of your plugin's 'requires' to check the environment require.As for me,I use ' requires = {"kkharji/sqlite.lua"}',and in its document,I must install sqlite in my device before,using 'sudo apt-get install sqlite3'.

I tried running "sudo apt-get install sqlite3" but the problem still persisted but strangely Telescope.nvim still kinda works

Can you post your specification here,with your error info?
For your confuse, the Telescope isn't a plugin rely on sqlite3,but its extension frequency need.

@IceShuttle
Copy link

Hello
I am using neovim 0.7.2 in Windows 10, sqlite installed via scoop
Installed via

use {
  "nvim-telescope/telescope-frecency.nvim",
  config = function()
    require"telescope".load_extension("frecency")
  end,
  requires = {"tami5/sqlite.lua"}
}

But when I run, I always got

E5108: Error executing lua ...ta\site\pack\packer\start\sqlite.lua/lua/sqlite/defs.lua:31: cannot load module 'libsqlite3': <d5>Ҳ<bb><b5><bd><b6><a8><b5><c4>ģ<bf>顣

stack traceback:

        [builtin#203]: at 0x7ff9657a6340
        ...ta\site\pack\packer\start\sqlite.lua/lua/sqlite/defs.lua:31: in main chunk
        [C]: in function 'require'
        ...a\site\pack\packer\start\sqlite.lua/lua/sqlite/utils.lua:252: in function '__index'
        ...data\site\pack\packer\start\sqlite.lua/lua/sqlite/db.lua:662: in main chunk
        [C]: in function 'require'
        ...ta\site\pack\packer\start\sqlite.lua/lua/sqlite/init.lua:66: in function '__index'
        ....nvim/lua/telescope/_extensions/frecency/sql_wrapper.lua:46: in function 'bootstrap'
        ...cy.nvim/lua/telescope/_extensions/frecency/db_client.lua:92: in function 'init'
        ...ope-frecency.nvim/lua/telescope/_extensions/frecency.lua:285: in function 'setup'
        ...\start\telescope.nvim/lua/telescope/_extensions/init.lua:20: in function '__index'
        [string ":lua"]:1: in main chunk

How can I fix this ?

The Exact same error happened to me also. I am on Ubuntu 22.04 LTS ,neovim installed through nix

Hello,have you installed sqlite3 in your ubuntu? Please find the README of your plugin's 'requires' to check the environment require.As for me,I use ' requires = {"kkharji/sqlite.lua"}',and in its document,I must install sqlite in my device before,using 'sudo apt-get install sqlite3'.

I tried running "sudo apt-get install sqlite3" but the problem still persisted but strangely Telescope.nvim still kinda works

Can you post your specification here,with your error info? For your confuse, the Telescope isn't a plugin rely on sqlite3,but its extension frequency need.

OS: Ubuntu 22.04 lts
Neovim version: 0.7.2 (nix pkg)
Configuration: I am using nvchad vanilla without any modifications https://nvchad.com/
Error message : "packer.nvim: Error running config for telescope-frecency.nvim: ...im/site/pack/packer/
start/sqlite.lua/lua/sqlite/defs.lua:31: libsqlite3.so: cannot open shared object file
: No such file or directory"

I also installed sqlite3 but the error still persisted. BTW thanks for clarification

@WendaoLee
Copy link

Hello
I am using neovim 0.7.2 in Windows 10, sqlite installed via scoop
Installed via

use {
  "nvim-telescope/telescope-frecency.nvim",
  config = function()
    require"telescope".load_extension("frecency")
  end,
  requires = {"tami5/sqlite.lua"}
}

But when I run, I always got

E5108: Error executing lua ...ta\site\pack\packer\start\sqlite.lua/lua/sqlite/defs.lua:31: cannot load module 'libsqlite3': <d5>Ҳ<bb><b5><bd><b6><a8><b5><c4>ģ<bf>顣

stack traceback:

        [builtin#203]: at 0x7ff9657a6340
        ...ta\site\pack\packer\start\sqlite.lua/lua/sqlite/defs.lua:31: in main chunk
        [C]: in function 'require'
        ...a\site\pack\packer\start\sqlite.lua/lua/sqlite/utils.lua:252: in function '__index'
        ...data\site\pack\packer\start\sqlite.lua/lua/sqlite/db.lua:662: in main chunk
        [C]: in function 'require'
        ...ta\site\pack\packer\start\sqlite.lua/lua/sqlite/init.lua:66: in function '__index'
        ....nvim/lua/telescope/_extensions/frecency/sql_wrapper.lua:46: in function 'bootstrap'
        ...cy.nvim/lua/telescope/_extensions/frecency/db_client.lua:92: in function 'init'
        ...ope-frecency.nvim/lua/telescope/_extensions/frecency.lua:285: in function 'setup'
        ...\start\telescope.nvim/lua/telescope/_extensions/init.lua:20: in function '__index'
        [string ":lua"]:1: in main chunk

How can I fix this ?

The Exact same error happened to me also. I am on Ubuntu 22.04 LTS ,neovim installed through nix

Hello,have you installed sqlite3 in your ubuntu? Please find the README of your plugin's 'requires' to check the environment require.As for me,I use ' requires = {"kkharji/sqlite.lua"}',and in its document,I must install sqlite in my device before,using 'sudo apt-get install sqlite3'.

I tried running "sudo apt-get install sqlite3" but the problem still persisted but strangely Telescope.nvim still kinda works

Can you post your specification here,with your error info? For your confuse, the Telescope isn't a plugin rely on sqlite3,but its extension frequency need.

OS: Ubuntu 22.04 lts Neovim version: 0.7.2 (nix pkg) Configuration: I am using nvchad vanilla without any modifications https://nvchad.com/ Error message : "packer.nvim: Error running config for telescope-frecency.nvim: ...im/site/pack/packer/ start/sqlite.lua/lua/sqlite/defs.lua:31: libsqlite3.so: cannot open shared object file : No such file or directory"

I also installed sqlite3 but the error still persisted. BTW thanks for clarification

I'm sorry I made a mistake in my previous reply,this plugin need sudo apt-get install sqlite3 libsqlite3-dev # Ubuntu,not only the sudo apt-get install sqlite3.Which you can refer his doc in Github.When I replied you I was having my breakfast and I reply with mobile Github so I didn't pay much caution to my answer.It's my fault.

If this didn't work,can you post your plugin's specification?That means the code you write in your packer.For instance,in my ubuntu nvim's config,it is the code like this:

    use {
        "nvim-telescope/telescope-frecency.nvim",
        config = function()
            require"telescope".load_extension("frecency")
        end,
        requires = {"kkharji/sqlite.lua"}
    }

@IceShuttle
Copy link

Hello
I am using neovim 0.7.2 in Windows 10, sqlite installed via scoop
Installed via

use {
  "nvim-telescope/telescope-frecency.nvim",
  config = function()
    require"telescope".load_extension("frecency")
  end,
  requires = {"tami5/sqlite.lua"}
}

But when I run, I always got

E5108: Error executing lua ...ta\site\pack\packer\start\sqlite.lua/lua/sqlite/defs.lua:31: cannot load module 'libsqlite3': <d5>Ҳ<bb><b5><bd><b6><a8><b5><c4>ģ<bf>顣

stack traceback:

        [builtin#203]: at 0x7ff9657a6340
        ...ta\site\pack\packer\start\sqlite.lua/lua/sqlite/defs.lua:31: in main chunk
        [C]: in function 'require'
        ...a\site\pack\packer\start\sqlite.lua/lua/sqlite/utils.lua:252: in function '__index'
        ...data\site\pack\packer\start\sqlite.lua/lua/sqlite/db.lua:662: in main chunk
        [C]: in function 'require'
        ...ta\site\pack\packer\start\sqlite.lua/lua/sqlite/init.lua:66: in function '__index'
        ....nvim/lua/telescope/_extensions/frecency/sql_wrapper.lua:46: in function 'bootstrap'
        ...cy.nvim/lua/telescope/_extensions/frecency/db_client.lua:92: in function 'init'
        ...ope-frecency.nvim/lua/telescope/_extensions/frecency.lua:285: in function 'setup'
        ...\start\telescope.nvim/lua/telescope/_extensions/init.lua:20: in function '__index'
        [string ":lua"]:1: in main chunk

How can I fix this ?

The Exact same error happened to me also. I am on Ubuntu 22.04 LTS ,neovim installed through nix

Hello,have you installed sqlite3 in your ubuntu? Please find the README of your plugin's 'requires' to check the environment require.As for me,I use ' requires = {"kkharji/sqlite.lua"}',and in its document,I must install sqlite in my device before,using 'sudo apt-get install sqlite3'.

I tried running "sudo apt-get install sqlite3" but the problem still persisted but strangely Telescope.nvim still kinda works

Can you post your specification here,with your error info? For your confuse, the Telescope isn't a plugin rely on sqlite3,but its extension frequency need.

OS: Ubuntu 22.04 lts Neovim version: 0.7.2 (nix pkg) Configuration: I am using nvchad vanilla without any modifications https://nvchad.com/ Error message : "packer.nvim: Error running config for telescope-frecency.nvim: ...im/site/pack/packer/ start/sqlite.lua/lua/sqlite/defs.lua:31: libsqlite3.so: cannot open shared object file : No such file or directory"
I also installed sqlite3 but the error still persisted. BTW thanks for clarification

I'm sorry I made a mistake in my previous reply,this plugin need sudo apt-get install sqlite3 libsqlite3-dev # Ubuntu,not only the sudo apt-get install sqlite3.Which you can refer his doc in Github.When I replied you I was having my breakfast and I reply with mobile Github so I didn't pay much caution to my answer.It's my fault.

If this didn't work,can you post your plugin's specification?That means the code you write in your packer.For instance,in my ubuntu nvim's config,it is the code like this:

    use {
        "nvim-telescope/telescope-frecency.nvim",
        config = function()
            require"telescope".load_extension("frecency")
        end,
        requires = {"kkharji/sqlite.lua"}
    }

Thank you very much for your help it work but I had to do some tweaks
I installed libsqlite3-dev as you said but the problem still persisted but then I ran
this command
let g:sqlite_clib_path = "/usr/lib/x86_64-linux-gnu/libsqlite3.so"

inside vim then it could detect the file
I think the issue is not in the frequency but the "sqlite.lua" itself
I added this to my config and now it runs as expected

@IceShuttle
Copy link

Hello
I am using neovim 0.7.2 in Windows 10, sqlite installed via scoop
Installed via

use {
  "nvim-telescope/telescope-frecency.nvim",
  config = function()
    require"telescope".load_extension("frecency")
  end,
  requires = {"tami5/sqlite.lua"}
}

But when I run, I always got

E5108: Error executing lua ...ta\site\pack\packer\start\sqlite.lua/lua/sqlite/defs.lua:31: cannot load module 'libsqlite3': <d5>Ҳ<bb><b5><bd><b6><a8><b5><c4>ģ<bf>顣

stack traceback:

        [builtin#203]: at 0x7ff9657a6340
        ...ta\site\pack\packer\start\sqlite.lua/lua/sqlite/defs.lua:31: in main chunk
        [C]: in function 'require'
        ...a\site\pack\packer\start\sqlite.lua/lua/sqlite/utils.lua:252: in function '__index'
        ...data\site\pack\packer\start\sqlite.lua/lua/sqlite/db.lua:662: in main chunk
        [C]: in function 'require'
        ...ta\site\pack\packer\start\sqlite.lua/lua/sqlite/init.lua:66: in function '__index'
        ....nvim/lua/telescope/_extensions/frecency/sql_wrapper.lua:46: in function 'bootstrap'
        ...cy.nvim/lua/telescope/_extensions/frecency/db_client.lua:92: in function 'init'
        ...ope-frecency.nvim/lua/telescope/_extensions/frecency.lua:285: in function 'setup'
        ...\start\telescope.nvim/lua/telescope/_extensions/init.lua:20: in function '__index'
        [string ":lua"]:1: in main chunk

How can I fix this ?

The Exact same error happened to me also. I am on Ubuntu 22.04 LTS ,neovim installed through nix

Hello,have you installed sqlite3 in your ubuntu? Please find the README of your plugin's 'requires' to check the environment require.As for me,I use ' requires = {"kkharji/sqlite.lua"}',and in its document,I must install sqlite in my device before,using 'sudo apt-get install sqlite3'.

I tried running "sudo apt-get install sqlite3" but the problem still persisted but strangely Telescope.nvim still kinda works

Can you post your specification here,with your error info? For your confuse, the Telescope isn't a plugin rely on sqlite3,but its extension frequency need.

OS: Ubuntu 22.04 lts Neovim version: 0.7.2 (nix pkg) Configuration: I am using nvchad vanilla without any modifications https://nvchad.com/ Error message : "packer.nvim: Error running config for telescope-frecency.nvim: ...im/site/pack/packer/ start/sqlite.lua/lua/sqlite/defs.lua:31: libsqlite3.so: cannot open shared object file : No such file or directory"
I also installed sqlite3 but the error still persisted. BTW thanks for clarification

I'm sorry I made a mistake in my previous reply,this plugin need sudo apt-get install sqlite3 libsqlite3-dev # Ubuntu,not only the sudo apt-get install sqlite3.Which you can refer his doc in Github.When I replied you I was having my breakfast and I reply with mobile Github so I didn't pay much caution to my answer.It's my fault.
If this didn't work,can you post your plugin's specification?That means the code you write in your packer.For instance,in my ubuntu nvim's config,it is the code like this:

    use {
        "nvim-telescope/telescope-frecency.nvim",
        config = function()
            require"telescope".load_extension("frecency")
        end,
        requires = {"kkharji/sqlite.lua"}
    }

Thank you very much for your help it work but I had to do some tweaks I installed libsqlite3-dev as you said but the problem still persisted but then I ran this command let g:sqlite_clib_path = "/usr/lib/x86_64-linux-gnu/libsqlite3.so"

inside vim then it could detect the file I think the issue is not in the frequency but the "sqlite.lua" itself I added this to my config and now it runs as expected

My pull request on kkharji/sqlite.lua has been merged thus there is no need of this work around on Linux as I have fixed this issue on linux

@yifan0414
Copy link

Hello
I am using neovim 0.7.2 in Windows 10, sqlite installed via scoop
Installed via

use {
  "nvim-telescope/telescope-frecency.nvim",
  config = function()
    require"telescope".load_extension("frecency")
  end,
  requires = {"tami5/sqlite.lua"}
}

But when I run, I always got

E5108: Error executing lua ...ta\site\pack\packer\start\sqlite.lua/lua/sqlite/defs.lua:31: cannot load module 'libsqlite3': <d5>Ҳ<bb><b5><bd><b6><a8><b5><c4>ģ<bf>顣

stack traceback:

        [builtin#203]: at 0x7ff9657a6340
        ...ta\site\pack\packer\start\sqlite.lua/lua/sqlite/defs.lua:31: in main chunk
        [C]: in function 'require'
        ...a\site\pack\packer\start\sqlite.lua/lua/sqlite/utils.lua:252: in function '__index'
        ...data\site\pack\packer\start\sqlite.lua/lua/sqlite/db.lua:662: in main chunk
        [C]: in function 'require'
        ...ta\site\pack\packer\start\sqlite.lua/lua/sqlite/init.lua:66: in function '__index'
        ....nvim/lua/telescope/_extensions/frecency/sql_wrapper.lua:46: in function 'bootstrap'
        ...cy.nvim/lua/telescope/_extensions/frecency/db_client.lua:92: in function 'init'
        ...ope-frecency.nvim/lua/telescope/_extensions/frecency.lua:285: in function 'setup'
        ...\start\telescope.nvim/lua/telescope/_extensions/init.lua:20: in function '__index'
        [string ":lua"]:1: in main chunk

How can I fix this ?

The Exact same error happened to me also. I am on Ubuntu 22.04 LTS ,neovim installed through nix

Hello,have you installed sqlite3 in your ubuntu? Please find the README of your plugin's 'requires' to check the environment require.As for me,I use ' requires = {"kkharji/sqlite.lua"}',and in its document,I must install sqlite in my device before,using 'sudo apt-get install sqlite3'.

I tried running "sudo apt-get install sqlite3" but the problem still persisted but strangely Telescope.nvim still kinda works

Can you post your specification here,with your error info? For your confuse, the Telescope isn't a plugin rely on sqlite3,but its extension frequency need.

OS: Ubuntu 22.04 lts Neovim version: 0.7.2 (nix pkg) Configuration: I am using nvchad vanilla without any modifications https://nvchad.com/ Error message : "packer.nvim: Error running config for telescope-frecency.nvim: ...im/site/pack/packer/ start/sqlite.lua/lua/sqlite/defs.lua:31: libsqlite3.so: cannot open shared object file : No such file or directory"
I also installed sqlite3 but the error still persisted. BTW thanks for clarification

I'm sorry I made a mistake in my previous reply,this plugin need sudo apt-get install sqlite3 libsqlite3-dev # Ubuntu,not only the sudo apt-get install sqlite3.Which you can refer his doc in Github.When I replied you I was having my breakfast and I reply with mobile Github so I didn't pay much caution to my answer.It's my fault.

If this didn't work,can you post your plugin's specification?That means the code you write in your packer.For instance,in my ubuntu nvim's config,it is the code like this:

    use {
        "nvim-telescope/telescope-frecency.nvim",
        config = function()
            require"telescope".load_extension("frecency")
        end,
        requires = {"kkharji/sqlite.lua"}
    }

Thanks very much, this fixes my problem

@delphinus
Copy link
Member

Now the master branch does not use SQLite3 library. See #91, #148.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

6 participants