Skip to content

Commit

Permalink
still trying to debug the 'install' CI
Browse files Browse the repository at this point in the history
  • Loading branch information
BDonnot committed Jan 25, 2024
1 parent ba7d842 commit 0c9cf57
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 18 deletions.
18 changes: 9 additions & 9 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ jobs:
- run:
command: |
source venv_test/bin/activate
python -m pip install -U "numpy>=1.20,<1.21" pandas "scipy<1.12" numba .[test]
python -m pip install -U "numpy>=1.20,<1.21" "pandas<2.2" "scipy<1.12" numba .[test]
pip freeze
- run:
command: |
Expand All @@ -151,7 +151,7 @@ jobs:
- run:
command: |
source venv_test/bin/activate
python -m pip install -U "numpy>=1.24,<1.25" pandas "scipy<1.12" numba
python -m pip install -U "numpy>=1.24,<1.25" "pandas<2.2" "scipy<1.12" numba
python -m pip install -U .[test]
- run:
command: |
Expand Down Expand Up @@ -185,7 +185,7 @@ jobs:
- run:
command: |
source venv_test/bin/activate
python -m pip install -U "numpy>=1.20,<1.21" pandas "scipy<1.12" numba .[test]
python -m pip install -U "numpy>=1.20,<1.21" "pandas<2.2" "scipy<1.12" numba .[test]
pip freeze
- run:
command: |
Expand All @@ -196,7 +196,7 @@ jobs:
- run:
command: |
source venv_test/bin/activate
python -m pip install -U "numpy>=1.26,<1.27" pandas "scipy<1.12" numba .[test]
python -m pip install -U "numpy>=1.26,<1.27" "pandas<2.2" "scipy<1.12" numba .[test]
pip freeze
- run:
command: |
Expand Down Expand Up @@ -224,7 +224,7 @@ jobs:
- run:
command: |
source venv_test/bin/activate
python -m pip install -U "numpy>=1.21,<1.22" pandas "scipy<1.12" numba .[test]
python -m pip install -U "numpy>=1.21,<1.22" "pandas<2.2" "scipy<1.12" numba .[test]
pip freeze
- run:
command: |
Expand All @@ -235,7 +235,7 @@ jobs:
- run:
command: |
source venv_test/bin/activate
python -m pip install -U "numpy>=1.26,<1.27" pandas "scipy<1.12" numba .[test]
python -m pip install -U "numpy>=1.26,<1.27" "pandas<2.2" "scipy<1.12" numba .[test]
pip freeze
- run:
command: |
Expand All @@ -262,7 +262,7 @@ jobs:
- run:
command: |
source venv_test/bin/activate
python -m pip install -U "numpy>=1.23,<1.24" pandas "scipy<1.12" numba .[test]
python -m pip install -U "numpy>=1.23,<1.24" "pandas<2.2" "scipy<1.12" numba .[test]
pip freeze
- run:
command: |
Expand All @@ -273,7 +273,7 @@ jobs:
- run:
command: |
source venv_test/bin/activate
python -m pip install -U "numpy>=1.26,<1.27" pandas "scipy<1.12" numba .[test]
python -m pip install -U "numpy>=1.26,<1.27" "pandas<2.2" "scipy<1.12" numba .[test]
pip freeze
- run:
command: |
Expand All @@ -300,7 +300,7 @@ jobs:
- run:
command: |
source venv_test/bin/activate
python -m pip install -U "numpy>=1.26,<1.27" pandas "scipy<1.12" .[test]
python -m pip install -U "numpy>=1.26,<1.27" "pandas<2.2" "scipy<1.12" .[test]
pip freeze
- run:
command: |
Expand Down
21 changes: 12 additions & 9 deletions grid2op/command_line.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,21 +77,24 @@ def testinstall():
)
)

def fun(*args, **kwargs):
sys.stderr.write(*args, **kwargs)
def fun(first=None, *args, **kwargs):
if first is not None:
sys.stderr.write(first, *args, **kwargs)
sys.stderr.write("\n")
sys.stderr.writeln = fun
results = unittest.TextTestResult(stream=sys.stderr,
descriptions=True,
verbosity=2)
test_suite.run(results)
if results.wasSuccessful():
sys.exit(0)
return 0
else:
for _, str_ in results.errors:
print(str_)
print("-------------------------\n")
for _, str_ in results.failures:
print(str_)
print("-------------------------\n")
print("\n")
results.printErrors()
# for _, str_ in results.errors:
# print(str_)
# print("-------------------------\n")
# for _, str_ in results.failures:
# print(str_)
# print("-------------------------\n")
raise RuntimeError("Test not successful !")

0 comments on commit 0c9cf57

Please sign in to comment.