#SelectMenu in Cog is throwing a missing parameter when done selecting options

1 messages · Page 1 of 1 (latest)

crude light
#

@interactions.component_callback("mySelectMenu")
async def mySelectMenu(self, ctx:interactions.ComponentContext, selected_option:list):

print(selected_option)

Error:

TypeError: AdminPanel.mySelectMenu() missing 1 required positional argument: 'selected_option'

is there anything I'm doing incorrectly here

little patio
#

the error is because your method is expecting a param called selected_option, that the lib isnt passing; you want ctx.values

crude light
#

ahhh v5 tings xD

#

okok

#

thanks mate