From fb9c6ffe665239191430be2cbb06ab077180b75e Mon Sep 17 00:00:00 2001 From: Alexander Popov Date: Sun, 1 Sep 2024 21:56:46 +0300 Subject: [PATCH] Fix style (quotation marks) --- kernel_hardening_checker/engine.py | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/kernel_hardening_checker/engine.py b/kernel_hardening_checker/engine.py index 39f54c5..0627adb 100755 --- a/kernel_hardening_checker/engine.py +++ b/kernel_hardening_checker/engine.py @@ -120,16 +120,16 @@ class OptCheck: def json_dump(self, with_results: bool) -> Dict[str, StrOrBool]: assert(self.opt_type), f'unexpected empty opt_type in {self.name}' dump = { - "option_name": self.name, - "type": self.opt_type, - "desired_val": self.expected, - "decision": self.decision, - "reason": self.reason, + 'option_name': self.name, + 'type': self.opt_type, + 'desired_val': self.expected, + 'decision': self.decision, + 'reason': self.reason, } # type: Dict[str, StrOrBool] if with_results: assert(self.result), f'unexpected empty result in {self.name}' - dump["check_result"] = self.result - dump["check_result_bool"] = self.result.startswith('OK') + dump['check_result'] = self.result + dump['check_result_bool'] = self.result.startswith('OK') return dump @@ -250,8 +250,8 @@ class ComplexOptCheck: if with_results: # Add the 'check_result' and 'check_result_bool' keys to the dictionary assert(self.result), f'unexpected empty result in {self.name}' - dump["check_result"] = self.result - dump["check_result_bool"] = self.result.startswith('OK') + dump['check_result'] = self.result + dump['check_result_bool'] = self.result.startswith('OK') return dump @@ -392,7 +392,7 @@ def override_expected_value(checklist: List[ChecklistObjType], name: str, new_va for opt in checklist: if opt.name == name: assert(isinstance(opt, SimpleNamedOptCheckTypes)), \ - f'overriding an expected value for {opt}" is not supported yet' + f'overriding an expected value for "{opt}" is not supported yet' opt.expected = new_val -- 2.31.1