SoFunction
Updated on 2024-11-16

jupyter notebook write code auto-completion implementation

procedure

Enter the command line environment. I am using conda. there are two ways to get to the command line.

Method 1: Through the anconda navigator interface, select environments, select the corresponding environment name, and select open terminal.

Method 2: Enter the command line directly using a terminal such as cmd or terminal. Activate the environment you want to configure for code completion (no need to activate if it is the default environment)

1. Installationnbextensions 

pip install jupyter_contrib_nbextensions -i /simple
jupyter contrib nbextension install --user

2. Installationnbextensions_configurator

pip install --user jupyter_nbextensions_configurator 
jupyter nbextensions_configurator enable --user

If you are prompted for missing dependencies, just use pip to install the corresponding dependencies.

Restart jupyter, in the main page that pops up, you can see the addition of a Nbextensions tab, in this page, check the Hinterland that is enabled code auto-completion, open a notebook feel it.

 

 

 

If an error occurs as follows:

Installing collected packages: msgpack
Could not install packages due to an EnvironmentError: [WinError 5] Denial of access。:
'E:\\JiangHeSong\\Anaconda35.2.0\\Lib\\site-packages\\msgpack\\_packer.cp36-win_
'
Consider using the `--user` option or check the permissions.

You are using pip version 10.0.1, however version 18.0 is available.
You should consider upgrading via the 'python -m pip install --upgrade pip' comm
and.

Just add a --user For example:

pip install --user msgpack -i /simple

Both can be installed properly!!!

to this article on jupyter notebook write code to achieve auto-completion of the article is introduced to this, more related jupyter notebook auto-completion content please search for my previous posts or continue to browse the following related articles I hope that you will support me in the future more!