[Ovmsdev] How I got sphinx working on ubuntu 23.1 + WSL

Chris van der Meijden chris at arachnon.de
Sun Nov 17 14:11:00 HKT 2024


Hi Michael,

to get get pip working on Debian I need to remove (or rename) the file 

/usr/lib/python3.11/EXTERNALLY-MANAGED

After doing that I can use pip as normal. It should be the same on
Ubuntu.

There are other solutions too:

https://www.makeuseof.com/fix-pip-error-externally-managed-environment-linux/

But this is the one I prefer.

Regards

Chris

Am Sonntag, dem 17.11.2024 um 08:19 +0800 schrieb Michael Geddes via
OvmsDev:
> Firstly, thanks to Michael Balzer for fixing my errors in the rst
> files I checked in. (Also, apparently I can't spell Auxiliary -
> doh).  I _had_ tried to get sphinx working recently and failed
> miserably, so I tried again this morning.
> 
> The problem is that ubuntu:
> * Doesn't provide a package for m2r2 or sphinx-mdinclude (a fork of
> m2r2)
> * No longer allows you to pip install into the main python library
> path
> 
> So first I got rid of the installed sphinx-doc
> sudo apt remove sphinx-doc
> 
> Then I set up a sphinx virtual environment
> 
> pipx install sphinx
> pipx inject sphinx sphinx_rtd_theme docutils mistune requests sphinx-
> mdinclude
> 
> 
> For some reason I was getting run-time python errors with m2r2 which
> is why I tried switching to mdinclude.  
> 
> In docs/source/conf.py I changed
>  extensions = [ 'm2r2' ] 
> to be  'sphinx_mdinclude' instead of 'm2r2'
> 
> The pipx command creates a virtual execution environment for sphinx
> and puts a shim for sphinx in your local path that runs it in the
> virtual environment.
> 
> //.ichael
> _______________________________________________
> OvmsDev mailing list
> OvmsDev at lists.openvehicles.com
> http://lists.openvehicles.com/mailman/listinfo/ovmsdev

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openvehicles.com/pipermail/ovmsdev/attachments/20241117/7419ebec/attachment.htm>


More information about the OvmsDev mailing list