Skip to content

Commit 519381e

Browse files
committed
Fix formatting
1 parent 6017256 commit 519381e

File tree

1 file changed

+34
-28
lines changed

1 file changed

+34
-28
lines changed

docs/html/user_guide.rst

Lines changed: 34 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -775,7 +775,7 @@ archives are built with identical packages.
775775
Fixing conflicting dependencies
776776
===============================
777777

778-
The purpose of this setion of documentation is to provide practical suggestions to
778+
The purpose of this section of documentation is to provide practical suggestions to
779779
pip users who encounter an error where pip cannot install their
780780
specified packages due to conflicting dependencies (a
781781
``ResolutionImpossible`` error).
@@ -792,6 +792,9 @@ like this:
792792
::
793793

794794
pip install package_coffee==0.44.1 package_tea==4.3.0
795+
796+
::
797+
795798
Due to conflicting dependencies pip cannot install package_coffee and
796799
package_tea:
797800
- package_coffee depends on package_water<3.0.0,>=2.4.2
@@ -801,11 +804,11 @@ In this example, pip cannot install the packages you have requested,
801804
because they each depend on different versions of the same package
802805
(``package_water``):
803806

804-
- ``package_coffee`` version ``0.44.1`` depends on a version of
805-
``package_water`` that is less than ``3.0.0`` but greater than or equal to
806-
``2.4.2``
807-
- ``package_tea`` version ``4.3.0`` depends on version ``2.3.1`` of
808-
``package_water``
807+
- ``package_coffee`` version ``0.44.1`` depends on a version of
808+
``package_water`` that is less than ``3.0.0`` but greater than or equal to
809+
``2.4.2``
810+
- ``package_tea`` version ``4.3.0`` depends on version ``2.3.1`` of
811+
``package_water``
809812

810813
Sometimes these messages are straightforward to read, because they use
811814
commonly understood comparison operators to specify the required version
@@ -814,25 +817,27 @@ commonly understood comparison operators to specify the required version
814817
However, Python packaging also supports some more complex ways for
815818
specifying package versions (e.g. ``~=`` or ``*``):
816819

817-
+------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------+
818-
| Operator | Description | Example |
819-
+============+=======================================================================================================================================================================+===============================================================================================================================================================+
820-
| ``>`` | Any version greater than the specified version | **``>3.1``:** any version greater than ``3.1`` |
821-
+------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------+
822-
| ``<`` | Any version less than the specified version | **``<3.1``:** any version less than ``3.1`` |
823-
+------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------+
824-
| ``<=`` | Any version less than or equal to the specified version | **``<=3.1``:** any version less than or equal to ``3.1`` |
825-
+------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------+
826-
| ``>=`` | Any version greater than or equal to the specified version | **``>=3.1``:** version ``3.1`` and greater |
827-
+------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------+
828-
| ``==`` | Exactly the specified version | **``==3.1``:** only version ``3.1`` |
829-
+------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------+
830-
| ``!=`` | Any version not equal to the specified version | **``!=3.1``:** any version other than ``3.1`` |
831-
+------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------+
832-
| ``~=`` | Any compatible release. Compatible releases are releases that are within the same major or minor version, assuming the package author is using semantic versioning. | **``~=3.1``:** version ``3.1`` or later, but not version ``4.0`` or later. **``~=3.1.2``:** version ``3.1.2`` or later, but not version ``3.2.0`` or later. |
833-
+------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------+
834-
| ``*`` | Can be used at the end of a version number to represent "all" | **``== 3.1.*``:** any version that starts with ``3.1``. Equivalent to ``~=3.1.0``. |
835-
+------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------+
820+
.. csv-table::
821+
:header: "Operator", "Description", "Example"
822+
823+
``>``, "Any version greater than the specified version", "``>3.1``: any
824+
version greater than 3.1"
825+
``<``, "Any version less than the specified version", "``<3.1``: any version
826+
less than ``3.1``"
827+
``<=``, "Any version less than or equal to the specified version", "``<=3.1``:
828+
any version less than or equal to ``3.1``",
829+
``>=``, "Any version greater than or equal to the specified
830+
version", "``>=3.1``: version ``3.1`` and greater"
831+
``==``, "Exactly the specified version", ``==3.1``: only version ``3.1``
832+
``!=``, "Any version not equal to the specified version", "``!=3.1``: any
833+
version other than ``3.1``"
834+
``~=``, "Any compatible release. Compatible releases are releases that are
835+
within the same major or minor version, assuming the package author is using
836+
semantic versioning.", "``~=3.1``: version ``3.1`` or later, but not version
837+
``4.0`` or later. ``~=3.1.2``: version ``3.1.2`` or later, but not
838+
version ``3.2.0`` or later."
839+
``*``,Can be used at the end of a version number to represent "all", "``== 3.
840+
1.*``: any version that starts with ``3.1``. Equivalent to ``~=3.1.0``."
836841

837842
The detailed specification of supported comparison operators can be
838843
found in :pep:`440`.
@@ -884,9 +889,10 @@ specifiers to *only* the more important package::
884889

885890
pip install package_coffee==0.44.1b0 package_tea
886891

887-
This will result in: - ``package_coffee 0.44.1b0``, which depends on
888-
``package_water 2.6.1`` - ``package_tea 4.1.3`` which also depends on
889-
``package_water 2.6.1``
892+
This will result in:
893+
894+
- ``package_coffee 0.44.1b0``, which depends on ``package_water 2.6.1``
895+
- ``package_tea 4.1.3`` which also depends on ``package_water 2.6.1``
890896

891897
Now that you have resolved the issue, you can repin the compatible
892898
package versions as required.

0 commit comments

Comments
 (0)