vscode jupyter notebook error Error: Session cannot generate requests

Viewed 4825

Error message in vs code when using jupyter extension connected to remote server using ssh.

Error: Session cannot generate requests
Error: Session cannot generate requests
at w.executeCodeCell (/root/.vscode-server/extensions/ms-toolsai.jupyter-2021.8.1236758218/out/client/extension.js:90:327199)
at w.execute (/root/.vscode-server/extensions/ms-toolsai.jupyter-2021.8.1236758218/out/client/extension.js:90:326520)
at w.start (/root/.vscode-server/extensions/ms-toolsai.jupyter-2021.8.1236758218/out/client/extension.js:90:322336)
at async t.CellExecutionQueue.executeQueuedCells (/root/.vscode-server/extensions/ms-toolsai.jupyter-2021.8.1236758218/out/client/extension.js:90:336863)
at async t.CellExecutionQueue.start (/root/.vscode-server/extensions/ms-toolsai.jupyter-2021.8.1236758218/out/client/extension.js:90:336403)

I got this error after running the code below.

import pandas as pd
from itertools import product
pd.DataFrame(product(item_table, user_table), columns = ['item_id', 'user_id'])

  • product function outputs all combinations of the given tables.
  • item_table has 39729 number of items(39729 by 1)
  • user_table has 251350 users(251350 by 1).

And the above code outputs 251350 x 39729 combination table.

Therefore I guess this is because of the large computation but I want to know the meaning of error messages and want to know how to solve the problem.

1 Answers

I have encountered the same problem (so so). It happened when I tried to import tensorflow.keras.

I was no longer able to import packages.

I just changed of conda environment, and then got back to the one I was working in and it worked (but trying to import keras still caused the same problem).

Related