@@ -43,3 +43,25 @@ For example, the `rich <https://rich.readthedocs.io/>`_ Python library
43
43
to declare its library dependencies
44
44
and installs itself on Read the Docs
45
45
`with pip <https://github.com/willmcgugan/rich/blob/ba5d0c2c/.readthedocs.yml#L18-L19 >`_.
46
+
47
+ Locking your dependencies
48
+ -------------------------
49
+
50
+ With you ``pyproject.toml `` file you are free to `specify the dependency
51
+ versions <https://python-poetry.org/docs/dependency-specification/> `_
52
+ that are more appropriate for your project,
53
+ either by leaving them unpinned or setting some constraints.
54
+ However, to achieve :doc: `/guides/reproducible-builds `
55
+ it is better that you lock your dependencies,
56
+ so that the decision to upgrade any of them is yours.
57
+ Poetry does this using ``poetry.lock `` files
58
+ that contain the exact versions of all your transitive dependencies
59
+ (that is, all the dependencies of your dependencies).
60
+
61
+ The first time you run ``poetry install `` in your project directory
62
+ `Poetry will generate a new poetry.lock
63
+ file <https://python-poetry.org/docs/basic-usage/#installing-without-poetrylock> `_
64
+ with the versions available at that moment.
65
+ You can then `commit your poetry.lock to version
66
+ control <https://python-poetry.org/docs/basic-usage/#commit-your-poetrylock-file-to-version-control> `_
67
+ so that Read the Docs also uses these exact dependencies.
0 commit comments