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 - fixing several broken hyperlinks #904

Closed
mjbear opened this issue Apr 1, 2024 · 5 comments
Closed

Docs - fixing several broken hyperlinks #904

mjbear opened this issue Apr 1, 2024 · 5 comments

Comments

@mjbear
Copy link
Contributor

mjbear commented Apr 1, 2024

Hello. It's nice to virtually meet you. 😀

I saw the notes on issue #593 and figured I can pitch in to fix some links up!

I believe I've accurately identified the corresponding readthedocs URL, but another set of eyes (please) couldn't hurt. Thank you!

I'd be glad to submit PRs for these docs fixes (once there's some feedback).
Would the maintainers prefer a PR per documentation file?

nornir]$ grep -ron 'ref/api' docs/*
docs/howto/handling_connections.ipynb:67:ref/api
docs/howto/handling_connections.ipynb:67:ref/api
docs/howto/handling_connections.ipynb:67:ref/api
docs/howto/handling_connections.ipynb:67:ref/api
docs/howto/handling_connections.ipynb:122:ref/api
docs/tutorial/initializing_nornir.ipynb:146:ref/api
docs/tutorial/failed_tasks.ipynb:381:ref/api
docs/tutorial/failed_tasks.ipynb:408:ref/api
docs/tutorial/failed_tasks.ipynb:408:ref/api
docs/tutorial/processors.ipynb:9:ref/api

"Processors are plugins that can execute code on certain events. For more information on those events check the [class documentation](../../ref/api/processors.rst).\n",

discussed on issue #593


"Now to create the [nornir](../../ref/api/nornir.rst#nornir) object:"

intent is probably linking to https://nornir.readthedocs.io/en/latest/api/nornir/init_nornir.html#nornir.init_nornir.InitNornir


"To achieve this `nornir` keeps a set of failed hosts in it's shared [data](../../ref/api/nornir.rst#nornir.core.state.GlobalState) object:"

intent seems to be https://nornir.readthedocs.io/en/latest/api/nornir/core/state.html#nornir.core.state.GlobalState


"If you want to mark some hosts as succeeded and make them back eligible for future tasks you can do it individually per host with the function [recover_host](../../ref/api/nornir.rst#nornir.core.state.GlobalState.recover_host) or reset the list completely with [reset_failed_hosts](../../ref/api/nornir.rst#nornir.core.state.GlobalState.reset_failed_hosts):"

https://nornir.readthedocs.io/en/latest/api/nornir/core/state.html#nornir.core.state.GlobalState.recover_host
and
https://nornir.readthedocs.io/en/latest/api/nornir/core/state.html#nornir.core.state.GlobalState.reset_failed_hosts


"[open_connection](../ref/api/inventory.rst#nornir.core.inventory.Host.open_connection), [close_connection](../ref/api/inventory.rst#nornir.core.inventory.Host.close_connection), [close_connections](../ref/api/inventory.rst#nornir.core.inventory.Host.close_connections) and [Nornir.close_connections](../ref/api/nornir.rst#nornir.core.Nornir.close_connections). For instance:"

https://nornir.readthedocs.io/en/latest/api/nornir/core/inventory.html#nornir.core.inventory.Host.open_connection
and
https://nornir.readthedocs.io/en/latest/api/nornir/core/inventory.html#nornir.core.inventory.Host.close_connection
and
https://nornir.readthedocs.io/en/latest/api/nornir/core/inventory.html#nornir.core.inventory.Host.close_connections
and
https://nornir.readthedocs.io/en/latest/api/nornir/core/__init__.html#nornir.core.__init__.Nornir.close_connections


"When using the [open_connection](../ref/api/inventory.rst#nornir.core.inventory.Host.open_connection) you can specify any parameters you want. If you don't, or if you let nornir open the connection automatically, nornir will read those parameters from the inventory. You can specify standard attributes at the object level if you want to reuse them across different connections or you can override them for each connection. For example:"

https://nornir.readthedocs.io/en/latest/api/nornir/core/inventory.html#nornir.core.inventory.Host.open_connection

@mjbear
Copy link
Contributor Author

mjbear commented Apr 4, 2024

Been a few days so I thought I'd ping this thread. Thank you!
@dbarrosop @ubaumann

@dbarrosop
Copy link
Contributor

Hi, sorry about that. Thanks for identifying the broken links, the tricky bit here is that the paths should be generated by sphinx rather than be hardcoded (otherwise links might point to the wrong thing in some cases). I dropped a comment in the PR you opened with an example.

@mjbear
Copy link
Contributor Author

mjbear commented Apr 6, 2024

All good.
This makes sense. Thank you for guiding me!

Hopefully these relative paths are correct.

As long as the processors PR goes well then I'll work up changes for the list below.

"Now to create the [nornir](../../ref/api/nornir.rst#nornir) object:"

../api/init_nornir.rst#nornir


"To achieve this `nornir` keeps a set of failed hosts in it's shared [data](../../ref/api/nornir.rst#nornir.core.state.GlobalState) object:"

../api/nornir.rst#nornir.core.state.GlobalState


"If you want to mark some hosts as succeeded and make them back eligible for future tasks you can do it individually per host with the function [recover_host](../../ref/api/nornir.rst#nornir.core.state.GlobalState.recover_host) or reset the list completely with [reset_failed_hosts](../../ref/api/nornir.rst#nornir.core.state.GlobalState.reset_failed_hosts):"

../api/nornir.rst#nornir.core.state.GlobalState.recover_host
../api/nornir.rst#nornir.core.state.GlobalState.reset_failed_hosts

"[open_connection](../ref/api/inventory.rst#nornir.core.inventory.Host.open_connection), [close_connection](../ref/api/inventory.rst#nornir.core.inventory.Host.close_connection), [close_connections](../ref/api/inventory.rst#nornir.core.inventory.Host.close_connections) and [Nornir.close_connections](../ref/api/nornir.rst#nornir.core.Nornir.close_connections). For instance:"

../api/inventory.rst#nornir.core.inventory.Host.open_connection
../api/inventory.rst#nornir.core.inventory.Host.close_connection
../api/inventory.rst#nornir.core.inventory.Host.close_connections
../api/nornir.rst#nornir.core.Nornir.close_connections

"When using the [open_connection](../ref/api/inventory.rst#nornir.core.inventory.Host.open_connection) you can specify any parameters you want. If you don't, or if you let nornir open the connection automatically, nornir will read those parameters from the inventory. You can specify standard attributes at the object level if you want to reuse them across different connections or you can override them for each connection. For example:"

../api/inventory.rst#nornir.core.inventory.Host.open_connection

@dbarrosop
Copy link
Contributor

dbarrosop commented Apr 11, 2024

I think this one can be close, can't it? Feel free to reopen otherwise.

@mjbear
Copy link
Contributor Author

mjbear commented Aug 5, 2024

🎯 Once I figure out how to get sphinx working so I can perform a local test then I'll know for sure.
🏆 And from there I can confidently submit PR(s) to fix these links.

All good. This makes sense. Thank you for guiding me!

Hopefully these relative paths are correct.

As long as the processors PR goes well then I'll work up changes for the list below.

"Now to create the [nornir](../../ref/api/nornir.rst#nornir) object:"

../api/init_nornir.rst#nornir

InitNornir docs link doesn't 404, so it is fixed at the current date+time.
Good. 😄

"To achieve this `nornir` keeps a set of failed hosts in it's shared [data](../../ref/api/nornir.rst#nornir.core.state.GlobalState) object:"

../api/nornir.rst#nornir.core.state.GlobalState

Correction: ../../api/nornir/core/state.rst#nornir.core.state.GlobalState

"If you want to mark some hosts as succeeded and make them back eligible for future tasks you can do it individually per host with the function [recover_host](../../ref/api/nornir.rst#nornir.core.state.GlobalState.recover_host) or reset the list completely with [reset_failed_hosts](../../ref/api/nornir.rst#nornir.core.state.GlobalState.reset_failed_hosts):"

../api/nornir.rst#nornir.core.state.GlobalState.recover_host
../api/nornir.rst#nornir.core.state.GlobalState.reset_failed_hosts

Correction:

../../api/nornir/core/state.rst#nornir.core.state.GlobalState.recover_host
../../api/nornir/core/state.rst#nornir.core.state.GlobalState.reset_failed_hosts

"[open_connection](../ref/api/inventory.rst#nornir.core.inventory.Host.open_connection), [close_connection](../ref/api/inventory.rst#nornir.core.inventory.Host.close_connection), [close_connections](../ref/api/inventory.rst#nornir.core.inventory.Host.close_connections) and [Nornir.close_connections](../ref/api/nornir.rst#nornir.core.Nornir.close_connections). For instance:"

../api/inventory.rst#nornir.core.inventory.Host.open_connection
../api/inventory.rst#nornir.core.inventory.Host.close_connection
../api/inventory.rst#nornir.core.inventory.Host.close_connections
../api/nornir.rst#nornir.core.Nornir.close_connections

Correction:

../api/nornir/core/inventory.rst#nornir.core.inventory.Host.open_connection
../api/nornir/core/inventory.rst#nornir.core.inventory.Host.close_connection
../api/nornir/core/inventory.rst#nornir.core.inventory.Host.close_connections

../api/nornir/core/__init__.rst#nornir.core.__init__.Nornir.close_connections

"When using the [open_connection](../ref/api/inventory.rst#nornir.core.inventory.Host.open_connection) you can specify any parameters you want. If you don't, or if you let nornir open the connection automatically, nornir will read those parameters from the inventory. You can specify standard attributes at the object level if you want to reuse them across different connections or you can override them for each connection. For example:"

../api/inventory.rst#nornir.core.inventory.Host.open_connection

Correction: ../api/nornir/core/inventory.rst#nornir.core.inventory.Host.open_connection

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