ho un modulo python con una funzione:
def do_stuff(param1 = 'a'):
if type(param1) == int:
# enter python interpreter here
do_something()
else:
do_something_else()
c'è un modo per entrare nell'interprete della riga di comando dove ho il commento? in modo che se eseguo quanto segue in Python:
>>> import my_module
>>> do_stuff(1)
ottengo il mio prossimo prompt nell'ambito e nel contesto in cui ho il commento do_stuff()?