Skip to content

Commit

Permalink
enable long trace by default
Browse files Browse the repository at this point in the history
  • Loading branch information
pierre.delaunay authored and Delaunay committed Jun 14, 2024
1 parent 3577cce commit adc0691
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 15 deletions.
2 changes: 1 addition & 1 deletion milabench/validation/error.py
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ def report_exceptions(self, summary, error, short):
for line in selected.lines:
summary.add(f" | {line}")

def report(self, summary, short=True, **kwargs):
def report(self, summary, short=False, **kwargs):
"""Print an error report and exit with an error code if any error were found"""

failures = 0
Expand Down
11 changes: 5 additions & 6 deletions tests/test_validation.py
Original file line number Diff line number Diff line change
Expand Up @@ -148,11 +148,10 @@ def test_exception_tracking(replayfolder, file_regression, capsys):

from milabench.utils import Summary

summary = Summary()
return_code = error.report(summary, short=False)
summary.show()

assert return_code != 0

# summary = Summary()
# return_code = error.report(summary, short=False)
# summary.show()
# assert return_code != 0

output = capsys.readouterr().out
file_regression.check(output)
8 changes: 0 additions & 8 deletions tests/test_validation/test_exception_tracking.txt
Original file line number Diff line number Diff line change
@@ -1,11 +1,3 @@
opt-1_3b.local
==============
* Error code = 1
* 9 exceptions found
* 7 x ModuleNotFoundError: No module named 'datasets'
* 1 x [2024-06-14 11:36:40,300] torch.distributed.elastic.multiprocessing.api: [ERROR] failed (exitcode: 1) local_rank: 0 (pid: 1078640) of binary: /milabench/milabench_venv/bin/python
* 1 x torch.distributed.elastic.multiprocessing.errors.

opt-1_3b.local
==============
* Error code = 1
Expand Down

0 comments on commit adc0691

Please sign in to comment.