Sindbad~EG File Manager

Current Path : /proc/thread-self/root/proc/thread-self/root/opt/imunify360/venv/lib/python3.11/site-packages/defence360agent/internals/
Upload File :
Current File : //proc/thread-self/root/proc/thread-self/root/opt/imunify360/venv/lib/python3.11/site-packages/defence360agent/internals/global_scope.py

import logging

logger = logging.getLogger(__name__)


class GlobalScope(dict):
    def __getattr__(self, item):
        try:
            return self[item]
        except KeyError as err:
            raise AttributeError(f"{item} is not in global scope") from err

    def __setattr__(self, key, value):
        if key in self:
            logger.warning("Name %s is already in global scope", key)
        else:
            self[key] = value


g = GlobalScope()

Sindbad File Manager Version 1.0, Coded By Sindbad EG ~ The Terrorists