code: def __new__(mcs, classname, bases, attrs):
      def make_method(name):
          def method(self, *args, **kwargs):
              obj = object.__getattribute__(self, "_wrapped")
              if obj is None:
                  cb = object.__getattribute__(self, "_callback")
                  obj = cb()
                  object.__setattr__(self, "_wrapped", obj)
  
              # we have to convert the instance to the real type
              if (
                  args
                  and len(args) == 1
                  and (
                      type(args[0]) == LazyEvalWrapper
                      or hasattr(type(args[0]), "_base_class_")
                  )
              ):
                  try:
                      int(args[0])  # force loading the instance
                  except:  # noqa
                      pass
                  args = (object.__getattribute__(args[0], "_wrapped"),)
  
              mtd = getattr(obj, name)
              return mtd(*args, **kwargs)
  
          return method
  
      typed_class = attrs.get("_base_class_")
      for name in mcs._special_names:
          if not typed_class or hasattr(typed_class, name):
              attrs[name] = make_method(name)
  
      overrides = attrs.get("__overrides__", [])
      # overrides.extend(k for k, v in attrs.items() if isinstance(v, lazy))
      attrs["__overrides__"] = overrides
      return type.__new__(mcs, classname, bases, attrs)
  
imports: import itertools
  import json
  from copy import copy
  from logging import getLogger
  import six
  import yaml
label_desc: Use image node_id 1 for calling the WrapperBase obj's underlying member method code with example usage: obj.__new__(mcs, classname, bases, attrs) and returns: type, method, mtd