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

Running a cell doesn't do anything #3

Open
davidgomes opened this issue May 12, 2024 · 12 comments
Open

Running a cell doesn't do anything #3

davidgomes opened this issue May 12, 2024 · 12 comments

Comments

@davidgomes
Copy link

davidgomes commented May 12, 2024

Screen.Recording.2024-05-12.at.14.mp4

I have cloned the repo and ran npm install and npm run dev but once the demo launches, running cells doesn't actually work (as per the attached video). No errors are printed in the console.

(I also had to run npm install raw-loader otherwise I get:

<w> [webpack.cache.PackFileCacheStrategy] Caching failed for pack: Error: ENOENT: no such file or directory, rename '/Users/david/src/jupyter-nextjs-example/.next/cache/webpack/client-development-fallback/0.pack.gz_' -> '/Users/david/src/jupyter-nextjs-example/.next/cache/webpack/client-development-fallback/0.pack.gz'
 ⨯ ./node_modules/@datalayer/jupyter-react/lib/jupyter/lab/JupyterLabCss.js:48:1
Module not found: Can't resolve 'raw-loader'

)

@davidgomes
Copy link
Author

One very easy way to reproduce this is by just using GitHub Codespaces.

yarn install
yarn add raw-loader
yarn dev

And then opening the demo.

@davidgomes
Copy link
Author

davidgomes commented May 12, 2024

I also tried https://github.com/datalayer/jupyter-ui/tree/main/examples/next-js and I get exactly the same outcome.

And I can reproduce both on Firefox or Chrome.

@davidgomes
Copy link
Author

The only workaround I've found is pinning these dependencies backwards by 1 version each:

    "@datalayer/icons-react": "0.2.5",
    "@datalayer/jupyter-react": "0.9.8",
    "@datalayer/primer-addons": "0.2.3",

@echarles
Copy link
Collaborator

thx for reporting. raw-loader is needed indeed due to datalayer/jupyter-ui#213 - I will add it in this repo and in the example tomorrow.

For the cell which does not run, I can not reproduce on my local env. It work with both the shift-enter in the cell, and via the left side menu.

I clearly see in your video the message "Requesting cell execution with cell executor" - I have never seen that... I will have a deeper look tomorrow.

@davidgomes
Copy link
Author

@echarles when I first cloned this repo it worked for me as well. But then it stopped working. There’s something going on with dependency versions. I’d say the best surefire way to reproduce is by using GitHub Codespaces. You get a free fresh isolated environment there and it reproduces there.

@echarles
Copy link
Collaborator

Just pushed 6ef50c2 to add raw-loader and change the server url as per datalayer/jupyter-ui#214

Tried also with codespace, but it uses yarn 1 which will not work, it needs yarn 3 (see https://jupyter-ui.datalayer.tech/docs/examples/next-js/ - this is a requirement from jupyterlab. npm has shown some success at some point, but we need to work more on that.

Trying now with a codesandbox.

Screenshot from 2024-05-13 07-51-17

@echarles
Copy link
Collaborator

@davidgomes I have created https://codesandbox.io/p/devbox/jupyter-react-nextjs-qzv8c - Build and run work fine with npm. The cell execution works on that codesanbox for me.

@echarles
Copy link
Collaborator

Sorry, the correct link is https://codesandbox.io/p/devbox/jupyter-react-nextjs-qzv8cz

@davidgomes
Copy link
Author

Interesting @echarles, if you can't reproduce feel free to close this issue. I'll just stick with an older version of these packages for now.

@echarles
Copy link
Collaborator

Let's leave this open. It may be that you have a specific in your setup. Sticking to older versions in not good in the long term. Have you made changes to the code? Does you jupyter server/lab work fine?

@davidgomes
Copy link
Author

Sorry I won't be able to test again for a while.

@vipulsharma144
Copy link

primer-addons

I was facing the same issue in 0.10.0 .It works after downgrading jupyter-react to 0.9.8 .Thanks @davidgomes @echarles

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

3 participants