diff --git a/docs/Makefile b/docs/Makefile index fb03f26e..03886de1 100644 --- a/docs/Makefile +++ b/docs/Makefile @@ -129,5 +129,5 @@ linkcheck: "or in $(BUILDDIR)/linkcheck/output.txt." doctest: - @echo "Run 'python setup.py test' in the root directory to run doctests " \ + @echo "Run 'pytest' in the root directory to run doctests " \ @echo "in the documentation." diff --git a/docs/conf.py b/docs/conf.py index 42431581..91b31289 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -52,7 +52,7 @@ # List of patterns, relative to source directory, that match files and # directories to ignore when looking for source files. -exclude_patterns.append('_templates') # noqa: F405 +# exclude_patterns.append('_templates') plot_formats = ['png', 'hires.png', 'pdf', 'svg'] @@ -66,9 +66,9 @@ author = project_meta['authors'][0]['name'] copyright = f'2015-{datetime.utcnow().year}, {author}' -# The version info for the project you're documenting, acts as replacement for -# |version| and |release|, also used in various other places throughout the -# built documents. +# The version info for the project you're documenting, acts as +# replacement for |version| and |release|, also used in various other +# places throughout the built documents. __import__(project) package = sys.modules[project] @@ -79,11 +79,11 @@ # -- Options for HTML output -------------------------------------------------- # The global astropy configuration uses a custom theme, -# 'bootstrap-astropy', which is installed along with astropy. A different -# theme can be used or the options for this theme can be modified by -# overriding some of the variables set in the global configuration. The -# variables set in the global configuration are listed below, commented -# out. +# 'bootstrap-astropy', which is installed along with astropy. A +# different theme can be used or the options for this theme can be +# modified by overriding some of the variables set in the global +# configuration. The variables set in the global configuration are +# listed below, commented out. # Add any paths that contain custom themes here, relative to this # directory. @@ -110,8 +110,8 @@ # html_logo = '' # The name of an image file (within the static path) to use as favicon -# of the docs. This file should be a Windows icon file (.ico) being 16x16 -# or 32x32 pixels large. +# of the docs. This file should be a Windows icon file (.ico) being +# 16x16 or 32x32 pixels large. # html_favicon = '' # A "Last built" timestamp is inserted at every page bottom, using the @@ -177,7 +177,6 @@ linkcheck_ignore = ['http://data.astropy.org', r'https://github\.com/astropy/regions/(?:issues|pull)/\d+'] linkcheck_timeout = 180 -linkcheck_anchors = False # -- Matplotlib plot defaults ------------------------------------------------- plot_rcparams = {'savefig.bbox': 'tight', @@ -189,5 +188,4 @@ 'figure.titlesize': 11, 'figure.subplot.wspace': 0.23, 'figure.subplot.hspace': 0.23} - plot_apply_rcparams = True diff --git a/docs/contributing.rst b/docs/contributing.rst index e3bef9f9..118d3a50 100644 --- a/docs/contributing.rst +++ b/docs/contributing.rst @@ -4,43 +4,34 @@ Reporting Issues and Contributing Reporting Issues ---------------- -If you have found a bug in Regions please report it by -creating a new issue on the `Regions GitHub issue tracker +If you have found a bug, please report it by creating +a new issue on the `Regions GitHub issue tracker `_. That requires creating a `free Github account `_ if you do not have one. -Please include an example that demonstrates the issue that will allow -the developers to reproduce and fix the problem. You may also be asked -to provide information about your operating system and a full Python -stack trace. The developers will walk you through obtaining a stack -trace if it is necessary. +Please include an example that demonstrates the issue and will allow the +developers to reproduce and fix the problem. You may be also asked to +provide information about your operating system and a full Python stack +trace. The developers will walk you through obtaining a stack trace if +it is necessary. Contributing ------------ -Like the `Astropy`_ project, Regions is made both by and for its users. -We accept contributions at all levels, spanning the gamut from fixing a -typo in the documentation to developing a major new feature. We welcome -contributors who will abide by the `Python Software Foundation Code of -Conduct `_. +Like the `Astropy`_ project, this package is made both by and for its +users. We accept contributions at all levels, spanning the gamut from +fixing a typo in the documentation to developing a major new feature. We +welcome contributors who will abide by the `Python Software Foundation +Code of Conduct `_. -Regions follows the same workflow and coding guidelines as `Astropy`_. -The following pages will help you get started with contributing fixes, -code, or documentation (no git or GitHub experience necessary): +This package follows the same workflow and coding guidelines as +`Astropy`_. The following pages will help you get started with +contributing fixes, code, or documentation (no git or GitHub experience +necessary): * `How to make a code contribution `_ * `Coding Guidelines `_ -* `Developer Documentation `_ - - -Getting Help ------------- - -Besides GitHub, you can `get help`_ from the community in a number of -ways. There is also a slack channel for Regions hosted under the main -Astropy slack. - -.. _get help: https://www.astropy.org/help.html +* `Developer Documentation `_ diff --git a/docs/make.bat b/docs/make.bat index 93dfe92b..aa930134 100644 --- a/docs/make.bat +++ b/docs/make.bat @@ -37,6 +37,8 @@ if "%1" == "help" ( if "%1" == "clean" ( for /d %%i in (%BUILDDIR%\*) do rmdir /q /s %%i del /q /s %BUILDDIR%\* + del /q /s api + del /q /s generated goto end ) diff --git a/regions/conftest.py b/regions/conftest.py index a7d87d32..c994ecad 100644 --- a/regions/conftest.py +++ b/regions/conftest.py @@ -26,14 +26,10 @@ def pytest_configure(config): # Customize the following lines to add/remove entries from the # list of packages for which version numbers are displayed when # running the tests. - PYTEST_HEADER_MODULES['Cython'] = 'Cython' - PYTEST_HEADER_MODULES['Numpy'] = 'numpy' - PYTEST_HEADER_MODULES['Astropy'] = 'astropy' - PYTEST_HEADER_MODULES['Matplotlib'] = 'matplotlib' - PYTEST_HEADER_MODULES['Shapely'] = 'shapely' - PYTEST_HEADER_MODULES.pop('scipy', None) - PYTEST_HEADER_MODULES.pop('Pandas', None) - PYTEST_HEADER_MODULES.pop('h5py', None) + PYTEST_HEADER_MODULES.clear() + deps = ['NumPy', 'Matplotlib', 'Astropy', 'Shapely'] + for dep in deps: + PYTEST_HEADER_MODULES[dep] = dep.lower() from regions import __version__ TESTED_VERSIONS['regions'] = __version__