unburn / musicard Goto Github PK
View Code? Open in Web Editor NEWMusicard is a futuristic music card canvas library
License: GNU General Public License v3.0
Musicard is a futuristic music card canvas library
License: GNU General Public License v3.0
I have created a Discord Bot that allows users to select songs using Slash Commands. Most of my friends are from Japan and Korea. When my friends enter song titles into the bot, they appear as garbled characters similar to not supporting special characters. However, artist names still appear in the English language. I apologize for not having much knowledge about coding, and I'm wondering what steps I should take to address this issue.
my code -
const card = new nowPlayingCard();
card
.setAuthor(`requested by ${track.info.requester}`)
.setColor(`auto`)
.setTheme(`classic`)
.setName(track.info.title)
.setThumbnail(track.info.thumbnail)
.setStartTime(`0:00`)
.setProgress(percent)
.setEndTime(`${duration}`)
const cardBuffer = await card.build();
and this causes another error - TypeError: Cannot read properties of undefined (reading 'width') which i belive is due to the image being absent due to the 404
Hello, I'd like to report a bug I've had for a few hours now. When I start my bot with the musicard module, it displays this error.
I tried without the module what it was doing, and it didn't show me this error. Thank you for your help and have a nice day.
Error: ENOENT: no such file or directory, lstat 'C:\Users\%%%\%%%\Project\res
TypeError: (intermediate value).setName(...).setA uthor(...).setColor(...).setTheme is not a functi on at module.exports (/home/container/src/events /Lavalink/trackStart.js:61:5 at process.processTicksAndRejections (node: in ternal/process/task_queues:95:5)
index.d.ts
is missing the decleration of setBrightness
method
Whenever i Require Musicard i get this Error My Code Is Working Fine Without Importing Musicard Although It Is Installed Whenever I Require I Get This Error:
node:internal/modules/cjs/loader:1340
return process.dlopen(module, path.toNamespacedPath(filename));
^
Error: The module '/home/ayushd/Documents/Codes/Bot/node_modules/canvas/build/Release/canvas.node'
was compiled against a different Node.js version using
NODE_MODULE_VERSION 102. This version of Node.js requires
NODE_MODULE_VERSION 108. Please try re-compiling or re-installing
the module (for instance, using `npm rebuild` or `npm install`).
at Module._extensions..node (node:internal/modules/cjs/loader:1340:18)
at Module.load (node:internal/modules/cjs/loader:1119:32)
at Module._load (node:internal/modules/cjs/loader:960:12)
at Module.require (node:internal/modules/cjs/loader:1143:19)
at require (node:internal/modules/cjs/helpers:119:18)
at Object.<anonymous> (/home/ayushd/Documents/Codes/Bot/node_modules/canvas/lib/bindings.js:3:18)
at Module._compile (node:internal/modules/cjs/loader:1256:14)
at Module._extensions..js (node:internal/modules/cjs/loader:1310:10)
at Module.load (node:internal/modules/cjs/loader:1119:32)
at Module._load (node:internal/modules/cjs/loader:960:12) {
code: 'ERR_DLOPEN_FAILED'
}
Node.js v18.18.0
Unhandled Rejection at: Promise {
TypeError: Cannot read properties of undefined (reading 'width')
at musicCard.build (/home/container/node_modules/musicard/build/structures/musicCard.js:229:59)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async module.exports.run (/home/container/src/events/poruEvents/player/trackStart.js:36:46)
} reason: TypeError: Cannot read properties of undefined (reading 'width')
at musicCard.build (/home/container/node_modules/musicard/build/structures/musicCard.js:229:59)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async module.exports.run (/home/container/src/events/poruEvents/player/trackStart.js:36:46)
https://i.ytimg.com/vi_webp/mpWnhkMLIu4/maxresdefault.webp
/home/hanahiranetwork/Desktop/DiscordBOT/HimawariChan/node_modules/canvas/lib/image.js:94
SetSource.call(img, src)
^
Error: Unsupported image type
at setSource (/home/hanahiranetwork/Desktop/DiscordBOT/HimawariChan/node_modules/canvas/lib/image.js:94:13)
at /home/hanahiranetwork/Desktop/DiscordBOT/HimawariChan/node_modules/canvas/lib/image.js:62:11
at /home/hanahiranetwork/Desktop/DiscordBOT/HimawariChan/node_modules/simple-get/index.js:97:7
at IncomingMessage. (/home/hanahiranetwork/Desktop/DiscordBOT/HimawariChan/node_modules/simple-concat/index.js:8:13)
at Object.onceWrapper (node:events:628:28)
at IncomingMessage.emit (node:events:526:35)
at endReadableNT (node:internal/streams/readable:1359:12)
at process.processTicksAndRejections (node:internal/process/task_queues:82:21)
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.