ulif/diceware

Wordlists path is hardcoded in API doc

Closed this issue · 2 comments

drebs commented

The path to wordlist files is hardcoded in the generated sphinx
documentation and because it may differ depending on how the package is
installed this creates different problems:

  • the path hardcoded in the online api documentation may differ from
    the one in each installation, leading to incorrect information
    provided to the user of the api.

  • packaging diceware documentation to specific operating systems may
    generate unreproducible packages.

One possible solution is to replace the WORDLISTS_DIR with a function called get_wordlists_dir() and have the path be constructed during execution of the function rather than during module load time.

drebs commented

This is a proposal of fix: #38

ulif commented

That's great, thank you @drebs !
Just merged your code. I hope this will help with reproducibility :)