Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: scipy intersphinx links point to bad urls (404) #542

Closed
delgadom opened this issue Mar 27, 2022 · 3 comments
Closed

docs: scipy intersphinx links point to bad urls (404) #542

delgadom opened this issue Mar 27, 2022 · 3 comments

Comments

@delgadom
Copy link
Contributor

delgadom commented Mar 27, 2022

Describe the bug

In the sparse docs, all links to scipy documentation result in 404 errors. See for example

Landing Page
On the first line of the landing page, all pointers to the scipy API reference are broken:

This implements sparse arrays of arbitrary dimension on top of numpy and scipy.sparse.

Here's the corresponding section as markdown (included here only for the purpose of illustrating the URLs - I know in reality this code is written in rst with intersphinx links):

This implements sparse arrays of arbitrary dimension on top of [numpy] 
(https://numpy.org/doc/stable/reference/index.html#module-numpy) and [scipy.sparse] 
(https://docs.scipy.org/doc/scipy/reference/reference/sparse.html#module-scipy.sparse).

From Scipy sparse matrices
Similarly, in the section on "Construct Sparse Arrays", all references to Scipy API docs, including in the section titles, are broken:

From Scipy sparse matrices
To construct COO array from spmatrix objects, you can use the COO.from_scipy_sparse method. As an example, if x is a scipy.sparse.spmatrix, you can do the following to get an equivalent COO array:

Here's the corresponding section as markdown:

From [Scipy sparse matrices](https://docs.scipy.org/doc/scipy/reference/reference/generated/scipy.sparse.spmatrix.html)
[](https://sparse.pydata.org/en/stable/construct.html#from-scipy-sparse-matrices)

To construct [COO](https://sparse.pydata.org/en/stable/generated/sparse.COO.html#sparse.COO) 
array from [spmatrix](https://docs.scipy.org/doc/scipy/reference/reference/generated/scipy.sparse.spmatrix.html#scipy.sparse.spmatrix)
objects, you can use the [COO.from_scipy_sparse](https://sparse.pydata.org/en/stable/generated/sparse.COO.from_scipy_sparse.html#sparse.COO.from_scipy_sparse)
method. As an example, if x is a [scipy.sparse.spmatrix](https://docs.scipy.org/doc/scipy/reference/reference/generated/scipy.sparse.spmatrix.html#scipy.sparse.spmatrix), 
you can do the following to get an equivalent 
[COO](https://sparse.pydata.org/en/stable/generated/sparse.COO.html#sparse.COO) array:

Explanation

The provided links point to https://docs.scipy.org/doc/scipy/reference/reference/generated/..., with reference twice. This should simply be https://docs.scipy.org/doc/scipy/reference/generated/..., as in https://docs.scipy.org/doc/scipy/reference/generated/scipy.sparse.spmatrix.html#scipy.sparse.spmatrix

Proposed Remedy

The culprit appears to be in docs/conf.py#L188:

    "numpy": ("https://docs.scipy.org/doc/numpy/", None),
    "scipy": ("https://docs.scipy.org/doc/scipy/reference/", None),
}

reference should simply be dropped from the scipy link

@delgadom delgadom added the bug Indicates an unexpected problem or unintended behavior label Mar 27, 2022
@delgadom
Copy link
Contributor Author

type:bug is probably not warranted. this is only an issue with the docs :)

delgadom added a commit to delgadom/sparse that referenced this issue Mar 27, 2022
@hameerabbasi hameerabbasi added type:docs and removed bug Indicates an unexpected problem or unintended behavior labels Mar 27, 2022
@hameerabbasi
Copy link
Collaborator

Thanks for the issue, would you be willing to make a PR?

@hameerabbasi
Copy link
Collaborator

Fixed in #543

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants