Difference between `jupyter` and `notebook`

I realized when I wanted to add more libraries to my jupyter notebook that there are two packages: jupyter, and the python notebook. What is the difference between these two packages? Is:

{ config, pkgs, ... }:
let
  python3-with-my-packages =
    pkgs.python3.withPackages (python-packages: with python-packages; [
      numpy
      notebook
  ]);
in
{
  environment.systemPackages = with pkgs; [
    python3-with-my-packages
  ];
  [...]
}

the way to go to add more packages to the notebook? If not, what is the way to go?

Thanks!

Just as with upstream, notebook is the actual Notebook, and jupyter is a meta-package including notebook but also including the console.

Thanks for your answer. What do you mean by including the console? Do you have an example of a command I can run with jupyter and not notebook? If I read the definition file it seems to just add a python kernel to notebook, but not sure to understand what’s the usecase, as notebook seems to already have a python kernel. Also, am I supposed to be able to overwrite the jupyter executable?

Thanks!

Ahh, you are referring to the top-level jupyter package. That one exists for when using multiple kernels, declaratively. It’s being used e.g. by our Jupyter service. When you just want a Python dev env, stick to the packages in python-packages.nix or pythonPackages.

Oh ok, thanks a lot!