Skip to content

Commit

Permalink
Merge 6c153be into 3816227
Browse files Browse the repository at this point in the history
  • Loading branch information
smarr committed Feb 3, 2023
2 parents 3816227 + 6c153be commit 017e035
Show file tree
Hide file tree
Showing 9 changed files with 11 additions and 11 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/ci.yml
Expand Up @@ -8,15 +8,15 @@ jobs:
strategy:
fail-fast: false
matrix:
python-version: [ '2.7', '3.7', '3.9', 'pypy3.9' ]
python-version: [ '2.7', '3.7', '3.11', 'pypy3.9' ]
yaml-parser: ['', 'ruamel']
include:
- python-version: 2.7
coverage: "--cov=rebench"
exclude:
- python-version: 2.7
yaml-parser: ruamel
- python-version: 3.9
- python-version: 3.11
yaml-parser: ruamel
- python-version: pypy3
yaml-parser: ruamel
Expand Down Expand Up @@ -54,7 +54,7 @@ jobs:
run: |
pip install pylint
pylint rebench
if: matrix.python-version == '3.9'
if: matrix.python-version == '3.11'

- name: Upload coverage results to Coveralls
run: coveralls
Expand Down
2 changes: 1 addition & 1 deletion .pylintrc
Expand Up @@ -482,4 +482,4 @@ known-third-party=enchant

# Exceptions that will emit a warning when being caught. Defaults to
# "Exception"
overgeneral-exceptions=Exception
overgeneral-exceptions=builtins.Exception
2 changes: 1 addition & 1 deletion rebench/configurator.py
Expand Up @@ -98,7 +98,7 @@ def __init__(self, run_filters):
elif parts[0] == "m" and len(parts) == 2:
self._machine_filters.append(_MachineFilter(parts[1]))
else:
raise Exception("Unknown filter expression: " + run_filter)
raise RuntimeError("Unknown filter expression: " + run_filter)

def applies_to_bench(self, bench):
return (self._match(self._executor_filters, bench) and
Expand Down
2 changes: 1 addition & 1 deletion rebench/environment.py
Expand Up @@ -136,4 +136,4 @@ def determine_environment():
if _environment:
return _environment

raise Exception("Environment was not initialized before accessing it.")
raise RuntimeError("Environment was not initialized before accessing it.")
2 changes: 1 addition & 1 deletion rebench/executor.py
Expand Up @@ -67,7 +67,7 @@ def _estimate_time_left(self):
return 0, 0, 0

current = time()
time_per_invocation = ((current - self._start_time) / self._runs_completed)
time_per_invocation = (current - self._start_time) / self._runs_completed
etl = time_per_invocation * (self._total_num_runs - self._runs_completed)
sec = etl % 60
minute = (etl - sec) / 60 % 60
Expand Down
2 changes: 1 addition & 1 deletion rebench/model/profiler.py
Expand Up @@ -16,7 +16,7 @@ def compile(cls, profiler_data):
perf = PerfProfiler(k, v)
profilers.append(perf)
else:
raise Exception("Not yet supported profiler type: " + k)
raise NotImplementedError("Not yet supported profiler type: " + k)
return profilers

def __init__(self, name, gauge_name):
Expand Down
2 changes: 1 addition & 1 deletion rebench/persistence.py
Expand Up @@ -403,7 +403,7 @@ def set_start_time(self, start_time):
self._start_time = start_time

def load_data(self, runs, discard_run_data):
raise Exception("Does not yet support data loading from ReBenchDB")
raise RuntimeError("Does not yet support data loading from ReBenchDB")

def persist_data_point(self, data_point):
with self._lock:
Expand Down
2 changes: 1 addition & 1 deletion rebench/tests/mock_http_server.py
Expand Up @@ -50,7 +50,7 @@ def start(self):
self._server = HTTPServer(('localhost', self._port), _RequestHandler)

self._thread = Thread(target=self._server.serve_forever)
self._thread.setDaemon(True)
self._thread.daemon = True
self._thread.start()

def shutdown(self):
Expand Down
2 changes: 1 addition & 1 deletion rebench/ui.py
Expand Up @@ -214,7 +214,7 @@ def step(self, progress=0, label=None):
assert not self.interactive
label = label or self.label
if not label:
raise Exception("No label set for spinner!")
raise RuntimeError("No label set for spinner!")

if self.total:
label = "%s: %.2f%%\n" % (label, progress / (self.total / 100.0))
Expand Down

0 comments on commit 017e035

Please sign in to comment.