Não consigo me conectar ao banco de dados, o seguinte erro acontece:
{ Error: ER_NOT_SUPPORTED_AUTH_MODE: Client does not support authentication protocol requested by server; consider upgrading MySQL client
at Handshake.Sequence._packetToError (C:\Users\pedro\casadocodigo\node_modules\mysql\lib\protocol\sequences\Sequence.js:47:14)
at Handshake.ErrorPacket (C:\Users\pedro\casadocodigo\node_modules\mysql\lib\protocol\sequences\Handshake.js:124:18)
at Protocol._parsePacket (C:\Users\pedro\casadocodigo\node_modules\mysql\lib\protocol\Protocol.js:278:23)
at Parser.write (C:\Users\pedro\casadocodigo\node_modules\mysql\lib\protocol\Parser.js:76:12)
at Protocol.write (C:\Users\pedro\casadocodigo\node_modules\mysql\lib\protocol\Protocol.js:38:16)
at Socket.<anonymous> (C:\Users\pedro\casadocodigo\node_modules\mysql\lib\Connection.js:91:28)
at Socket.<anonymous> (C:\Users\pedro\casadocodigo\node_modules\mysql\lib\Connection.js:502:10)
at emitOne (events.js:116:13)
at Socket.emit (events.js:211:7)
at addChunk (_stream_readable.js:263:12)
--------------------
at Protocol._enqueue (C:\Users\pedro\casadocodigo\node_modules\mysql\lib\protocol\Protocol.js:144:48)
at Protocol.handshake (C:\Users\pedro\casadocodigo\node_modules\mysql\lib\protocol\Protocol.js:51:23)
at Connection.connect (C:\Users\pedro\casadocodigo\node_modules\mysql\lib\Connection.js:118:18)
at Connection._implyConnect (C:\Users\pedro\casadocodigo\node_modules\mysql\lib\Connection.js:453:10)
at Connection.query (C:\Users\pedro\casadocodigo\node_modules\mysql\lib\Connection.js:198:8)
at C:\Users\pedro\casadocodigo\app\routes\produtos.js:14:20
at Layer.handle [as handle_request] (C:\Users\pedro\casadocodigo\node_modules\express\lib\router\layer.js:95:5)
at next (C:\Users\pedro\casadocodigo\node_modules\express\lib\router\route.js:137:13)
at Route.dispatch (C:\Users\pedro\casadocodigo\node_modules\express\lib\router\route.js:112:3)
at Layer.handle [as handle_request] (C:\Users\pedro\casadocodigo\node_modules\express\lib\router\layer.js:95:5)
code: 'ER_NOT_SUPPORTED_AUTH_MODE',
errno: 1251,
sqlMessage: 'Client does not support authentication protocol requested by server; consider upgrading MySQL client',
sqlState: '08004',
fatal: true }
{ Error: ER_NOT_SUPPORTED_AUTH_MODE: Client does not support authentication protocol requested by server; consider upgrading MySQL client
at Handshake.Sequence._packetToError (C:\Users\pedro\casadocodigo\node_modules\mysql\lib\protocol\sequences\Sequence.js:47:14)
at Handshake.ErrorPacket (C:\Users\pedro\casadocodigo\node_modules\mysql\lib\protocol\sequences\Handshake.js:124:18)
at Protocol._parsePacket (C:\Users\pedro\casadocodigo\node_modules\mysql\lib\protocol\Protocol.js:278:23)
at Parser.write (C:\Users\pedro\casadocodigo\node_modules\mysql\lib\protocol\Parser.js:76:12)
at Protocol.write (C:\Users\pedro\casadocodigo\node_modules\mysql\lib\protocol\Protocol.js:38:16)
at Socket.<anonymous> (C:\Users\pedro\casadocodigo\node_modules\mysql\lib\Connection.js:91:28)
at Socket.<anonymous> (C:\Users\pedro\casadocodigo\node_modules\mysql\lib\Connection.js:502:10)
at emitOne (events.js:116:13)
at Socket.emit (events.js:211:7)
at addChunk (_stream_readable.js:263:12)
--------------------
at Protocol._enqueue (C:\Users\pedro\casadocodigo\node_modules\mysql\lib\protocol\Protocol.js:144:48)
at Protocol.handshake (C:\Users\pedro\casadocodigo\node_modules\mysql\lib\protocol\Protocol.js:51:23)
at Connection.connect (C:\Users\pedro\casadocodigo\node_modules\mysql\lib\Connection.js:118:18)
at Connection._implyConnect (C:\Users\pedro\casadocodigo\node_modules\mysql\lib\Connection.js:453:10)
at Connection.query (C:\Users\pedro\casadocodigo\node_modules\mysql\lib\Connection.js:198:8)
at C:\Users\pedro\casadocodigo\app\routes\produtos.js:14:20
at Layer.handle [as handle_request] (C:\Users\pedro\casadocodigo\node_modules\express\lib\router\layer.js:95:5)
at next (C:\Users\pedro\casadocodigo\node_modules\express\lib\router\route.js:137:13)
at Route.dispatch (C:\Users\pedro\casadocodigo\node_modules\express\lib\router\route.js:112:3)
at Layer.handle [as handle_request] (C:\Users\pedro\casadocodigo\node_modules\express\lib\router\layer.js:95:5)
code: 'ER_NOT_SUPPORTED_AUTH_MODE',
errno: 1251,
sqlMessage: 'Client does not support authentication protocol requested by server; consider upgrading MySQL client',
sqlState: '08004',
fatal: true }
Tentei usar o script desse tópico https://cursos.alura.com.br/forum/topico-erro-ao-conectar-com-o-banco-de-dados-63602 no MySQL worckbench 8.0 ce mas dá erro de sintaxe (Não sei usar no prompt).