Skip to content

Commit

Permalink
Fix imports for Sphinx below 6.1
Browse files Browse the repository at this point in the history
  • Loading branch information
AA-Turner committed Jan 7, 2023
1 parent decb84d commit c016b9f
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions sphinxcontrib/applehelp/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -16,19 +16,23 @@
from subprocess import CalledProcessError, PIPE, STDOUT
from typing import Any, Dict

import sphinx
from sphinx.application import Sphinx
from sphinx.builders.html import StandaloneHTMLBuilder
from sphinx.errors import SphinxError
from sphinx.locale import get_translation
from sphinx.util import logging
from sphinx.util import progress_message
from sphinx.util.display import SkipProgressMessage
from sphinx.util.fileutil import copy_asset, copy_asset_file
from sphinx.util.matching import Matcher
from sphinx.util.osutil import ensuredir, make_filename

from sphinxcontrib.applehelp.version import __version__

if sphinx.version_info[:2] >= (6, 1):
from sphinx.util.display import SkipProgressMessage, progress_message
else:
from sphinx.util import SkipProgressMessage, progress_message

package_dir = path.abspath(path.dirname(__file__))
template_dir = path.join(package_dir, 'templates')

Expand Down

0 comments on commit c016b9f

Please sign in to comment.