Skip to content

Nested projects cause confusing "no package found in source" message #1779

@seth

Description

@seth

A project containing a subdirectory containing a copy of the top-level project fails to build. The message given to the user (with --verbose) is: "no package found in source".

Here's a sample project repo that reproduces the issue:
https://github.com/seth/nested-rust-ex1

I encountered this issue "in the wild" while working on delivery-cli:
https://github.com/chef/delivery-cli
While this may seem super obscure, it is something I hit and I wasn't intentionally trying to created a bogus project structure. What happens is that a build tool (omnibus) creates the nested copy while producing OS packages and leaves it behind.

I think the behavior is somewhat new and that such directories were ignored in previous versions of cargo.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions