local robotpy docs - how?

My team’s school shuts off internet access for students, teams, etc. Which means we aren’t able to surf over to readthedocs to check on API details & such.

Hence, I pretty much download everything at home, put it on a stick and then upload to the workstations for off-line use at the school. Java doc, for example, I’m able to cache using wget and --recursive … and then it’s available offline (when we used to do java :slight_smile:

However, I’m unable to get the robotpy docs locally. I’ve tried git cloning the doc repo, and building the html locally. However, that still has numerous http:// references to external pages; not file:// references to local pages.

I’ve tried the wget trick, but with no success there, either. Same issue - external http references.

Any ideas how to get a fully local copy?

Thanks!
Otto

Currently the option doesn’t exist. I’ve filed a bug at Add local build option · Issue #22 · robotpy/robotpy-docs · GitHub … I suspect the easiest option would be a script that post-processes the generated files and does a search/replace on the URLs.

Thanks - will look at the post-process option

The docs are on read the docs which allows you to download an html, PDF, or EPUB version of the documentation. You can access this by clicking on the menu button and the little triangle next to the version you are reading. It will open a new menu window. At the bottom will be the download option.

Really good to know - thank you!

I grabbed the pdf for latest, and alas, the links in the doc point out to the readthedocs.io url. So, I’m back to seeing if I can post-process the links…

It would be almost impossible in the PDF without acrobat pro, easier in the html, but may not be necessary in the epub. I will check later today.

I poked around, and I think I discovered the problem.

In all 3 versions, the links worked for me as expected, but the docs have two types of links.

  1. Internal links which point to places in the docs (E.X. Hardware & Sensors, robotpy- cscore install, etc).

  2. External links which point to important websites (Ex. The robotpy fit, or opencv pypi project page).

So, if wanted to rewrite the external links and point them to local installs, I would recommend the html. Otherwise, either option should work.

Good luck.

~Mr. R^2

It seems that it would be really useful to have a script that clones all the repos, runs build, does the substitutions, and then sticks them all in a single directory structure.

So,
I think I figured out what the issue is, and this is directly related to Virtuald’s post above.

Though any version of the readthedocs file downloads with links, some different sections (specifically all API related) are actually different read the docs files (presumably based on folder structure), and therefore skipped during download.

So, if you want access to the entire robotpy help file with all the API, download each section separately by doing the following…

  1. Go to the the robotpy readthedocs file.
  2. Click the hamburger menu icon.
  3. Click v:stable (or whichever version you are browsing).
  4. Click the flavor you want to download (PDF, html, or epb).
    5)Go back to the readthedocs menu.
    6)Click wpilib Api.
  5. Repeat steps 2-6 for each Api you want to access offline (for me, it defaults to v:latest when I click on Api sections, but you can change this to stable easily enough by clicking the stable version in step 4).

I needed to do this for each subsection of the API Reference section of the manual.

For some this may be self evident, but it took me a while to figure out and now our team will have it offline for our event, so thought I would share.