This notebooks shows how a warning and an error is raised when there is no title in the first cell.

Publish without title#

from nbproject import header, meta, publish
import pytest

header()
idaK1IQUYIQsMs
version0
time_init2022-06-08 14:42
time_run2023-04-16 04:55
pypackage_storenbproject==0.0.7+2.g8521e30
pypackage_livenbproject==0.8.4 pytest==7.3.1
meta.live.title  # returns None
publish() == "no-title"
❌ No title! Update & save your notebook with a title '# My title' in the first cell.
True