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

2 minutes to start a jupyterq kernel #62

Closed
kimtang opened this issue Dec 30, 2020 · 5 comments
Closed

2 minutes to start a jupyterq kernel #62

kimtang opened this issue Dec 30, 2020 · 5 comments

Comments

@kimtang
Copy link

kimtang commented Dec 30, 2020

Hi all,

when starting the jupyterq kernel we can see that the jupyterq_server.q q process is trying to make a connection to the 'outside'. See the strace below. Our servers are all secured and do not allow any connection to the outside.
However this side effect will timeout in 2 minutes making the q kernel unresponsive. Is it possible to turn this off?

Thanks,
Kim

(base) $strace -p 4928
Process 4928 attached
connect(12, {sa_family=AF_INET, sin_port=htons(443), sin_addr=inet_addr("74.50.49.235")}, 16^CProcess 4928 detached
<detached ...>

@Dianeod
Copy link
Contributor

Dianeod commented Jan 4, 2021

Hi Kim,

Just to clarify, when you say connect to the ‘outside’ do you mean trying to connect to the internet? When initializing jupyterq, it attempts to access https://code.kx.com/ to display documentation for built-in functions while running the notebooks which could cause that issue if internet connection is not available.

@kimtang
Copy link
Author

kimtang commented Jan 4, 2021

Hi Diane,

Yes, there is no internet connection available. Is there a flag to turn it off?

Kim

@Dianeod
Copy link
Contributor

Dianeod commented Jan 4, 2021

We are currently working on a fix for this that will hopefully be included within a future release. In the meantime, you can use the following workaround as a temporary fix:

In the script jupyterq_help.q found in your QHOME - amend line 30

refcard:@[req:{"c"$.p.import[urllib.request][:urlopen][x][:read][]};(hb:"https://code.kx.com/v2/"),"ref";{0}];

to

refcard:0;

@kimtang
Copy link
Author

kimtang commented Jan 4, 2021

This is good. Let me try it and will confirm back if it is working.
Thanks for your quick reply.

@kimtang
Copy link
Author

kimtang commented Jan 5, 2021

Yes, this is working.

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

2 participants