The text handler is intended to run whenever destination is a string. Find why this call misses it.
Python
from functools import singledispatch
@singledispatch
def ship(payload, destination):
return f"default:{payload}:{destination}"
@ship.register(str)
def ship_text(payload, destination):
return f"text:{payload}:{destination}"
print(ship(100, "Paris"))