fabric icon indicating copy to clipboard operation
fabric copied to clipboard

Run dead link checker against Fabric docs

Open denyeart opened this issue 4 years ago • 10 comments

See history at https://jira.hyperledger.org/browse/FAB-18102

denyeart avatar Aug 09 '21 03:08 denyeart

Hi @denyeart , could you please guide me a little more about how to solve this issue as I'm new to hyperledger ?

ggold7046 avatar May 11 '23 19:05 ggold7046

@ggold7046 As a first pass, you could manually run a broken link checker against Fabric ReadTheDocs latest version and fix any broken links.

Ideally there would be a Github Action to run a broken link checker on a regular basis, for example https://github.com/marketplace/actions/my-broken-link-checker.

Any help on either approach would be appreciated.

denyeart avatar May 12 '23 15:05 denyeart

@denyeart

Hi, I started by adding a github workflow for checking the broken links. I think introducing the process for continuously checking the broken links and fixing the broken links should be done in a separate effort. Would it be possible for you to review this PR when time allows? Thanks again. https://github.com/hyperledger/fabric/pull/4312

yuriechan avatar Jul 11 '23 11:07 yuriechan

@yuriechan Thank you for adding the daily broken link checker. We can now use the results to fix the broken links.

denyeart avatar Jul 17 '23 18:07 denyeart

We can now use the results to fix the broken links.

@denyeart , could you tell me how these broken links are fixed ? Where would I find the broken links ?

ggold7046 avatar Sep 25 '23 07:09 ggold7046

@ggold7046

Broken Link Checker runs nightly, see results here: https://github.com/hyperledger/fabric/actions/workflows/broken-link-checker.yml

In the report, look for 404 not found errors. Here's an example:

https://hyperledger-fabric.readthedocs.io/en/latest/pluggable_endorsement_and_validation.html
	404	https://hyperledger.github.io/fabric-sdk-node/main/tutorial-chaincode-lifecycle.html

In this case, the problem is that Node SDK no longer supports chaincode deployment, and therefore the referenced doc page doesn't exist anymore. In this case the entire following sentence should be deleted:

If you are using the
Fabric SDK for Node.js, visit `How to install and start your chaincode <https://hyperledger.github.io/fabric-sdk-node/{BRANCH}/tutorial-chaincode-lifecycle.html>`__.

You could do a pull request for that one to get started.

Every occurrence of a broken link will have a different solution, I'd suggest to scan through the 404 errors and determine which ones you can fix quickly. Then the remaining broken links could be fixed by a maintainer who has more context.

denyeart avatar Sep 27 '23 16:09 denyeart

If you are using the Fabric SDK for Node.js, visit How to install and start your chaincode <https://hyperledger.github.io/fabric-sdk-node/{BRANCH}/tutorial-chaincode-lifecycle.html>__.

Hi @denyeart , I couldn't find from which doc page this line to be deleted.

ggold7046 avatar Sep 28 '23 07:09 ggold7046

If you are using the Fabric SDK for Node.js, visit How to install and start your chaincode <https://hyperledger.github.io/fabric-sdk-node/{BRANCH}/tutorial-chaincode-lifecycle.html>__.

Hi @denyeart , I couldn't find from which doc page this line to be deleted.

Hi @ggold7046 , thank you for looking into fixing the broken links! I suggest that you look into the latest version of the documentations, such as, https://hyperledger-fabric.readthedocs.io/en/latest/.

The main reason why is, the broken link checker that runs nightly only checks against the latest version of documentations.

yuriechan avatar Sep 28 '23 09:09 yuriechan

I suggest that you look into the latest version of the documentations, such as, https://hyperledger-fabric.readthedocs.io/en/latest/.

Hi @yuriechan , actually I'm trying to find out from which page in this document link; that contains the lines to be deleted. How to search it ?

ggold7046 avatar Sep 28 '23 14:09 ggold7046

@ggold7046 I grepped the Fabric source, you'll find that broken link in: docs/source/pluggable_endorsement_and_validation.rst

denyeart avatar Sep 28 '23 19:09 denyeart