exec
PYL-W0122781 try:
782 result = eval(code)
783 except SyntaxError:
784 exec(785 "async def __aexec(client, message): "
786 + "".join(f"\n {line}" for line in code.split("\n"))
787 )
Usage of exec
function is strongly discouraged, since it opens up possibilities of unauthorized code execution if the statements are not escaped properly. Read more on why should exec
be avoided here.