Skip to content
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

fix: setuptools is unbundled on Gentoo #1864

Merged
merged 2 commits into from Apr 7, 2023
Merged

fix: setuptools is unbundled on Gentoo #1864

merged 2 commits into from Apr 7, 2023

Conversation

marcelotduarte
Copy link
Owner

Fixes #1863

Copy link

@mgorny mgorny left a comment

Choose a reason for hiding this comment

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

Thank you. I've applied the patch on top of 6.14.8 and I've confirmed that it fixes the import errors on Gentoo. I still get two test failures that I suspect are related to newer setuptools version but that's a separate problem (and possibly one already fixed in git, I haven't checked).

ci/requirements.py Show resolved Hide resolved
@marcelotduarte
Copy link
Owner Author

@mgorny On top of 6.14.8 tests/test_winversioninfo.py should be fixed. Then the tests passed with warnings.


============================================================= warnings summary =============================================================
../../.local/venv/cx310/lib/python3.10/site-packages/pkg_resources/__init__.py:121
  /home/marcelo/.local/venv/cx310/lib/python3.10/site-packages/pkg_resources/__init__.py:121: DeprecationWarning: pkg_resources is deprecated as an API
    warnings.warn("pkg_resources is deprecated as an API", DeprecationWarning)

../../.local/venv/cx310/lib/python3.10/site-packages/pkg_resources/__init__.py:2870
../../.local/venv/cx310/lib/python3.10/site-packages/pkg_resources/__init__.py:2870
../../.local/venv/cx310/lib/python3.10/site-packages/pkg_resources/__init__.py:2870
../../.local/venv/cx310/lib/python3.10/site-packages/pkg_resources/__init__.py:2870
  /home/marcelo/.local/venv/cx310/lib/python3.10/site-packages/pkg_resources/__init__.py:2870: DeprecationWarning: Deprecated call to `pkg_resources.declare_namespace('sphinxcontrib')`.
  Implementing implicit namespace packages (as specified in PEP 420) is preferred to `pkg_resources.declare_namespace`. See https://setuptools.pypa.io/en/latest/references/keywords.html#keyword-namespace-packages
    declare_namespace(pkg)

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html
========================================================= short test summary info ==========================================================
SKIPPED [1] tests/test_command_bdist_msi.py:25: Windows tests
SKIPPED [1] tests/test_command_bdist_msi.py:44: Windows tests
SKIPPED [1] tests/test_command_bdist_msi.py:57: Windows tests
SKIPPED [1] tests/test_command_bdist_msi.py:70: Windows tests
SKIPPED [1] tests/test_winmsvcr.py:12: Windows tests
SKIPPED [1] tests/test_winversioninfo.py:17: Windows tests
SKIPPED [1] tests/test_winversioninfo.py:34: Windows tests
SKIPPED [1] tests/test_winversioninfo.py:44: Windows tests
SKIPPED [1] tests/samples/plist_items/test_plist_items.py:14: Macos tests
================================================ 13 passed, 9 skipped, 5 warnings in 21.06s ================================================

The warning are removed in main branch.

@marcelotduarte
Copy link
Owner Author

@mgorny
Copy link

mgorny commented Apr 6, 2023

What I'm seeing is:

FAILED tests/test_command_build.py::test_build - TypeError: ConfigError.__init__() missing 1 required positional argument: 'msg'
FAILED tests/test_command_build_exe.py::test_build_exe - TypeError: ConfigError.__init__() missing 1 required positional argument: 'msg'

Full log (1.7M):
dev-python:cx_Freeze-6.14.8:20230406-141948.log

@marcelotduarte
Copy link
Owner Author

marcelotduarte commented Apr 7, 2023

This two errors occurs because cx_Freeze is not installed. Run this command before pytest:
pip install -e . --no-build-isolation --no-deps

I tested with docker image gentoo/stage3

To test the bdist_rpm install rpmbuild:
emerge --ask app-arch/rpm

Wow, the are no binaries on Gentoo. Compilation of source code all the time ;-)

@marcelotduarte marcelotduarte merged commit 1009039 into main Apr 7, 2023
19 checks passed
@marcelotduarte marcelotduarte deleted the setuptools branch April 7, 2023 03:39
@mgorny
Copy link

mgorny commented Apr 8, 2023

Thanks. We're running the test suite as part of the ebuild, i.e. as part of emerge -v dev-python/cx_Freeze — but I'll recheck and investigate once the next release is out.

@mgorny
Copy link

mgorny commented Apr 9, 2023

Thanks, again. It works now ;-).

I have also figured out our test failure — pytest was importing cx_Freeze from the current directory instead of the installed version.

@marcelotduarte
Copy link
Owner Author

Good. You're welcome.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Please provide support for non-setuptools.extern bundled packages
2 participants