    def _apply_overrides(self, spawner_override: dict):
        """
        Apply set of overrides onto the current spawner instance

        spawner_override is a dict with key being the name of the traitlet
        to override, and value is either a callable or the value for the
        traitlet. If the value is a dictionary, it is *merged* with the
        existing value (rather than replaced). Callables are called with
        one parameter - the current spawner instance.
        """
        for k, v in spawner_override.items():
            if callable(v):
                v = v(self)

            # If v is a dict, *merge* it with existing values, rather than completely
            # resetting it. This allows *adding* things like environment variables rather
            # than completely replacing them. If value is set to None, the key
            # will be removed
            if isinstance(v, dict) and isinstance(getattr(self, k), dict):
                recursive_update(getattr(self, k), v)
            else:
                setattr(self, k, v)
Apply set of overrides onto the current spawner instance

spawner_override is a dict with key being the name of the traitlet
to override, and value is either a callable or the value for the
traitlet. If the value is a dictionary, it is *merged* with the
existing value (rather than replaced). Callables are called with
one parameter - the current spawner instance.
jupyterhub/spawner.py