Skip to content

macOS wheel builds broken because of find_sources test failure #10073

Closed

Description

@JukkaL

macOS wheel builds are broken because of a test failure:

...
        files = {
            "pkg/a1/b/c/d/e.py",
            "pkg/a1/b/f.py",
            "pkg/a2/__init__.py",
            "pkg/a2/b/c/d/e.py",
            "pkg/a2/b/f.py",
        }
        fscache = FakeFSCache(files)
>       assert len(find_sources(["/"], options, fscache)) == len(files)

site-packages/mypy/test/test_find_sources.py:363: 
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 
site-packages/mypy/test/test_find_sources.py:59: in find_sources
    return normalise_build_source_list(create_source_list(paths, options, fscache))
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ 

>   ???
E   mypy.find_sources.InvalidSourceList: There are no .py[i] files in directory '/'

This is blocking the 0.810 release #10062.

Activity

  1. JukkaL commented on Feb 11, 2021

    @JukkaL
    CollaboratorAuthor

    Actually it's unclear if this is failing on the 0.810 release branch. If it's only failing on master, this doesn't block the 0.810 release.

  2. self-assigned this
    on Feb 11, 2021
  3. JukkaL commented on Feb 11, 2021

    @JukkaL
    CollaboratorAuthor

    Yes, this is failing on the 0.810 release branch, as I feared originally. I'm working on a fix.

  4. JukkaL commented on Feb 11, 2021

    @JukkaL
    CollaboratorAuthor

    The wheel build is still failing. I have another attempt being built, but at least if it doesn't work, I'll probably have to postpone until the next week.

  5. hauntsaninja commented on Feb 11, 2021

    @hauntsaninja
    Collaborator

    Sorry for the trouble, I'm optimistic #10077 would fix.

  6. hauntsaninja commented on Feb 11, 2021

    @hauntsaninja
    Collaborator

    Your fix seems to have worked... But maybe we should change the logic a little:

    subpath_str = os.path.abspath(subpath).replace(os.sep, "/")

    We currently normalise the path for the purposes of --exclude using abspath, but maybe we should use relpath. This would make the behaviour more consistent across possible project locations (assuming that you run mypy from within the project)

  7. hauntsaninja commented on Feb 11, 2021

    @hauntsaninja
    Collaborator

    I opened a PR in case you think using relpath is better: #10078

  8. JukkaL commented on Feb 15, 2021

    @JukkaL
    CollaboratorAuthor

    @hauntsaninja Thanks, the macOS wheel builds work now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions