@@ -757,7 +757,6 @@ def patched_getattribute(obj, key, *args, **kwargs):
757757 return orig_getattribute (obj , key , * args , ** kwargs )
758758
759759 attr = orig_getattribute (obj , key , * args , ** kwargs )
760- print ("args" , args , "attr.dir" , dir (attr ))
761760
762761 # 0. If we already patched it, we can return immediately.
763762 if getattr (attr , "_patched" , None ) is not None :
@@ -772,22 +771,18 @@ def patched_getattribute(obj, key, *args, **kwargs):
772771 if mangled_or_private :
773772 return attr
774773
775- print ("\033 [35mattr" , attr , "hex_id" , hex (id (attr )), "\033 [00m" )
776-
777774 # 3. Wrap the callable attribute and then capture its metadata keyed argument.
778775 def wrapped_attr (* args , ** kwargs ):
779776 metadata = kwargs .get ("metadata" , [])
780777 if not metadata :
781778 # Increment the reinvocation count.
782- print ("not metatadata" , attr .__name__ )
783779 wrapped_attr ._attempt += 1
784780 return attr (* args , ** kwargs )
785781
786782 # 4. Find all the headers that match the target header key.
787783 all_metadata = []
788784 for key , value in metadata :
789785 if key is REQ_ID_HEADER_KEY :
790- print ("key" , key , "value" , value , "attempt" , wrapped_attr ._attempt )
791786 # 5. Increment the original_attempt with that of our re-invocation count.
792787 splits = value .split ("." )
793788 hdr_attempt_plus_reinvocation = (
@@ -802,7 +797,6 @@ def wrapped_attr(*args, **kwargs):
802797 wrapped_attr ._attempt += 1
803798
804799 kwargs ["metadata" ] = all_metadata
805- print ("\033 [34mwrap_callable" , hex (id (attr )), attr .__name__ , "\033 [00m" )
806800 return attr (* args , ** kwargs )
807801
808802 wrapped_attr ._attempt = 0
0 commit comments