Skip to content

Commit

Permalink
Fix post-rebase failures
Browse files Browse the repository at this point in the history
  • Loading branch information
vkarak committed Oct 24, 2024
1 parent 50dec2f commit 72b5d36
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
5 changes: 3 additions & 2 deletions reframe/frontend/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -1060,10 +1060,11 @@ def restrict_logging():

for rpt in reports:
uuid = rpt.store()
printer.info(f'Successfully imported session {uuid}')
printer.verbose(f'Successfully imported session {uuid}')

printer.info(f'Successfully imported {len(reports)} sessions')
if not reports:
printer.info('No sessions have been imported')
printer.warning('No sessions have been imported')

sys.exit(0)

Expand Down
8 changes: 4 additions & 4 deletions reframe/frontend/reporting/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,8 @@
from reframe.core.warnings import suppress_deprecations
from reframe.utility import nodelist_abbrev, nodelist_expand, OrderedSet
from .storage import StorageBackend
from .utility import Aggregator, parse_cmp_spec, parse_query_spec
from .utility import (Aggregator, parse_cmp_spec,
parse_query_spec, parse_time_period)

# The schema data version
# Major version bumps are expected to break the validation of previous schemas
Expand Down Expand Up @@ -406,7 +407,7 @@ def create_from_sqlite_db(cls, *dbfiles, exclude_sessions=None,

start = time_period.get('start', '19700101T0000+0000')
end = time_period.get('end', 'now')
ts_start, ts_end = parse_time_period(f'{start}:{end}')
qs = parse_query_spec(f'{start}:{end}')
include_sessions = set(include_sessions) if include_sessions else set()
exclude_sessions = set(exclude_sessions) if exclude_sessions else set()
reports = []
Expand All @@ -420,8 +421,7 @@ def create_from_sqlite_db(cls, *dbfiles, exclude_sessions=None,
)
continue

sessions = src_backend.fetch_sessions_time_period(ts_start, ts_end)
for sess in sessions:
for sess in src_backend.fetch_sessions(qs):
uuid = sess['session_info']['uuid']
if include_sessions and uuid not in include_sessions:
continue
Expand Down

0 comments on commit 72b5d36

Please sign in to comment.