I have tried that but I was not able to figure out how to make it work. Do 
you have any code examples of something like that being done?

On Friday, 13 January 2023 at 23:33:24 UTC rbel...@google.com wrote:

> You're going very far off road here, but you'd need to write a C extension 
> that instantiates a instance of grpc_socket_mutator 
> <https://github.com/grpc/grpc/blob/41e7aff3be1bfca2b6f1b391abb74cbd859076da/src/core/lib/iomgr/socket_mutator.h#L62>
>  
> that implements the functionality that you want, then put the pointer into 
> a Python int object and pass it as the value in the channel arg.
>
> On Tuesday, January 10, 2023 at 4:06:04 PM UTC-8 Rodrigo Alexandre wrote:
>
>> Hello everyone,
>>
>> I am trying to make a gRPC client to use a specific exit interface.
>> For that, I am setting the value for the "socket_mutator" in the 
>> channel_arguments.
>> I defined a function that takes a socket as an argument and modifies it 
>> however I receive a:
>> *TypeError: Expected int, bytes, or behavior, got <class 'function'>*
>>
>> Does someone know what should I place in the socket_mutator value instead?
>>
>> Thank you for your time.
>>
>

-- 
You received this message because you are subscribed to the Google Groups 
"grpc.io" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to grpc-io+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/grpc-io/2428d783-dbb9-4fad-b283-b988786456fbn%40googlegroups.com.

Reply via email to