def save(self):
with open(self.state_file, "<STR_LIT:w>") as fh:<EOL><INDENT>json.dump({<EOL>"<STR_LIT>": self.hosts,<EOL>"<STR_LIT>": self.stats,<EOL>}, fh)<EOL><DEDENT>
Saves the state to the state file