Skip to content

Commit d7ae2de

Browse files
Revert formatting changes
1 parent 615cbfb commit d7ae2de

File tree

2 files changed

+104
-106
lines changed

2 files changed

+104
-106
lines changed

setup.py

Lines changed: 52 additions & 53 deletions
Original file line numberDiff line numberDiff line change
@@ -21,80 +21,79 @@
2121

2222

2323
if sys.version_info >= (3, 11):
24-
sys.exit("Sorry, Python >= 3.11 is not supported")
24+
sys.exit('Sorry, Python >= 3.11 is not supported')
2525

2626

2727
def select_constraint(default, nightly=None, git_master=None):
28-
"""Select dependency constraint based on TFX_DEPENDENCY_SELECTOR env var."""
29-
selector = os.environ.get("TFX_DEPENDENCY_SELECTOR")
30-
if selector == "UNCONSTRAINED":
31-
return ""
32-
elif selector == "NIGHTLY" and nightly is not None:
33-
return nightly
34-
elif selector == "GIT_MASTER" and git_master is not None:
35-
return git_master
36-
else:
37-
return default
38-
39-
28+
"""Select dependency constraint based on TFX_DEPENDENCY_SELECTOR env var."""
29+
selector = os.environ.get('TFX_DEPENDENCY_SELECTOR')
30+
if selector == 'UNCONSTRAINED':
31+
return ''
32+
elif selector == 'NIGHTLY' and nightly is not None:
33+
return nightly
34+
elif selector == 'GIT_MASTER' and git_master is not None:
35+
return git_master
36+
else:
37+
return default
4038
REQUIRED_PACKAGES = [
41-
"tensorflow>=2.16,<2.17",
42-
"tensorflow-hub>=0.16.1,<1.0.0",
43-
"tensorflow-data-validation>=1.16.1,<2.0.0",
44-
"tensorflow-model-analysis>=0.47.1,<0.48.0",
45-
"witwidget>=1.4.4,<2",
46-
"protobuf>=3.20.3,<5",
39+
'tensorflow>=2.16,<2.17',
40+
'tensorflow-hub>=0.16.1,<1.0.0',
41+
'tensorflow-data-validation>=1.16.1,<2.0.0',
42+
'tensorflow-model-analysis>=0.47.1,<0.48.0',
43+
'witwidget>=1.4.4,<2',
44+
'protobuf>=3.20.3,<5',
4745
]
4846

