Developing the Project#

This section provides a collection of guides for common development tasks, such as listing dependencies and using an interactive shell for debugging.

Listing dependencies#

If you want to get an overview of the dependencies used in the project, you can use the uv command to list them:

$ uv tree --frozen
Resolved 78 packages in 290ms
docbuild
├── click v8.2.1
├── jinja2 v3.1.6
│   └── markupsafe v3.0.2
├── lxml v6.0.0
├── pydantic v2.11.7
│   ├── annotated-types v0.7.0
│   ├── pydantic-core v2.33.2
│   │   └── typing-extensions v4.14.1
│   ├── typing-extensions v4.14.1
│   └── typing-inspection v0.4.1
│       └── typing-extensions v4.14.1
├── rich v14.0.0
│   ├── markdown-it-py v3.0.0
│   │   └── mdurl v0.1.2
│   └── pygments v2.19.2
└── tomlkit v0.13.3

This gives a tree-like structure of the dependencies, showing the main packages and their sub-dependencies. The output includes the package names and their versions, allowing you to see which libraries are being used in the project.

In case you want to list outdated dependencies, use the option --outdated:

$ uv tree --outdated
Resolved 78 packages in 15ms
docbuild
├── click v8.2.1
├── jinja2 v3.1.6
│   └── markupsafe v3.0.2
├── lxml v6.0.0
├── pydantic v2.11.7
│   ├── annotated-types v0.7.0
│   ├── pydantic-core v2.33.2 (latest: v2.35.2)
│   │   └── typing-extensions v4.14.1
│   ├── typing-extensions v4.14.1
│   └── typing-inspection v0.4.1
│       └── typing-extensions v4.14.1
├── rich v14.0.0
│   ├── markdown-it-py v3.0.0
│   │   └── mdurl v0.1.2
│   └── pygments v2.19.2
└── tomlkit v0.13.3

As you can see, the output indicates that the package pydantic-core has a newer version available (v2.35.2), while the others are up to date.

Using IPython#

This repository provides a convenient way to run IPython with the current environment, allowing you to easily import and test the code without needing to modify the Python path.

To start an interactive IPython shell with pre-loaded project modules, use the uipython alias (see Helper Tools). This is useful for experimenting with the project’s code and for debugging.

Running IPython using uv with alias uipython#
$ uipython

After the IPython shell is loaded, you can use the normal import without changing the import path:

Interactive IPython session#
[...]
In [1]: from docbuild.cli.context import Doctype
In [2]: Doctype
Out[2]: docbuild.models.doctype.Doctype