Skip to content

DOC: better warning when nibabel not on path #503

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jan 12, 2017
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 8 additions & 3 deletions doc/source/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,6 @@
import sys
import os

import nibabel

# Check for external Sphinx extensions we depend on
try:
import numpydoc
Expand All @@ -34,6 +32,13 @@
except ImportError:
raise RuntimeError('Need to install "texext" package for doc build')

# Need nibabel installed as well
try:
import nibabel
except ImportError:
raise RuntimeError('Need nibabel on Python PATH; consider "make htmldoc" '
'from nibabel root directory')

# If extensions (or modules to document with autodoc) are in another directory,
# add these directories to sys.path here. If the directory is relative to the
# documentation root, use os.path.abspath to make it absolute, like shown here.
Expand Down Expand Up @@ -82,7 +87,7 @@

# General information about the project.
project = u'NiBabel'
copyright = u'2006-2016, %(MAINTAINER)s <%(AUTHOR_EMAIL)s>' % rel
copyright = u'2006-2017, %(MAINTAINER)s <%(AUTHOR_EMAIL)s>' % rel

# The version info for the project you're documenting, acts as replacement for
# |version| and |release|, also used in various other places throughout the
Expand Down