'Check if there is conflict in user selections :attr:`mod_cfg` from a
part specified by :attr:`part_id` in the data file.
.. note:: A conflict may happen while one module selected is declared
in `mutex` word of ano module selected at the same time.
.. note:: This is a `classmethod`.
:param part_id: ID number of a specified part from the hosts data
file.
.. note:: ID number is usually an 8-bit control byte.
.. seealso:: :meth:`~util.retrievedata.get_host`.
:type part_id: int
:param mod_cfg: A 16-bit config word indicating module selections of a
specified part.
.. note::
If modules in specified part whose IDs are `0x0002` and
`0x0010`, the value here should be `0x0002 + 0x0010 = 0x0012`,
which is `0b0000000000000010 + 0b0000000000010000 =
0b0000000000010010` in binary.
:type: int
.. seealso:: :attr:`make_cfg` in
:class:`~tui.curses_d.CursesDaemon` class.
:return: A flag indicating whether there is a conflict or not.
Return  Status
True    Conflict
False   No conflicts
:rtype: bool'

@classmethod
def chk_mutex(cls, part_id, mod_cfg):

    if (part_id == 4):
        return True
    cls._cur.execute('\n                                                SELECT    mod_id,    mutex    FROM    modules\n                                                WHERE    part_id=:part_id;\n                                ', (part_id,))
    mutex_tuple = dict(cls._cur.fetchall())
    mutex_info = []
    mod_info = cls.get_ids(mod_cfg)
    for mod_id in mod_info:
        mutex_info.extend(cls.get_ids(mutex_tuple[mod_id]))
    mutex_info = set(mutex_info)
    for mod_id in mod_info:
        if (mod_id in mutex_info):
            return False
    return True
