Skip to content

Commit

Permalink
Update to CMake 3.25.0 (#12)
Browse files Browse the repository at this point in the history
Signed-off-by: Henry Schreiner <henryschreineriii@gmail.com>

Signed-off-by: Henry Schreiner <henryschreineriii@gmail.com>
  • Loading branch information
henryiii authored Nov 16, 2022
1 parent 9d9a0e3 commit 9d267a2
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 13 deletions.
2 changes: 1 addition & 1 deletion sphinxcontrib/moderncmakedomain/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@

from .cmake import setup

__version__ = "3.24.2"
__version__ = "3.25.0"
18 changes: 6 additions & 12 deletions sphinxcontrib/moderncmakedomain/cmake.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,12 +59,6 @@

from docutils.parsers.rst import Directive, directives
from docutils.transforms import Transform
try:
from docutils.utils.error_reporting import SafeString, ErrorString
except ImportError:
# error_reporting was not in utils before version 0.11:
from docutils.error_reporting import SafeString, ErrorString

from docutils import io, nodes

from sphinx.directives import ObjectDescription
Expand Down Expand Up @@ -130,13 +124,13 @@ def run(self):
f = io.FileInput(source_path=path, encoding=encoding,
error_handler=e_handler)
except UnicodeEncodeError as error:
raise self.severe('Problems with "%s" directive path:\n'
'Cannot encode input file path "%s" '
'(wrong locale?).' %
(self.name, SafeString(path)))
msg = ('Problems with "%s" directive path:\n'
'Cannot encode input file path "%s" '
'(wrong locale?).' % (self.name, path))
raise self.severe(msg)
except IOError as error:
raise self.severe('Problems with "%s" directive path:\n%s.' %
(self.name, ErrorString(error)))
msg = 'Problems with "%s" directive path:\n%s.' % (self.name, error)
raise self.severe(msg)
raw_lines = f.read().splitlines()
f.close()
rst = None
Expand Down

1 comment on commit 9d267a2

@kloczek
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

issue tracker is not enabled so I'll drop found issue here.
Despite move from setuptools to hatchling `seruptools still is used in test suite

+ PYTHONPATH=/home/tkloczko/rpmbuild/BUILDROOT/python-sphinxcontrib-moderncmakedomain-3.25.0-2.fc35.x86_64/usr/lib64/python3.8/site-packages:/home/tkloczko/rpmbuild/BUILDROOT/python-sphinxcontrib-moderncmakedomain-3.25.0-2.fc35.x86_64/usr/lib/python3.8/site-packages
+ /usr/bin/pytest -ra --exit-0-if-no-units
=========================================================================== test session starts ============================================================================
platform linux -- Python 3.8.15, pytest-7.1.3, pluggy-1.0.0
rootdir: /home/tkloczko/rpmbuild/BUILD/moderncmakedomain-3.25.0
collected 0 items / 1 error

================================================================================== ERRORS ==================================================================================
__________________________________________________________________ ERROR collecting tests/test_version.py __________________________________________________________________
ImportError while importing test module '/home/tkloczko/rpmbuild/BUILD/moderncmakedomain-3.25.0/tests/test_version.py'.
Hint: make sure your test modules/packages have valid Python names.
Traceback:
/usr/lib64/python3.8/importlib/__init__.py:127: in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
tests/test_version.py:2: in <module>
    from sphinxcontrib.moderncmakedomain import __version__
../../BUILDROOT/python-sphinxcontrib-moderncmakedomain-3.25.0-2.fc35.x86_64/usr/lib/python3.8/site-packages/sphinxcontrib/moderncmakedomain/__init__.py:1: in <module>
    __import__('pkg_resources').declare_namespace(__name__)
E   ModuleNotFoundError: No module named 'pkg_resources'
========================================================================= short test summary info ==========================================================================
ERROR tests/test_version.py
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! Interrupted: 1 error during collection !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
============================================================================= 1 error in 0.06s =============================================================================

pkg_resources is part of the setuptools. You should have look on to https://github.com/python/importlib_metadata/issues/378 shich contains description about how to move from pkg_resourcestoimportlib-metadata`.

PS. Really it would be good to enable issue tracker for this repo.

Please sign in to comment.