Giter Site home page Giter Site logo

Comments (11)

jghauser avatar jghauser commented on June 8, 2024

It looks like there's something fishy going on with the ~. Though I don't quite understand what as I have /home/julian/Documents/library/main in my config and it works without issues.

Does it also fail if you leave the config empty (papis.nvim then queries papis for the config values)?

I'll investigate this further later today.

from papis.nvim.

jghauser avatar jghauser commented on June 8, 2024

What OS are you on?

from papis.nvim.

maxmahlke avatar maxmahlke commented on June 8, 2024

I'm on Linux, pop-os. Leaving the config empty does not lead to an error but running :Telescope papis in that case provides me with zero options.

from papis.nvim.

jghauser avatar jghauser commented on June 8, 2024

Ok, thanks so much for helping debug this!

Did this error:

/home/max/~/astro/papers/ is not accessible by the current user!                                                 
/home/max/~/astro/papers/ is not accessible by the current user!                                                 
Press ENTER or type command to continue   

happen with the above config? Or when dir was set to ~/astro/papers/? If with the above config, then I'm a bit confused how that tilde got in there haha. If it wasn't with the above config, can you try again with /home/max/astro/papers (as in your above config) and send me the error message?

What might also help is to enable debug mode and send me the logs. There's instructions in the README.

from papis.nvim.

maxmahlke avatar maxmahlke commented on June 8, 2024

This message

/home/max/~/astro/papers/ is not accessible by the current user!

appeared with all different dir values I give in the first post. I spent some time looking into this now: I deleted the papis-nvim.sqlite3 file from the cache, after which the message vanished. I then started to see some papers appear in the :Telescope papis call, and I got a notification of a missing ref: entry in a paper. There are apparently numerous cases of this in my library, not sure why I never noticed this. [Side note: I made sure using stat that these files were not modified since I installed your plugin, confirming what you say in the readme, the info.yaml is not touched.]

As I'm fixing the missing references, the list of papers in the database grows, cool.

Now, I'd like to give you the debug info, but enabling the debug module does not work for me. I added it to the config (opening a PR about a missing comma in a second) yet

newconf["enable_modules"]["debug"]

remains False. I disabled impatient.nvim and put the papis.nvim setup call at the end of my init.lua, no success, the debug commands are not available.

I'll keep investigating. I'm now suspecting that this error is on my side, I'll keep you updated.

from papis.nvim.

jghauser avatar jghauser commented on June 8, 2024

This is how I found out that some ref fields were missing in my library too... ;)

And I should have thought of the database being in a funny state. I think similar things happened to me when changing the dir value. I think the PapisReInitData command might have fixed it (if it was available). In general, I guess we should handle this more gracefully... I'll think about how!

About debug. This is again something I can't seem to reproduce. In my config I have:

enable_modules = {
	["debug"] = true,
},

And this does the trick. 🤔 Do keep me updated. Otherwise if you could share a minimal config, I could try replicate things on my end.

from papis.nvim.

maxmahlke avatar maxmahlke commented on June 8, 2024

After adding the missing refentries and removing the cached papis-nvim.sqlite3 database, I can now select articles using :Telescope papis and insert their citations! It's a bit slow for the size of the database (738 articles) but I suspect that's on my telescope side.

A new issue is that the user commands throw errors, e.g. running :PapisOpenNote gives:

Error executing Lua callback: ...m/site/pack/packer/opt/papis.nvim/lua/papis/commands.lua:63: attempt to call field 'open_note' (a nil value)
stack traceback:
        ...m/site/pack/packer/opt/papis.nvim/lua/papis/commands.lua:63: in function <...m/site/pack/packer/opt/papis.nvim/lua/papis/commands.lua:62>

:PapisOpenFile and :PapisEditEntry give the analogous errors, it's the commands from the papis.commands module only. The debug commands work fine.

I think that this is just a symptom of the actual, yet to be discovered issue, much like the first one I reported was due to the malformed SQL database, which was due to missing ref entries. I'll close this one and open another if I'm able to figure out what's going wrong now. Stay tuned ;-)

from papis.nvim.

jghauser avatar jghauser commented on June 8, 2024

Glad to hear the first thing got sorted out!

Yeah, searching is a bit slow. My library is about double your size and searching isn't as smooth as I would want though also not so slow that i have to consciously wait for results. I haven't yet figured out how to speed things up. That's definitely on my todo list.

About the error. I get that too! I hadn't noticed because I always use the keymaps, and they're not affected. This should be an easy fix, gimme a couple of minutes! Thanks for reporting :)

from papis.nvim.

jghauser avatar jghauser commented on June 8, 2024

Ok, should be fixed now! Let me know if not and keep the bugs coming :)

from papis.nvim.

maxmahlke avatar maxmahlke commented on June 8, 2024

Can confirm that it works now! And +1 for speeding up the search, I will look into it as well, though I don't know much about the sqlite backend.

from papis.nvim.

jghauser avatar jghauser commented on June 8, 2024

The speed issue probably doesn't have to do with the sqlite backend. I've opened #8, happy to hear your feedback!

from papis.nvim.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.