Cannot manage PPAs in Ubuntu/Mint

When trying to add a PPA in terminal error occurs:

Traceback (most recent call last):
File "/usr/lib/linuxmint/mintSources/", line 1455, in <module>
codename = config_parser.get("general", "base_codename")
File "/usr/lib/python2.7/", line 330, in get
raise NoSectionError(section)
ConfigParser.NoSectionError: No section: 'general'

Or trying to access/manage PPAs via GUI similar errors occur or GUI closes the application window. In terminal, run:

sudo /etc/init.d/mintsystem force-reload

If any required part of mintsystem package is missing, run:

sudo apt install mintsystem
mintsystem reload