cancel
Showing results for 
Search instead for 
Did you mean: 

Python not working in Q

BigGorilla
New Contributor III

Hello

I have installed embedpy and jupyterq but can't use python in a Q terminal. I also can't use Q in jupyter but I can use python in jupyter.

I get the following error any time I try to use python in a Q console. What does this error mean? I haven't found anyone else experiencing this issue.

q.p))p)abc = "hello"
'libpython
[14] C:\q\p.q:14:
.P.env:not H~P;
.p:(`:./p 2:(`init;3))[L;H;B]]

 

Thank you!

7 REPLIES 7

eohara
New Contributor III
New Contributor III

Could you try running this in command line, then starting a new q session?

export PATH="/usr/bin/anaconda3/bin:$PATH"

 

BigGorilla
New Contributor III

Hello, thanks for the reply.

I tried this in command prompt and also Q and neither understood the command.

I manually added "C:\Users\B\anaconda3\bin" to my environment PATH, but this didn't help either.

Thanks!

BigGorilla
New Contributor III

I am using Windows, by the way

cmccarthy1
New Contributor III
New Contributor III

Hi,

Could you please provide some more information about you're environment?

- What version of Python are you running?

- How did you install embedPy and JupyterQ?

The FAQ section of embedPy outlines some potential reasons for this problem https://code.kx.com/q/ml/embedpy/faq/#installing-embedpy-on-system-with-python-installed-from-source 

Hi! Thanks for the reply. I installed Python 3.8 and then installed embedPy and JupyterQ together following the instruction guide using pip.

What does it mean to install Python "manually"? How can I install it automatically? That sounds much easier.

Thanks!


following the instruction guide using pip.

By this do you mean using conda? Installing Python from source is probably more accurate, if you installed Python via conda this issue is much less common. Our suggestion is that you install everything within a conda environment.

Hi!

Yes, I do mean by using Conda. Thanks!