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

Jupyter Lab showing a 'Document is empty' display error after installing an extension #7189

Closed
super-sebajin opened this issue Sep 11, 2019 · 14 comments · Fixed by #7192
Closed
Assignees
Labels
bug pkg:ui-components status:resolved-locked Closed issues are locked after 30 days inactivity. Please open a new issue for related discussion.
Milestone

Comments

@super-sebajin
Copy link

Hello there, I am running Jupyter Lab 1.0.2 on Chrome. I have recently added the latex extension for jupyter lab and am now getting a display error:

Screenshot (6)

Also, I get this when executing the browser's inspector:

Screenshot (7)

I am new to Jupyter Lab but I do have working experience with Jupyter Notebooks. Hopefully this is an easily fixed issue. I really do enjoy the Lab version more than the notebook.

@jasongrout
Copy link
Contributor

This should be fixed as of a day ago or so. Can you try to clean and rebuild JupyterLab?

jupyter lab clean
jupyter lab build

This should have been fixed in #7182

@jasongrout
Copy link
Contributor

If that doesn't work, can you give us set of instructions to reproduce the issue, starting with creating a new conda environment (if you are using conda)?

@jasongrout jasongrout added this to the Reference milestone Sep 11, 2019
@super-sebajin
Copy link
Author

I wholly thank you, this has solved the issue, to some degree. As soon as I ran those to commands (the ones you provided me with) Jupyter Lab was able to run normally again, with the new extension!

The problem now is that I can no longer see the files and folders in the folders tab:

Screenshot (8)

Screenshot (9)

Hopefully this issue can fixed quickly, I really enjoy the jupyter platform!

@jasongrout
Copy link
Contributor

jasongrout commented Sep 12, 2019

That does indeed look weird. Can you upgrade to JupyterLab 1.0.10 or 1.1.3?

@jasongrout
Copy link
Contributor

jasongrout commented Sep 12, 2019

This may be related to QuantStack/jupyterlab-drawio#45, or at least have similar causes.

@jasongrout
Copy link
Contributor

I reproduced this new issue with the filebrowser not showing anything with:

conda create -n del-jlabext jupyterlab=1.0.2
jupyter labextension install @jupyterlab/latex
jupyter lab

CC @telamonian, since it appears to be an icon-related issue.

The relevant error (in my compiled code) is at the return statement here:

/**
 * A pure function for a notebook trust status component.
 *
 * @param props: the props for the component.
 *
 * @returns a tsx component for notebook trust.
 */
function NotebookTrustComponent(props) {
    const source = cellTrust(props)[1];
    return react__WEBPACK_IMPORTED_MODULE_0___default.a.createElement(_jupyterlab_statusbar__WEBPACK_IMPORTED_MODULE_2__["IconItem"], { source: source });
}

and the error is:

Warning: React.createElement: type is invalid -- expected a string (for built-in components) or a class/function (for composite components) but got: undefined. You likely forgot to export your component from the file it's defined in, or you might have mixed up default and named imports.

Check the render method of NotebookTrustComponent.
in NotebookTrustComponent
in div

@super-sebajin
Copy link
Author

Thank you so much @jasongrout you have been of most help! I am just getting started out with the Jupyter platform, I have always used the tradition Visual Studio or PyCharm IDE's and to be honest, Jupyter is QUITE faster than those two.

Everything seems to be working now, at least display-wise. If anything I will communicate any further issues to the team.

Thank you for your work!

@jasongrout
Copy link
Contributor

Thanks! Let's still keep this issue open to try to solve the thing I reproduced above.

@super-sebajin
Copy link
Author

super-sebajin commented Sep 12, 2019

I have no idea on how to go about helping, but as soon as I get some free time school I'll check some of those errors you reproduced above! Thank you once again!

@jasongrout
Copy link
Contributor

@telamonian - do you think #7192 fixes this issue?

@telamonian
Copy link
Member

It's certainly possible, but there's no particular reason to believe so. I'll see if I can also repro the second bug

@telamonian
Copy link
Member

I reproduced this new issue with the filebrowser not showing anything with:

conda create -n del-jlabext jupyterlab=1.0.2
jupyter labextension install @jupyterlab/latex
jupyter lab

CC @telamonian, since it appears to be an icon-related issue.

@jasongrout I followed your recipe, and though I wasn't able to reproduce filebrowser not showing anything, I did reproduce the NotebookTrustComponent error message. I figured that one out. Before 1.1, @jupyterlab/statusbar used to export a IconItem react component. IconItem was removed in favor of the icon handling stuff in ui-components. However, the code in @jupyterlab/notebook@v1.0.2 still tries to import IconItem and use it as part of NotebookTrustComponent. So the definition of IconItem is undefined, which causes the error.

I have a sudden deep wish that I had gotten the new icon stuff in before 1.0. The IconItem thing is fixable, but I still have no idea about the blank filebrowser

@telamonian
Copy link
Member

telamonian commented Sep 14, 2019

Okay, I was able to reproduce the blank filebrowser by installing jupyterlab-drawio.

I think the problem with trying to fix these bugs is that they're dependent upon the specific combination of old and new packages that the user has.

telamonian added a commit to telamonian/jupyterlab that referenced this issue Sep 14, 2019
@telamonian
Copy link
Member

telamonian commented Sep 14, 2019

There's now a fix up. It overlapped somewhat with #7192, so I just added it as a commit to that existing PR.

@super-sebajin After these changes are published, do a clean build:

jupyter lab clean
jupyter lab build

@lock lock bot added the status:resolved-locked Closed issues are locked after 30 days inactivity. Please open a new issue for related discussion. label Oct 16, 2019
@lock lock bot locked as resolved and limited conversation to collaborators Oct 16, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug pkg:ui-components status:resolved-locked Closed issues are locked after 30 days inactivity. Please open a new issue for related discussion.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants