Multiple top-level packages discovered in a flat-layout - Vsphere SDK
See original GitHub issueHello,
While in venv during the installation, there is an issue with the Vsphere Automation SDK install. This is also happening if building the docker image and on another system.
Outside of the venv, nothing to report.
Here comes the logs :
Collecting git+https://github.com/vmware/vsphere-automation-sdk-python.git
Cloning https://github.com/vmware/vsphere-automation-sdk-python.git to /tmp/pip-req-build-m46egoho
Running command git clone --filter=blob:none --quiet https://github.com/vmware/vsphere-automation-sdk-python.git /tmp/pip-req-build-m46egoho
Resolved https://github.com/vmware/vsphere-automation-sdk-python.git to commit d8ee747115e2ad7505692723c60765824104e3b7
Preparing metadata (setup.py): started
Preparing metadata (setup.py): finished with status 'error'
error: subprocess-exited-with-error
× python setup.py egg_info did not run successfully.
│ exit code: 1
╰─> [14 lines of output]
error: Multiple top-level packages discovered in a flat-layout: ['lib', 'samples', 'sample_template'].
To avoid accidental inclusion of unwanted files or directories,
setuptools will not proceed with this build.
If you are trying to create a single distribution with multiple packages
on purpose, you should not rely on automatic discovery.
Instead, consider the following options:
1. set up custom discovery (`find` directive with `include` or `exclude`)
2. use a `src-layout`
3. explicitly set `py_modules` or `packages` with a list of names
To find more information, look for "package discovery" on setuptools docs.
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed
× Encountered error while generating package metadata.
╰─> See above for output.
note: This is an issue with the package mentioned above, not pip.
hint: See above for details.
Issue Analytics
- State:
- Created a year ago
- Comments:6 (4 by maintainers)
Top Results From Across the Web
Problem installing the sdk with the latest setuptools version ...
This is happening while to installing the sdk: 1. pip3 install ... error: Multiple top-level packages discovered in a flat-layout: ['lib', ...
Read more >Multiple top-level packages discovered in a flat-layout
In my case specifying packages = ["my_pkg_name"] under [tool.setuptools] in pyproject.toml was the solution (I had another directory at the same ...
Read more >Bug #1966382 “Multiple tripleo jobs are failing because of ...
Multiple tripleo jobs are failing because of "error: Multiple top-level packages discovered in a flat-layout". Bug #1966382 reported by ...
Read more >Getting Started with the vSphere Automation SDK for Python
First things first, clone the vSphere Automation SDK for Python from the VMware GitHub repository located here. Cloning the Python SDK repo.
Read more >getting requirements to build wheel did not run successfully. â ...
Compile : Downloading https://build-artifactory.eng.vmware.com/api/pypi/rdoss- ... #9 539.2 error: Multiple top-level packages discovered in a flat-layout: ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Ahh great, good find. I guess we need to wait until VMware adopted to this behaviour.
There is also an open bug: https://github.com/vmware/vsphere-automation-sdk-python/issues/303
Just tested building the Dockerfile with setuptools locked to 60.10.0 and it worked. Thanks !