14 """Setup module for the GRPC Python package's optional reflection."""
21 _PACKAGE_PATH = os.path.realpath(os.path.dirname(__file__))
22 _README_PATH = os.path.join(_PACKAGE_PATH,
'README.rst')
25 os.chdir(os.path.dirname(os.path.abspath(__file__)))
31 class _NoOpCommand(setuptools.Command):
48 'Development Status :: 5 - Production/Stable',
49 'Programming Language :: Python',
50 'Programming Language :: Python :: 3',
51 'Programming Language :: Python :: 3.4',
52 'Programming Language :: Python :: 3.5',
53 'Programming Language :: Python :: 3.6',
54 'Programming Language :: Python :: 3.7',
55 'Programming Language :: Python :: 3.8',
56 'Programming Language :: Python :: 3.9',
57 'Programming Language :: Python :: 3.10',
58 'License :: OSI Approved :: Apache Software License',
61 PACKAGE_DIRECTORIES = {
67 'grpcio>={version}'.
format(version=grpc_version.VERSION),
71 import reflection_commands
as _reflection_commands
74 SETUP_REQUIRES = (
'grpcio-tools=={version}'.
format(
75 version=grpc_version.VERSION),)
78 'preprocess': _reflection_commands.Preprocess,
79 'build_package_protos': _reflection_commands.BuildPackageProtos,
85 'preprocess': _NoOpCommand,
86 'build_package_protos': _NoOpCommand,
89 setuptools.setup(name=
'grpcio-reflection',
90 version=grpc_version.VERSION,
91 license=
'Apache License 2.0',
92 description=
'Standard Protobuf Reflection Service for gRPC',
93 long_description=
open(_README_PATH,
'r').
read(),
94 author=
'The gRPC Authors',
95 author_email=
'grpc-io@googlegroups.com',
96 classifiers=CLASSIFIERS,
97 url=
'https://grpc.io',
98 package_dir=PACKAGE_DIRECTORIES,
99 packages=setuptools.find_packages(
'.'),
100 python_requires=
'>=3.6',
101 install_requires=INSTALL_REQUIRES,
102 setup_requires=SETUP_REQUIRES,
103 cmdclass=COMMAND_CLASS)