Usage
pixi t
Arguments
List only packages matching a regular expression.
Options
The path to the
pixi.toml or pyproject.toml file.The environment to show the tree for. Defaults to the default environment.
The platform to show the tree for. Defaults to the current platform.
Invert the tree and show what depends on the given package (requires a regex argument).
Use the lockfile as-is without updating it.
Check if the lockfile is up-to-date. Errors if the lockfile is out-of-date.
Don’t install the environment before showing the tree.
Examples
Show full dependency tree
Show dependencies of a specific package
Show reverse dependencies (what depends on a package)
Show tree for a specific environment
Show tree for a different platform
Display Format
Color Coding
Dependency names are color-coded:- Green: Packages that are explicitly specified in the manifest
- Yellow: Conda package versions
- Blue: PyPI package versions
Tree Symbols
├──- Package has more siblings└──- Last package in the list
Understanding Dependencies
Direct Dependencies
Packages you explicitly add to your project are shown in green.Transitive Dependencies
Packages that are installed because they’re required by your direct dependencies.Example
pixi tree shows:
Inverted Tree
The--invert flag shows reverse dependencies - which packages depend on a given package:
numpydepends onpythonpandasdepends onnumpy(which depends onpython)requestsdepends onpythonpipdepends onpython
The
--invert flag requires a package name or regex to specify which package’s dependents you want to see.Filtering
By Package Name
numpy package and its dependencies.
By Regex Pattern
Use Cases
Debugging Dependency Conflicts
Understanding Package Size
Auditing Dependencies
Cross-Platform Dependencies
Package Sources
The tree distinguishes between:- Conda packages: Version numbers in yellow
- PyPI packages: Version numbers in blue
Differences from pixi list
| Feature | pixi tree | pixi list |
|---|---|---|
| Output | Hierarchical tree | Flat list |
| Shows relationships | Yes | No |
| Inverted view | Yes | No |
| Sorting | No | Yes |
| JSON output | No | Yes |
| Field selection | No | Yes |
Understanding the Output
Explicit vs Transitive
Circular Dependencies
If circular dependencies exist, the tree will show them but avoid infinite recursion.Performance
For large dependency trees:- Use filtering to focus on specific packages
- Consider using
pixi listfor a simpler overview - Use
--no-installif you don’t need to update the environment