Mkdocs
Macports and Python¶
Macports installs python as needed. It accumulates versions of python without uninstalling old versions. It is good to uninstall the old versions and reinstall each broken package linked to the old version of python, like bind9. Especially bind9.
PIP will also install python modules, but they should be install AFTER macports not before because Macports may show conflict errors with PIP installed modules. Force installation and activation of Macports python modules, then reinstall PIP modules.
Install PIP¶
PIP installs python modules that may be used by Macports. To avoid confusion you may need to reinstall PIP modules to fix any problems.
Installation of mkdocs¶
sudo port install python39
sudo port install py39-pip
sudo port select --set python pip39
sudo port select --set python3 pip39
sudo port select --set pip pip39
sudo port select --set pip3 pip39
pip install --upgrade pip
Uninstall mkdocs
sudo -H pip uninstall mkdocs
sudo -H pip uninstall mkdocs-material
sudo -H pip uninstall markdown-include
Install mkdocs
Updating pip moduled
Reinstall all pip modules
Link mkdocs to the binary so you don’t need PATH
sudo ln -s -f /opt/local/Library/Frameworks/Python.framework/Versions/3.8/bin/mkdocs /opt/local/bin/mkdocs
PIP freeze list contains all modules and dependent modules. Install mkdocs and theme first, then check list.
Upgrade them all - remove any URL references
pip freeze > installed.in
pico installed.in
cat installed.in | sed 's/==/>=/' >installed.out
pip install -r installed.out --upgrade
Troubleshooting