[to #43554786]fix: test error is not detected in gate test, protobuf version to (3, 3.21.0) for tensorflow

限制protobuf版本,修复单元测试有error返回值为0问题
        Link: https://code.alibaba-inc.com/Ali-MaaS/MaaS-lib/codereview/9510263

    * fix test error is not detected in gate test, protobuf version to (3, 3.21.0)
This commit is contained in:
mulin.lyh
2022-07-26 10:57:16 +08:00
parent 321292ceda
commit fc90bf0d1a
3 changed files with 5 additions and 5 deletions

View File

@@ -9,8 +9,8 @@ lxml
matplotlib
nara_wpe
numpy<=1.18
# tested on version before 3.20, expecting no breaking change going forward
protobuf>3
# protobuf version beyond 3.20.0 is not compatible with TensorFlow 1.x, therefore is discouraged.
protobuf>3,<3.21.0
ptflops
pytorch_wavelets
PyWavelets>=1.0.0

View File

@@ -6,8 +6,6 @@ filelock>=3.3.0
numpy
opencv-python
Pillow>=6.2.0
# tested on version before 3.20, expecting no breaking change going forward
protobuf>3
pyyaml
requests
scipy

View File

@@ -49,7 +49,9 @@ def main(args):
if not args.list_tests:
result = runner.run(test_suite)
if len(result.failures) > 0:
sys.exit(1)
sys.exit(len(result.failures))
if len(result.errors) > 0:
sys.exit(len(result.errors))
if __name__ == '__main__':