4947
TEST_PACKAGES = [
50-
"pytest",
48+
'pytest',
5149
]
5250
# Get version from version module.
53-
with open("fairness_indicators/version.py") as fp:
54-
globals_dict = {}
55-
exec(fp.read(), globals_dict) # pylint: disable=exec-used
56-
__version__ = globals_dict["__version__"]
57-
with open("README.md", "r", encoding="utf-8") as fh:
58-
long_description = fh.read()
51+
with open('fairness_indicators/version.py') as fp:
52+
globals_dict = {}
53+
exec(fp.read(), globals_dict) # pylint: disable=exec-used
54+
__version__ = globals_dict['__version__']
55+
with open('README.md', 'r', encoding='utf-8') as fh:
56+
long_description = fh.read()
5957
setuptools.setup(
60-
name="fairness_indicators",
58+
name='fairness_indicators',
6159
version=__version__,
62-
description="Fairness Indicators",
60+
description='Fairness Indicators',
6361
long_description=long_description,
64-
long_description_content_type="text/markdown",
65-
url="https://github.com/tensorflow/fairness-indicators",
66-
author="Google LLC",
67-
author_email="[email protected]",
68-
packages=setuptools.find_packages(exclude=["tensorboard_plugin"]),
62+
long_description_content_type='text/markdown',
63+
url='https://github.com/tensorflow/fairness-indicators',
64+
author='Google LLC',
65+
author_email='[email protected]',
66+
packages=setuptools.find_packages(exclude=['tensorboard_plugin']),
6967
package_data={
70-
"fairness_indicators": ["documentation/*"],
68+
'fairness_indicators': ['documentation/*'],
7169
},
72-
python_requires=">=3.9,<4",
70+
python_requires='>=3.9,<4',
7371
install_requires=REQUIRED_PACKAGES,
7472
tests_require=REQUIRED_PACKAGES,
7573
extras_require={
76-
"test": TEST_PACKAGES,
74+
'test': TEST_PACKAGES,
7775
},
7876
# PyPI package information.
7977
classifiers=[
80-
"Development Status :: 4 - Beta",
81-
"Intended Audience :: Developers",
82-
"Intended Audience :: Education",
83-
"Intended Audience :: Science/Research",
84-
"License :: OSI Approved :: Apache Software License",
85-
"Operating System :: OS Independent",
86-
"Programming Language :: Python :: 3",
87-
"Programming Language :: Python :: 3.9",
88-
"Programming Language :: Python :: 3 :: Only",
89-
"Topic :: Scientific/Engineering",
90-
"Topic :: Scientific/Engineering :: Mathematics",
91-
"Topic :: Scientific/Engineering :: Artificial Intelligence",
92-
"Topic :: Software Development",
93-
"Topic :: Software Development :: Libraries",
94-
"Topic :: Software Development :: Libraries :: Python Modules",
78+
'Development Status :: 4 - Beta',
79+
'Intended Audience :: Developers',
80+
'Intended Audience :: Education',
81+
'Intended Audience :: Science/Research',
82+
'License :: OSI Approved :: Apache Software License',
83+
'Operating System :: OS Independent',
84+
'Programming Language :: Python :: 3',
85+
'Programming Language :: Python :: 3.9',
86+
'Programming Language :: Python :: 3 :: Only',
87+
'Topic :: Scientific/Engineering',
88+
'Topic :: Scientific/Engineering :: Mathematics',
89+
'Topic :: Scientific/Engineering :: Artificial Intelligence',
90+
'Topic :: Software Development',
91+
'Topic :: Software Development :: Libraries',
92+
'Topic :: Software Development :: Libraries :: Python Modules',
9593
],
96-
license="Apache 2.0",
94+
license='Apache 2.0',
9795
keywords=(
98-
"tensorflow model analysis fairness indicators tensorboard machine learning"
96+
'tensorflow model analysis fairness indicators tensorboard machine'
97+
' learning'
9998
),
10099
)

tensorboard_plugin/setup.py

Lines changed: 52 additions & 53 deletions
Original file line numberDiff line numberDiff line change
@@ -26,85 +26,84 @@
2626

2727

2828
if sys.version_info >= (3, 11):
29-
sys.exit("Sorry, Python >= 3.11 is not supported")
29+
sys.exit('Sorry, Python >= 3.11 is not supported')
3030

3131

3232
def select_constraint(default, nightly=None, git_master=None):
33-
"""Select dependency constraint based on TFX_DEPENDENCY_SELECTOR env var."""
34-
selector = os.environ.get("TFX_DEPENDENCY_SELECTOR")
35-
if selector == "UNCONSTRAINED":
36-
return ""
37-
elif selector == "NIGHTLY" and nightly is not None:
38-
return nightly
39-
elif selector == "GIT_MASTER" and git_master is not None:
40-
return git_master
41-
else:
42-
return default
43-
33+
"""Select dependency constraint based on TFX_DEPENDENCY_SELECTOR env var."""
34+
selector = os.environ.get('TFX_DEPENDENCY_SELECTOR')
35+
if selector == 'UNCONSTRAINED':
36+
return ''
37+
elif selector == 'NIGHTLY' and nightly is not None:
38+
return nightly
39+
elif selector == 'GIT_MASTER' and git_master is not None:
40+
return git_master
41+
else:
42+
return default
4443

4544
REQUIRED_PACKAGES = [
46-
"protobuf>=3.20.3,<5",
47-
"tensorboard>=2.16.2,<2.17.0",
48-
"tensorflow>=2.16,<2.17",
49-
"tf-keras>=2.16,<2.17",
50-
"tensorflow-model-analysis>=0.47,<0.48",
51-
"werkzeug<2",
45+
'protobuf>=3.20.3,<5',
46+
'tensorboard>=2.16.2,<2.17.0',
47+
'tensorflow>=2.16,<2.17',
48+
'tf-keras>=2.16,<2.17',
49+
'tensorflow-model-analysis>=0.47,<0.48',
50+
'werkzeug<2',
5251
]
5352

5453
TEST_PACKAGES = [
55-
"pytest",
54+
'pytest',
5655
]
5756

