code: def enable_yum_priority_obsoletes(path="/etc/yum/pluginconf.d/priorities.conf"):
      
      config = configparser.ConfigParser()
      config.read(path)
      config.set('main', 'check_obsoletes', '1')
      with open(path, 'w') as fout:
          config.write(fout)
docs: Configure Yum priorities to include obsoletes