-
Notifications
You must be signed in to change notification settings - Fork 24
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] pyenv causes issues with image rendering #92
Comments
I'm on a train currently, so no Internet and answering from my phone, but I have a few ideas: You probably need to update to the master branch of image.nvim and I probably need to update my docs. If that doesn't fix it could you try these things:
|
Yup all that behavior seems normal. I've got time to dig into this. Thank you for providing a minimal config, i'll take a look. |
I think I did find the one difference between that image.nvim test and when I try to use molten. It is Using this to test rendering: :lua require("image").from_file("image.png"):render() |
Interesting. I wonder if there is a larger issue here then. Do you normally have Also I just merged the revert, if you could try using the main branch of molten now that will definitely fix a problem. But perhaps not the exact problem that you're having. |
that's odd. I will say that you should be using host-program and a corresponding neovim virtual environment. They way neovim will always launch with the necessary decencies, and you don't have to install all the modules molten needs in every venv you create. |
Exactly the same issue here. Also on mac m1. But i dont run a special venv. |
Unfortunately I can't help much without a reproduction, I'm not seeing the issue with the current repro. I do wonder if @sphyrnidae8 are you using pyenv as well? |
Both of you should 100% set I recommend setting up a |
I think it does have something to do with pyenv. I was using pyenv for the different versions of python. I just uninstalled it and used a homebrew install of python3.10 and set up the environment like in your docs. Now everything works. Thanks! |
and yes updating to master has fixed an issue where it will only display the plot the first time in the output, and not if the output hides and then displays again |
Awesome! I'm curious about pyenv, now that I know that it's a problem I can look into it. Thank you for working with me on this one, environment issues are always tricky. |
I probably won't get around to this until after Christmas though |
I can't reproduce this issue with pyenv. I've installed it, set it up, activated it, installed pynvim and jupyter_client (and ipykernel), tested it with both an existing kernel and the new default python3 kernel, they both work. Images show in virtual text and in floating windows, and they show in multiple floating windows as well. I did confirm with My only guess is that you missed something with your pyenv install that you didn't miss when following the docs. |
I met a similar issue and I am pretty sure this is not caused by pyenv but poetry, which is commonly used together with pyenv. This is a known issue with image.nvim and there is no fix, but the workaround is to source the venv created by poetry directly instead of using the poetry shell |
Description
There is no image in the output, even though everything else is correctly displaying.
![image](https://private-user-images.githubusercontent.com/6133462/291940221-467e1588-aeed-4ca5-86e5-3781f9409b30.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjM3Mzk0MDgsIm5iZiI6MTcyMzczOTEwOCwicGF0aCI6Ii82MTMzNDYyLzI5MTk0MDIyMS00NjdlMTU4OC1hZWVkLTRjYTUtODZlNS0zNzgxZjk0MDliMzAucG5nP1gtQW16LUFsZ29yaXRobT1BV1M0LUhNQUMtU0hBMjU2JlgtQW16LUNyZWRlbnRpYWw9QUtJQVZDT0RZTFNBNTNQUUs0WkElMkYyMDI0MDgxNSUyRnVzLWVhc3QtMSUyRnMzJTJGYXdzNF9yZXF1ZXN0JlgtQW16LURhdGU9MjAyNDA4MTVUMTYyNTA4WiZYLUFtei1FeHBpcmVzPTMwMCZYLUFtei1TaWduYXR1cmU9MDBmMGQyZGVmNTJjY2VhNDc3NTY4ODIwODAxODBmZGU2ZjZiZDU1MmFiZjVkYzA0MWViNmJlNDEyOGJkMzk4YyZYLUFtei1TaWduZWRIZWFkZXJzPWhvc3QmYWN0b3JfaWQ9MCZrZXlfaWQ9MCZyZXBvX2lkPTAifQ.Nqyxhc4xwViq-CWPJB0gGduCUBVHhRB54GNUF11Q19s)
I believe I have everything properly installed
![image](https://private-user-images.githubusercontent.com/6133462/291940144-9932cadf-43e0-4ec0-b033-2732d93dd845.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MjM3Mzk0MDgsIm5iZiI6MTcyMzczOTEwOCwicGF0aCI6Ii82MTMzNDYyLzI5M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YXR1cmU9M2QwZmRmNTRiMWE5OTVmYWNjMjFmMWU2ODdiZTI4ZTEzMTYwNTg0YTM5YWQ2ZDI5NWU5YzNmZmE2N2E4Mjg4MSZYLUFtei1TaWduZWRIZWFkZXJzPWhvc3QmYWN0b3JfaWQ9MCZrZXlfaWQ9MCZyZXBvX2lkPTAifQ.2iW8o8u6nZwQTGkD6e0ovyIbVjmkzuYQlJxktFyfWG8)
and image.nvim works just fine with the test that they provide:
The issue is a lot like #7 on image.nvim repo. However, the fix/troubleshooting steps on that issue did not pertain to my issue with molten-nvim.
I am using a minimal test config file for neovim so that variables can be isolated (I didn't use a color scheme in the screenshots because I thought that might be the issue, but I added it back because it looks better)
Reproduction Steps
I am running python 3.12.1 currently. But I have also tried this with 3.11. Here are the python packages I have installed
For these current screenshots open up NeoVim with the slim config file
run the python file to test the plotting behavior
Expected Behavior
I expect that the plot would be drawn in the output box. I have tried changing settings in Molten but nothing I have tried has fixed the issue. If I am doing anything wrong let me know. I guess it seems like the issue would be Molten if image.nvim is able to output images with the exact same config.
The text was updated successfully, but these errors were encountered: