vlc-rpc / vlc-discord-rpc Goto Github PK
View Code? Open in Web Editor NEWDisplay what you're watching on VLC media player as your Discord status with this Node.js application.
License: MIT License
Display what you're watching on VLC media player as your Discord status with this Node.js application.
License: MIT License
Error: child "activity" fails because [child "details" fails because ["details" length must be at least 2 characters long]]
Currently, if you do not have anything queued and try to run the program while using the detached option, the user gets an ugly error message that does not tell them what the actual issue is. This should be fixed to let the user know to queue something first.
Mentioned in: #12
Moving this here for better tracking.
In Pigpog's original repo, there was a way to set up VLC to run "detached" from vlc-discord-rpc:
Out of the box, starting vlc-discord-rpc will open VLC, and closing VLC will close vlc-discord-rpc. This is the "attached" mode, and it is the default because "it just works" in most cases.
Detached mode will not open VLC for you, and closing VLC won't close vlc-discord-rpc. It requires a bit of tweaking, but once it is configured, it allows you to open and close VLC as you normally would and still show a rich presence.
How can we achieve this same functionality using your fork of vlc-discord-rpc?
So I'm trying to watch a video I got saved on my computer and it doesn't have any metadata as far as I know since this is the error that keeps coming up. (the one in the title, trying to read category when that field is empty probably or smth)
So I tried running the rich presence app without anything open in VLC and I still get this error.
I checked the vlcPath
in the config file and it is the correct path to my custom VLC install folder but it doesn't seem to be able to communicate with it for some reason.
In the main interfaces on VLC, I have
In Lua interpreter I have these settings (I double checked and I have the same password on both config and VLC)
in case I somehow messed up, I changed the password to a simple one like 123
in both places and still get the error even tho VLC is running and has a video playing. Oh and I set detached to true
Connecting to Discord...
Logged in as *************************
Failed to reach VLC. Is it open?
Uncaught TypeError TypeError: Cannot read properties of undefined (reading 'category')
at module.exports (h:\Discord\vlc-discord-rpc-main\Functions\rpc-format.js:23:35)
at <anonymous> (h:\Discord\vlc-discord-rpc-main\Functions\client.js:28:41)
at module.exports (h:\Discord\vlc-discord-rpc-main\Functions\status.js:85:7)
at processTicksAndRejections (internal/process/task_queues:95:5)
I went to status.js
in the Functions
folder and it dies on line 21
where it tries to await VLCClient.getStatus();
first goes here when I step into
line 57
step into that then get here
line 57
pass the return new Promise
gets the address
var, everything seems fine
runs _request
on line 59
drop to line 97
starts doing that promise
passes data, basicAuth and we get to req
on req it does the http.get(address.toString())
thing but instead of .on('response'
it jumps to .on('error', reject)
and then the usual output of Failed to reach VLC. blah blah
comes up and exits.
Not sure what the issue is I followed all the steps one by one and precisely. The only thing I didn't fill out was the spotify information because I don't have an account and don't use it and don't really care about the cover pictures. Unless filling out the spotify information is an essential part to fill out in the config?
From npm:
npm warn deprecated [email protected]: This module is not supported, and leaks memory. Do not use it. Check out lru-cache if you want a good and tested way to coalesce async requests by a key value, which is much more comprehensive and powerful.
The details attribute must be <= 128 characters. If it's greater than 128 chars, we should just cut it and append a ...
When you use copy path, it will provide the file as a quote:
"C:\Users\User\Documents\..."
This seems to work fine in the metadata script, but does not check if the file already exists, due to the quotes.
well the title explains it
ive searched up everywhere but cannot find a way to get the spotify token
Hi! Just came across this and wanted to give it a go, though I seem to be having issues. using command 'npm i' works just fine but running up 'node . ' gives me an error message, claims that 'storage/config.js' can't be found. I was curious on if this was a bug or not. I made sure to run everything up correctly and double checked my steps.
I wanted to add as well that the support discord invite link expired and doesn't seem to be working.
I thought i'd try to get the movie icons to work, got my OMDb api key. The settings seem correct, but I think i just dont understand how to name the movies and where to put them. Can someone help?
im getting this error with only this episode , other episodes are fine and even other movies, idk if its the episode itself but i thought i should report in case it is not.
ps: im gonna keep this episode in my pc in case you have an idea how to fix this so i can test it
Connecting to Discord...
Logged in as **************
VLC not playing; going to sleep. true
{
_STATISTICS_WRITING_APP: "mkvmerge v82.0 ('I'm The President') 64-bit",
showName: 'Shogun 2024',
DURATION: '00:52:34.083000000',
seasonNumber: '01',
filename: 'Shogun.2024.S01E03.1080p.10bit.WEBRip.6CH.x265.HEVC-PSA.mkv',
BPS: '41',
title: 'PSArips.com | Shogun.2024.S01E03.1080p.10bit.WEBRip.6CH.x265.HEVC-PSA',
_STATISTICS_TAGS: 'BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES',
NUMBER_OF_FRAMES: '554',
NUMBER_OF_BYTES: '16271',
episodeNumber: '03',
_STATISTICS_WRITING_DATE_UTC: '2024-03-05 06:51:36'
}
TypeError: Cannot read properties of undefined (reading 'show')
at searchShow (C:\Users\Spix\Desktop\vlc-discord-rpc-main\Functions\Images\searchShow.js:8:26)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async module.exports (C:\Users\Spix\Desktop\vlc-discord-rpc-main\Functions\rpc-format.js:42:18)
at async C:\Users\Spix\Desktop\vlc-discord-rpc-main\Functions\client.js:13:25
C:\Users\Spix\Desktop\vlc-discord-rpc-main\Functions\rpc-format.js:44
if (show.image) {
^
TypeError: Cannot read properties of null (reading 'image')
at module.exports (C:\Users\Spix\Desktop\vlc-discord-rpc-main\Functions\rpc-format.js:44:14)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async C:\Users\Spix\Desktop\vlc-discord-rpc-main\Functions\client.js:13:25
Node.js v20.11.1
PS C:\Users\Spix\Desktop\vlc-discord-rpc-main>
node .
in repo directory.PS C:\Users\Jet\Desktop\vlc-discord-rpc-main> node .
Connecting to Discord...
Logged in as jetpackjackson
VLC not playing; going to sleep. true
C:\Users\Jet\Desktop\vlc-discord-rpc-main\node_modules\discord-rpc\src\client.js:178
const e = new Error(message.data.message);
^
Error: child "activity" fails because [child "details" fails because ["details" is not allowed to be empty]]
at RPCClient.onRpcMessage (C:\Users\Jet\Desktop\vlc-discord-rpc-main\node_modules\discord-rpc\src\client.js:178:19)
at IPCTransport.emit (node:events:518:28)
at C:\Users\Jet\Desktop\vlc-discord-rpc-main\node_modules\discord-rpc\src\transports\ipc.js:138:18
at decode (C:\Users\Jet\Desktop\vlc-discord-rpc-main\node_modules\discord-rpc\src\transports\ipc.js:92:5)
at Socket. (C:\Users\Jet\Desktop\vlc-discord-rpc-main\node_modules\discord-rpc\src\transports\ipc.js:120:7)
at Socket.emit (node:events:518:28)
at emitReadable (node:internal/streams/readable:832:12)
at process.processTicksAndRejections (node:internal/process/task_queues:81:21) {
code: 4000,
data: {
code: 4000,
message: 'child "activity" fails because [child "details" fails because ["details" is not allowed to be empty]]'
}
}
Node.js v20.11.0
Windows 10 with PowerShell
Getting this as of the last day or two:
C:\Users\Spiff>cd "C:\Users\Spiff\Documents\Scripts\vlc-discord-rich-presence"
C:\Users\Spiff\Documents\Scripts\vlc-discord-rich-presence>npm i
up to date, audited 23 packages in 365ms
1 package is looking for funding
run `npm fund` for details
found 0 vulnerabilities
C:\Users\Spiff\Documents\Scripts\vlc-discord-rich-presence>node .
Connecting to Discord...
(node:40796) [DEP0040] DeprecationWarning: The `punycode` module is deprecated. Please use a userland alternative instead.
(Use `node --trace-deprecation ...` to show where the warning was created)
Logged in as Spiff
undefined:1
SyntaxError: Unexpected end of JSON input
at JSON.parse (<anonymous>)
at new VLCStatus (C:\Users\Spiff\Documents\Scripts\vlc-discord-rich-presence\node_modules\vlc.js\lib\src\http\classes\VLCStatus.js:13:27)
at C:\Users\Spiff\Documents\Scripts\vlc-discord-rich-presence\node_modules\vlc.js\lib\src\http\Requester.js:65:21
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
Node.js v21.2.0
C:\Users\Spiff\Documents\Scripts\vlc-discord-rich-presence>
Currently, you need to have a link to update the files, but users should be able to use local files.
Mentioned in: #12
Moving this here for better tracking.
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.