|
3 | 3 | import os |
4 | 4 | import sys |
5 | 5 |
|
6 | | -import sphobjinv as soi |
7 | 6 | from sphinx_api_relink.helpers import ( |
8 | 7 | get_branch_name, |
9 | 8 | get_execution_mode, |
|
15 | 14 | sys.path.insert(0, os.path.abspath(".")) |
16 | 15 | from _extend_docstrings import extend_docstrings # noqa: PLC2701 |
17 | 16 |
|
18 | | - |
19 | | -def create_constraints_inventory() -> None: |
20 | | - inv = soi.Inventory() |
21 | | - inv.project = "constraint" |
22 | | - constraint_object_names = [ |
23 | | - "Constraint", |
24 | | - "Domain", |
25 | | - "Problem", |
26 | | - "Solver", |
27 | | - "Variable", |
28 | | - ] |
29 | | - for object_name in constraint_object_names: |
30 | | - inv.objects.append( |
31 | | - soi.DataObjStr( |
32 | | - name=f"{inv.project}.{object_name}", |
33 | | - domain="py", |
34 | | - role="class", |
35 | | - priority="1", |
36 | | - uri=f"{inv.project}.{object_name}-class.html", |
37 | | - dispname="-", |
38 | | - ) |
39 | | - ) |
40 | | - text = inv.data_file(contract=True) |
41 | | - ztext = soi.compress(text) |
42 | | - soi.writebytes("constraint.inv", ztext) |
43 | | - |
44 | | - |
45 | | -create_constraints_inventory() |
46 | 17 | extend_docstrings() |
47 | 18 | set_intersphinx_version_remapping({ |
48 | 19 | "ipython": { |
@@ -250,7 +221,7 @@ def create_constraints_inventory() -> None: |
250 | 221 | "ampform": ("https://ampform.readthedocs.io/en/stable", None), |
251 | 222 | "attrs": (f"https://www.attrs.org/en/{pin('attrs')}", None), |
252 | 223 | "compwa": ("https://compwa.github.io", None), |
253 | | - "constraint": ("https://labix.org/doc/constraint/public", "constraint.inv"), |
| 224 | + "constraint": ("https://python-constraint.github.io/python-constraint", None), |
254 | 225 | "graphviz": ("https://graphviz.readthedocs.io/en/stable", None), |
255 | 226 | "IPython": (f"https://ipython.readthedocs.io/en/{pin('IPython')}", None), |
256 | 227 | "jsonschema": ("https://python-jsonschema.readthedocs.io/en/stable", None), |
|
0 commit comments