IndexError: list index out of range

0

I've looked in other questions, and apparently none have the answer, sorry if something is wrong or if you need more information, I'm new.

   def seleciona(self):
    self.posicao = self.mostrar.curselection()
    if self.posicao[0] == '':
        messagebox.showinfo('Alerta','Precisa selecionar musica para tocar')
    else:
        nome = todos[int(self.posicao[0])]
    
asked by anonymous 20.01.2018 / 23:24

0 answers