lickm3
DFDimensional Fun
•Created by lickm3 on 6/7/2023 in #lavaclient
Nodes
I know its can sounds dump, but I never really worked with this part of discord bot developing and I started with lavaclient yesterday 😄
3 replies
DFDimensional Fun
•Created by lickm3 on 6/6/2023 in #lavaclient
nodeTrackStart and nodeQueueFinish is not assignable to parameter of type 'keyof ClusterEvents'.
Looks like its worked. Thanks for your time!
35 replies
DFDimensional Fun
•Created by lickm3 on 6/6/2023 in #lavaclient
nodeTrackStart and nodeQueueFinish is not assignable to parameter of type 'keyof ClusterEvents'.
Error: Cannot find module '@lavaclient/spotify'
Require stack:
- C:\Users\vitga\Desktop\workspace\DendaZMehoSklepa\dendazmehosklepa\build\handlers\lavaclient.js
- C:\Users\vitga\Desktop\workspace\DendaZMehoSklepa\dendazmehosklepa\build\client\Client.js
- C:\Users\vitga\Desktop\workspace\DendaZMehoSklepa\dendazmehosklepa\build\index.js
at Module._resolveFilename (node:internal/modules/cjs/loader:1075:15)
at Module._load (node:internal/modules/cjs/loader:920:27)
at Module.require (node:internal/modules/cjs/loader:1141:19)
at require (node:internal/modules/cjs/helpers:110:18)
at Object.<anonymous> (C:\Users\vitga\Desktop\workspace\DendaZMehoSklepa\dendazmehosklepa\build\handlers\lavaclient.js:6:35)
at Module._compile (node:internal/modules/cjs/loader:1254:14)
at Module._extensions..js (node:internal/modules/cjs/loader:1308:10)
at Module.load (node:internal/modules/cjs/loader:1117:32)
at Module._load (node:internal/modules/cjs/loader:958:12)
at Module.require (node:internal/modules/cjs/loader:1141:19) {
code: 'MODULE_NOT_FOUND',
requireStack: [
'C:\\Users\\vitga\\Desktop\\workspace\\DendaZMehoSklepa\\dendazmehosklepa\\build\\handlers\\lavaclient.js',
'C:\\Users\\vitga\\Desktop\\workspace\\DendaZMehoSklepa\\dendazmehosklepa\\build\\client\\Client.js',
'C:\\Users\\vitga\\Desktop\\workspace\\DendaZMehoSklepa\\dendazmehosklepa\\build\\index.js'
]
}
35 replies
DFDimensional Fun
•Created by lickm3 on 6/6/2023 in #lavaclient
nodeTrackStart and nodeQueueFinish is not assignable to parameter of type 'keyof ClusterEvents'.
I installed the 7.0.1. Could I use require or import?
35 replies
DFDimensional Fun
•Created by lickm3 on 6/6/2023 in #lavaclient
nodeTrackStart and nodeQueueFinish is not assignable to parameter of type 'keyof ClusterEvents'.
npm
35 replies
DFDimensional Fun
•Created by lickm3 on 6/6/2023 in #lavaclient
nodeTrackStart and nodeQueueFinish is not assignable to parameter of type 'keyof ClusterEvents'.
Oh okay. Do you know about any alternative that supports typescript?
35 replies
DFDimensional Fun
•Created by lickm3 on 6/6/2023 in #lavaclient
nodeTrackStart and nodeQueueFinish is not assignable to parameter of type 'keyof ClusterEvents'.
yeah
35 replies
DFDimensional Fun
•Created by lickm3 on 6/6/2023 in #lavaclient
nodeTrackStart and nodeQueueFinish is not assignable to parameter of type 'keyof ClusterEvents'.
So maybe I use ESM? Iam not really sure. Iam still learning
35 replies
DFDimensional Fun
•Created by lickm3 on 6/6/2023 in #lavaclient
nodeTrackStart and nodeQueueFinish is not assignable to parameter of type 'keyof ClusterEvents'.
Well the errors are only on lines where I already use require
35 replies
DFDimensional Fun
•Created by lickm3 on 6/6/2023 in #lavaclient
nodeTrackStart and nodeQueueFinish is not assignable to parameter of type 'keyof ClusterEvents'.
I think CommonJS
35 replies
DFDimensional Fun
•Created by lickm3 on 6/6/2023 in #lavaclient
nodeTrackStart and nodeQueueFinish is not assignable to parameter of type 'keyof ClusterEvents'.
This is after useing require btw
35 replies
DFDimensional Fun
•Created by lickm3 on 6/6/2023 in #lavaclient
nodeTrackStart and nodeQueueFinish is not assignable to parameter of type 'keyof ClusterEvents'.
C:\Users\vitga\Desktop\workspace\DendaZMehoSklepa\dendazmehosklepa\build\handlers\lavaclient.js:8:37 :
const pretty_ms_1 = __importDefault(require("pretty-ms"));
C:\Users\vitga\Desktop\workspace\DendaZMehoSklepa\dendazmehosklepa\build\client\Client.js:33:20 : const lavaclient = require("../handlers/lavaclient");
C:\Users\vitga\Desktop\workspace\DendaZMehoSklepa\dendazmehosklepa\build\index.js:3:18 : const Client_1 = require("./client/Client");
35 replies
DFDimensional Fun
•Created by lickm3 on 6/6/2023 in #lavaclient
nodeTrackStart and nodeQueueFinish is not assignable to parameter of type 'keyof ClusterEvents'.
const pretty_ms_1 = __importDefault(require("pretty-ms"));
^
Error [ERR_REQUIRE_ESM]: require() of ES Module C:\Users\vitga\Desktop\workspace\DendaZMehoSklepa\dendazmehosklepa\node_modules\pretty-ms\index.js from C:\Users\vitga\Desktop\workspace\DendaZMehoSklepa\dendazmehosklepa\build\handlers\lavaclient.js not supported.
Instead change the require of index.js in C:\Users\vitga\Desktop\workspace\DendaZMehoSklepa\dendazmehosklepa\build\handlers\lavaclient.js to a dynamic import() which is available in all CommonJS modules.
at Object.<anonymous> (C:\Users\vitga\Desktop\workspace\DendaZMehoSklepa\dendazmehosklepa\build\handlers\lavaclient.js:8:37)
at Object.<anonymous> (C:\Users\vitga\Desktop\workspace\DendaZMehoSklepa\dendazmehosklepa\build\client\Client.js:33:20)
at Object.<anonymous> (C:\Users\vitga\Desktop\workspace\DendaZMehoSklepa\dendazmehosklepa\build\index.js:3:18) {
code: 'ERR_REQUIRE_ESM'
}
Node.js v18.16.0
35 replies
DFDimensional Fun
•Created by lickm3 on 6/6/2023 in #lavaclient
nodeTrackStart and nodeQueueFinish is not assignable to parameter of type 'keyof ClusterEvents'.
let me try it
35 replies
DFDimensional Fun
•Created by lickm3 on 6/6/2023 in #lavaclient
nodeTrackStart and nodeQueueFinish is not assignable to parameter of type 'keyof ClusterEvents'.
Tbh Iam really new to lavaclient
35 replies
DFDimensional Fun
•Created by lickm3 on 6/6/2023 in #lavaclient
nodeTrackStart and nodeQueueFinish is not assignable to parameter of type 'keyof ClusterEvents'.
Yeah I do
35 replies
DFDimensional Fun
•Created by lickm3 on 6/6/2023 in #lavaclient
nodeTrackStart and nodeQueueFinish is not assignable to parameter of type 'keyof ClusterEvents'.
This is my code for lavaclient.ts: https://pastebin.com/MNLQ58zT
35 replies
DFDimensional Fun
•Created by lickm3 on 6/6/2023 in #lavaclient
nodeTrackStart and nodeQueueFinish is not assignable to parameter of type 'keyof ClusterEvents'.
I will also send the code
35 replies
DFDimensional Fun
•Created by lickm3 on 6/6/2023 in #lavaclient
nodeTrackStart and nodeQueueFinish is not assignable to parameter of type 'keyof ClusterEvents'.
This is the errors:
src/handlers/lavaclient.ts:44:17 - error TS2345: Argument of type '"nodeTrackStart"' is not assignable to parameter of type 'keyof ClusterEvents'.
44 lavaclient.on("nodeTrackStart", (_node, queue, song) => {
~~~~~~~~~~~~~~~~
src/handlers/lavaclient.ts:77:17 - error TS2345: Argument of type '"nodeQueueFinish"' is not assignable to parameter of type 'keyof ClusterEvents'.
77 lavaclient.on("nodeQueueFinish", async (_node, queue) => {
35 replies