Last weeks everything was ok. But all of a sudden I can't run jupyter notebook (if i run it from the start menu it wont open / if i run it from anaconda navigator or dataspell it wont run and give me the following error:
Jupyter server process exited with code 1 Traceback (most recent call last): File "C:\Users\SOL-1\anaconda3\Lib\site-packages\notebook\traittypes.py", line 235, in _resolve_classes klass = self._resolve_string(klass) ^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "C:\Users\SOL-1\AppData\Roaming\Python\Python311\site-packages\traitlets\traitlets.py", line 2028, in _resolve_string return import_item(string) ^^^^^^^^^^^^^^^^^^^ File "C:\Users\SOL-1\AppData\Roaming\Python\Python311\site-packages\traitlets\utils\importstring.py", line 31, in import_item module = import(package, fromlist=[obj]) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ ModuleNotFoundError: No module named 'jupyter_server.contents' During handling of the above exception, another exception occurred: Traceback (most recent call last): File "C:\Users\SOL-1\anaconda3\Scripts\jupyter-notebook-script.py", line 10, in sys.exit(main()) ^^^^^^ File "C:\Users\SOL-1\AppData\Roaming\Python\Python311\site-packages\jupyter_core\application.py", line 280, in launch_instance super().launch_instance(argv=argv, **kwargs) File "C:\Users\SOL-1\AppData\Roaming\Python\Python311\site-packages\traitlets\config\application.py", line 1051, in launch_instance app = cls.instance(**kwargs) ^^^^^^^^^^^^^^^^^^^^^^ File "C:\Users\SOL-1\AppData\Roaming\Python\Python311\site-packages\traitlets\config\configurable.py", line 581, in instance inst = cls(*args, **kwargs) ^^^^^^^^^^^^^^^^^^^^ File "C:\Users\SOL-1\AppData\Roaming\Python\Python311\site-packages\traitlets\traitlets.py", line 1313, in new inst.setup_instance(*args, **kwargs) File "C:\Users\SOL-1\AppData\Roaming\Python\Python311\site-packages\traitlets\traitlets.py", line 1356, in setup_instance super(HasTraits, self).setup_instance(*args, **kwargs) File "C:\Users\SOL-1\AppData\Roaming\Python\Python311\site-packages\traitlets\traitlets.py", line 1332, in setup_instance init(self) File "C:\Users\SOL-1\anaconda3\Lib\site-packages\notebook\traittypes.py", line 226, in instance_init self._resolve_classes() File "C:\Users\SOL-1\anaconda3\Lib\site-packages\notebook\traittypes.py", line 238, in _resolve_classes warn(f"{klass} is not importable. Is it installed?", ImportWarning) TypeError: warn() missing 1 required keyword-only argument: 'stacklevel' )
Screenshot of the error when I try to run a simple code:
I reinstalled anaconda navigator (anaconda3), jupyter notebook, python. It doesnt work. Last weeks when it worked I just opened jupyter notebook from the start menu and then it opened in my browser as a localhost (it worked fine). If I try to do that now it just opens a cmd window and it shows a big text but closes very quickly as I cant see the text in it. I am currently enrolled in IBM Data Science Professional Certificate and I'm trying to use it like I used it in the previous courses but now it won't work.
Looks like you may be dealing with an error similar to this Github issue post: https://github.com/microsoft/azuredatastudio/issues/24436. Looks like the solution solved the error for multiple people.
Hope that helps