[AstroPy] docs building issue

Miguel de Val-Borro miguel.deval at gmail.com
Wed Nov 20 19:24:09 EST 2013


On Wed, Nov 20, 2013 at 06:20:19PM -0500, Russell Hewett wrote:
> def get_graphviz_version():
>     try:
>         output = subprocess.check_output(
>             ['dot', '-V'], stdin=subprocess.PIPE,
>             stderr=subprocess.STDOUT,
>             shell=True)
>     except subprocess.CalledProcessError:
>         return '0'
>     tokens = output.split()
>     for token in tokens:
>         if re.match(b'[0-9.]*', token):
>             return token.decode('ascii')
>     return '0'
> 
> graphviz_found = LooseVersion(get_graphviz_version())
> graphviz_broken = LooseVersion('0.30')
> 
> if graphviz_found >= graphviz_broken:
>     needs_sphinx = '1.2b2'
> else:
>     needs_sphinx = '1.1'

It looks like the version comparison in Sphinx is done with the
major.minor numbers in the version string. Could you try to replace in
that file:

needs_sphinx = '1.2b2'
by
needs_sphinx = '1.2'

I'm not sure that it will help but maybe the comparison is failing
because of that.



More information about the AstroPy mailing list