Skip to content

Commit

Permalink
CRAYSAT-1945: Fix traceback error of session checks in CFS v2
Browse files Browse the repository at this point in the history
(cherry picked from commit 7b99f7d)
  • Loading branch information
annapoorna-s-alt committed Dec 18, 2024
1 parent f6208ba commit b97e6e6
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 15 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,12 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [3.33.7] - 2024-12-18

### Fixed
- Fixed the traceback error encountered during session checks in CFS v2
when using a smaller page size.

## [3.33.6] - 2024-12-12

### Added
Expand Down
31 changes: 16 additions & 15 deletions sat/cli/bootsys/service_activity.py
Original file line number Diff line number Diff line change
Expand Up @@ -386,23 +386,24 @@ def get_active_sessions(self):
cfs_client = CFSClientBase.get_cfs_client(SATSession(), get_config_value('cfs.api_version'))
try:
sessions = cfs_client.get_sessions()
except (APIError, ValueError) as err:
raise self.get_err(str(err))

cfs_session_fields = [
self.id_field_name,
'status.session.status',
'status.session.startTime',
'status.session.succeeded',
'status.session.job'
]
cfs_session_fields = [
self.id_field_name,
'status.session.status',
'status.session.startTime',
'status.session.succeeded',
'status.session.job'
]

return [
get_new_ordered_dict(session, cfs_session_fields, MISSING_VALUE)
for session in sessions
# Possible values are 'pending', 'running', or 'complete'
if get_val_by_path(session, 'status.session.status') != 'complete'
]
return [
get_new_ordered_dict(session, cfs_session_fields, MISSING_VALUE)
for session in sessions
# Possible values are 'pending', 'running', or 'complete'
if get_val_by_path(session, 'status.session.status') != 'complete'
]

except APIError as err:
raise self.get_err(str(err))


class FirmwareActivityChecker(ServiceActivityChecker):
Expand Down

0 comments on commit b97e6e6

Please sign in to comment.