The problem is with your syntax, You have to set a callback function for the filechooser this way
def parseChoice(file_paths:list): print('File path ', file_paths[0]) filechooser.open_file(on_selection=parseChoice)