Skip to content
This repository has been archived by the owner on Jul 6, 2023. It is now read-only.

Commit

Permalink
fix: Prevent unrelated packages from being installed
Browse files Browse the repository at this point in the history
Currently, packages `tests` and `docs` are installed (because they are discovered as valid packages by `PEP420PackageFinder`), which can break user's code if they also use `test` as a location for their tests, due to package name conflict.
  • Loading branch information
msdinit committed Jun 17, 2021
1 parent cbd94ac commit 7bd1f69
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion setup.py
Expand Up @@ -27,6 +27,8 @@
with io.open(readme_filename, encoding="utf-8") as readme_file:
readme = readme_file.read()

packages = [package for package in setuptools.PEP420PackageFinder.find() if package.startswith('google')]

setuptools.setup(
name="google-cloud-workflows",
version=version,
Expand All @@ -35,7 +37,7 @@
author_email="googleapis-packages@google.com",
license="Apache 2.0",
url="https://github.com/googleapis/python-workflows",
packages=setuptools.PEP420PackageFinder.find(),
packages=packages,
namespace_packages=("google", "google.cloud"),
platforms="Posix; MacOS X; Windows",
include_package_data=True,
Expand Down

0 comments on commit 7bd1f69

Please sign in to comment.