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

[BUG] 71.0.0 missing setuptools\cli-64.exe #4475

Closed
matthuisman opened this issue Jul 17, 2024 · 10 comments · Fixed by #4479
Closed

[BUG] 71.0.0 missing setuptools\cli-64.exe #4475

matthuisman opened this issue Jul 17, 2024 · 10 comments · Fixed by #4479
Assignees
Labels

Comments

@matthuisman
Copy link

setuptools version

setuptools==71.0.0

Python version

Python 3.10

OS

Windows 64 Bit

Additional environment information

No response

Description

trying to editable install a package with console_scripts and getting
error: [Errno 2] No such file or directory: 'C:\Users\mhuisman\Envs\3.10\lib\site-packages\setuptools\cli-64.exe'

reverting to setuptools==70.3.0 fixes the issue

Expected behavior

no error and installs succesfully

How to Reproduce

sorry, the code is close-sourced / work
but i suspect trying to install any setup.py with console_scripts in entry_points will cause the issue

Output

    running egg_info
    writing src\my_test_framework.egg-info\PKG-INFO
    writing dependency_links to src\my_test_framework.egg-info\dependency_links.txt
    writing entry points to src\my_test_framework.egg-info\entry_points.txt
    writing requirements to src\my_test_framework.egg-info\requires.txt
    writing top-level names to src\my_test_framework.egg-info\top_level.txt
    reading manifest file 'src\my_test_framework.egg-info\SOURCES.txt'
    reading manifest template 'MANIFEST.in'
    writing manifest file 'src\my_test_framework.egg-info\SOURCES.txt'
    running build_ext
    Creating c:\users\mhuisman\envs\3.10\lib\site-packages\my-test-framework.egg-link (link to src)
    Adding my-test-framework 2.0.365+5eb0314 to easy-install.pth file
    Installing gui_test_runner-script.py script to C:\Users\mhuisman\Envs\3.10\Scripts
    error: [Errno 2] No such file or directory: 'C:\\Users\\mhuisman\\Envs\\3.10\\lib\\site-packages\\setuptools\\cli-64.exe'
    [end of output]
@matthuisman matthuisman added bug Needs Triage Issues that need to be evaluated for severity and status. labels Jul 17, 2024
@jaraco jaraco self-assigned this Jul 17, 2024
@jaraco jaraco removed the Needs Triage Issues that need to be evaluated for severity and status. label Jul 17, 2024
@jaraco
Copy link
Member

jaraco commented Jul 17, 2024

I suspect the offending commit is fa7ee91. While all it does is add an include, my guess is that its presence causes other package data not to be included.

@jaraco
Copy link
Member

jaraco commented Jul 18, 2024

Confirmed. If I revert that commit, the wheel gets the cli scripts. If I do that, however, setuptools/_vendor/jaraco/text/Lorem ipsum.txt is missing from the wheel.

I don't encounter this kind of fluctuation in other projects because I employ include_package_data=True, but setuptools has that disabled apparently due to #2505.

@jaraco
Copy link
Member

jaraco commented Jul 18, 2024

Re-reading #2505, I see that the main issue was how bloated the wheels where, but it turned out they were bloated by design, primarily because they included new binary artifacts, binary artifacts that are now gone (wininst executables).

Therefore, I'd like to try to re-introduce include_package_data.

@matthuisman
Copy link
Author

[setting this to high priority as requested by my manager] :P

@jaraco
Copy link
Member

jaraco commented Jul 18, 2024

Attempting to restore include_package_data causes two tests to fail (tests designed to check for the exclusion of tests).

_____________________________________________________ TestMeta.test_example_file_not_in_wheel _____________________________________________________
[gw5] darwin -- Python 3.12.4 /Users/jaraco/code/pypa/setuptools/.tox/py/bin/python

self = <setuptools.tests.config.test_apply_pyprojecttoml.TestMeta object at 0x109a9b470>
setuptools_wheel = PosixPath('/private/var/folders/f2/2plv6q2n7l932m2x004jlw340000gn/T/pytest-of-jaraco/pytest-90/dist_build/setuptools-71.0.0.post20240717-py3-none-any.whl')

    def test_example_file_not_in_wheel(self, setuptools_wheel):
        """Meta test to ensure auxiliary test files are not in wheel"""
        with ZipFile(setuptools_wheel) as zipfile:
>           assert not any(name.endswith(EXAMPLES_FILE) for name in zipfile.namelist())
E           AssertionError

setuptools/tests/config/test_apply_pyprojecttoml.py:428: AssertionError
____________________________________________________ test_its_own_wheel_does_not_contain_tests ____________________________________________________
[gw11] darwin -- Python 3.12.4 /Users/jaraco/code/pypa/setuptools/.tox/py/bin/python

setuptools_wheel = PosixPath('/private/var/folders/f2/2plv6q2n7l932m2x004jlw340000gn/T/pytest-of-jaraco/pytest-90/dist_build/setuptools-71.0.0.post20240717-py3-none-any.whl')

    def test_its_own_wheel_does_not_contain_tests(setuptools_wheel):
        with ZipFile(setuptools_wheel) as zipfile:
            contents = [f.replace(os.sep, '/') for f in zipfile.namelist()]
    
        for member in contents:
>           assert '/tests/' not in member
E           AssertionError

/Users/jaraco/code/pypa/setuptools/setuptools/tests/test_setuptools.py:309: AssertionError

jaraco added a commit that referenced this issue Jul 18, 2024
jaraco added a commit that referenced this issue Jul 18, 2024
It's more important to be able to include the important resources than to exclude unwanted ones. Ref #4475.
jaraco added a commit that referenced this issue Jul 18, 2024
It's more important to be able to include the important resources than to exclude unwanted ones. Ref #4475.
@jaraco
Copy link
Member

jaraco commented Jul 18, 2024

I deleted the first test, as it's basically redundant to and covered by the latter test.

I've disabled the second test for now, so we can get a fix out sooner.

@jaraco jaraco mentioned this issue Jul 18, 2024
2 tasks
jaraco added a commit that referenced this issue Jul 18, 2024
It's more important to be able to include the important resources than to exclude unwanted ones. Ref #4475.
@de1acr0ix
Copy link

Perhaps release 71.0.0 shall be retracted from PyPI first, considering the impacts. There are 3 other bugs reported for this release as well...

jaraco added a commit that referenced this issue Jul 18, 2024
It's more important to be able to include the important resources than to exclude unwanted ones. Ref #4475.
@jaraco
Copy link
Member

jaraco commented Jul 18, 2024

Yes, perhaps. Since 71.0.1 with the fix had to be yanked, this issue is once again open.

@jaraco jaraco reopened this Jul 18, 2024
@jaraco
Copy link
Member

jaraco commented Jul 18, 2024

Now that #4485 is removed, this fix should go out with the 71.0.2 release.

@jaraco jaraco closed this as completed Jul 18, 2024
@matthuisman
Copy link
Author

thanks for all your hardwork @jaraco
Id imagine yesterday was pretty stressful!

Hopefully today you can relax :)

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

Successfully merging a pull request may close this issue.

3 participants