def _replacements_init(self):
        """
        Initiate and check any replacements set
        """
        replacements = getattr(self._py3status_module, "replacements", [])
        self._replacements = {}

        if isinstance(replacements, list):
            self._replacements[None] = [
                (re.compile(x[0], re.IGNORECASE), x[1]) for x in replacements
            ]

        elif isinstance(replacements, dict):
            for key, value in replacements.items():
                if isinstance(value, list):
                    self._replacements[key] = [
                        (re.compile(x[0], re.IGNORECASE), x[1]) for x in value
                    ]

        Initiate and check any replacements set
        
py3status/py3.py