def injector(self):
    def decorator_wrapper(*injections):
      not_found = [i for i in injections if i not in self.bean_names]
      if not_found:
          raise InjectionException('Dependencies not found: ' + str(not_found))

      def decorator(method):
        if not inspect.isfunction(method):
          raise InjectionException('Injection works on function only')

        @wraps(method)
        def decorated_method(*args, **kwargs):
          return self.invoke_injected_method(method, injections, *args, **kwargs)

        deps = list(injections)
        deps += getattr(method, '__injected_dependencies__', [])
        deps = list(set(deps))
        setattr(decorated_method, '__injected_dependencies__', deps)
        return decorated_method

      return decorator

    return decorator_wrapper
Trivial implementation of URLFetchService::Fetch().
dataset/ETHPy150Open yegong/stock/utils/injection.py/ApplicationContextBuilder.injector--crossover with--dataset/ETHPy150Open CollabQ/CollabQ/.google_appengine/google/appengine/api/urlfetch_stub.py/URLFetchServiceStub._Dynamic_Fetch