58-
with open("README.md", "r", encoding="utf-8") as fh:
59-
long_description = fh.read()
57+
with open('README.md', 'r', encoding='utf-8') as fh:
58+
long_description = fh.read()
6059

6160
# Get version from version module.
62-
with open("tensorboard_plugin_fairness_indicators/version.py") as fp:
63-
globals_dict = {}
64-
exec(fp.read(), globals_dict) # pylint: disable=exec-used
65-
__version__ = globals_dict["__version__"]
61+
with open('tensorboard_plugin_fairness_indicators/version.py') as fp:
62+
globals_dict = {}
63+
exec(fp.read(), globals_dict) # pylint: disable=exec-used
64+
__version__ = globals_dict['__version__']
6665

6766
setup(
68-
name="tensorboard_plugin_fairness_indicators",
67+
name='tensorboard_plugin_fairness_indicators',
6968
version=__version__,
70-
description="Fairness Indicators TensorBoard Plugin",
69+
description='Fairness Indicators TensorBoard Plugin',
7170
long_description=long_description,
72-
long_description_content_type="text/markdown",
73-
url="https://github.com/tensorflow/fairness-indicators",
74-
author="Google LLC",
75-
author_email="[email protected]",
71+
long_description_content_type='text/markdown',
72+
url='https://github.com/tensorflow/fairness-indicators',
73+
author='Google LLC',
74+
author_email='[email protected]',
7675
packages=find_packages(),
7776
package_data={
78-
"tensorboard_plugin_fairness_indicators": ["static/**"],
77+
'tensorboard_plugin_fairness_indicators': ['static/**'],
7978
},
8079
entry_points={
81-
"tensorboard_plugins": [
82-
"fairness_indicators = tensorboard_plugin_fairness_indicators.plugin:FairnessIndicatorsPlugin",
80+
'tensorboard_plugins': [
81+
'fairness_indicators = tensorboard_plugin_fairness_indicators.plugin:FairnessIndicatorsPlugin',
8382
],
8483
},
85-
python_requires=">=3.9,<4",
84+
python_requires='>=3.9,<4',
8685
install_requires=REQUIRED_PACKAGES,
8786
tests_require=REQUIRED_PACKAGES,
8887
extras_require={
89-
"test": TEST_PACKAGES,
88+
'test': TEST_PACKAGES,
9089
},
9190
classifiers=[
92-
"Development Status :: 4 - Beta",
93-
"Intended Audience :: Developers",
94-
"Intended Audience :: Education",
95-
"Intended Audience :: Science/Research",
96-
"License :: OSI Approved :: Apache Software License",
97-
"Operating System :: OS Independent",
98-
"Programming Language :: Python :: 3",
99-
"Programming Language :: Python :: 3.9",
100-
"Programming Language :: Python :: 3 :: Only",
101-
"Topic :: Scientific/Engineering",
102-
"Topic :: Scientific/Engineering :: Mathematics",
103-
"Topic :: Scientific/Engineering :: Artificial Intelligence",
104-
"Topic :: Software Development",
105-
"Topic :: Software Development :: Libraries",
106-
"Topic :: Software Development :: Libraries :: Python Modules",
91+
'Development Status :: 4 - Beta',
92+
'Intended Audience :: Developers',
93+
'Intended Audience :: Education',
94+
'Intended Audience :: Science/Research',
95+
'License :: OSI Approved :: Apache Software License',
96+
'Operating System :: OS Independent',
97+
'Programming Language :: Python :: 3',
98+
'Programming Language :: Python :: 3.9',
99+
'Programming Language :: Python :: 3 :: Only',
100+
'Topic :: Scientific/Engineering',
101+
'Topic :: Scientific/Engineering :: Mathematics',
102+
'Topic :: Scientific/Engineering :: Artificial Intelligence',
103+
'Topic :: Software Development',
104+
'Topic :: Software Development :: Libraries',
105+
'Topic :: Software Development :: Libraries :: Python Modules',
107106
],
108-
license="Apache 2.0",
109-
keywords="tensorflow model analysis fairness indicators tensorboard machine learning",
107+
license='Apache 2.0',
108+
keywords='tensorflow model analysis fairness indicators tensorboard machine learning',
110109
)

0 commit comments

Comments
 (0)