code: def save(self):
          
          try:
              # ensure file is encoded properly while saving
              self.project.main_file.encoding = 'utf_8'
              self.project.save_main()
              if self.fix:
                  LOGGER.info("Saved changes to '%s'", self.filename)
          except:  # pylint: disable=W0702
              LOGGER.error("Unable to save '%s'", self.filename)
              sys.exit(1)
docs: Save subtitle file.