pickled_arguments = pickle.dumps(your_function.__defaults__)
pickled_closure = pickle.dumps(your_function.__closure__)
send_through_a_socket((marshaled_bytecode, pickled_name, pickled_arguments,
    pickled_closure))
We need to pickle any sort of callable