Open nodecentral opened 1 month ago
Hi @CyferShepard - do you need anything more from me on this issue ?
Is there anything I can do in the interim ? The Jellyfin ip and port, it gave me is the one I set up for jelly stat, and no matter what I can do I can’t edit it. Is there somewhere like a config/txt/xml file where I could maybe edit it in ?
Hey @nodecentral , can you pull the newest unstable image and try again? i added safety checks for the code where the logs indicated an error. I just want to see if that helps or if theres a new error
Hi - OK - pulled the unstable version and tried to make changes to the Jelly fin URL and API key again..
No message comes up, and upon refresh the it returns to it’s original value - so the problem still occurs.. Here is a snap of the log..
> jfstat@1.1.1 start
> cd backend && node server.js
all values are hidden
env.js file has been saved successfully.
[JELLYSTAT] Database exists. Skipping creation
FS-related option specified for migration configuration. This resets migrationSource to default FsMigrations
FS-related option specified for migration configuration. This resets migrationSource to default FsMigrations
[JELLYSTAT] Server listening on http://127.0.0.1:3000/
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<link rel="icon" href="favicon.ico" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<meta name="theme-color" content="#000000" />
<meta name="description" content="Jellyfin stats for the masses" />
<link rel="apple-touch-icon" href="icon-b-192.png" />
<script src="env.js"></script>
<!--
manifest.json provides metadata used when your web app is installed on a
user's mobile device or desktop. See https://developers.google.com/web/fundamentals/web-app-manifest/
-->
<link rel="manifest" href="manifest.json" />
<!--
Notice the use of %PUBLIC_URL% in the tags above.
It will be replaced with the URL of the `public` folder during the build.
Only files inside the `public` folder can be referenced from the HTML.
all values are hidden
Unlike "favicon.ico" or "favicon.ico", "%PUBLIC_URL%/favicon.ico" will
work correctly both with client-side routing and a non-root public URL.
Learn how to configure a non-root public URL by running `npm run build`.
-->
<title>JellyStat</title>
<script type="module" crossorigin src="./assets/index-864c1f9d.js"></script>
<link rel="modulepreload" crossorigin href="./assets/vendor-2d4d1dd6.js">
<link rel="stylesheet" href="./assets/index-ac22111c.css">
</head>
<body>
<noscript>You need to enable JavaScript to run this app.</noscript>
<div id="root"></div>
</body>
</html>
all values are hidden
[JELLYFIN-API] {
ErrorAt: 'at JellyfinAPI.getRecentlyAdded (/app/backend/classes/jellyfin-api.js:355:48',
ErrorLines: [
{
TraceIndex: 1,
line: '/app/backend/classes/jellyfin-api.js:355:48'
},
{ TraceIndex: 2, line: 'node:internal/process/task_queues:105:5' },
{
TraceIndex: 3,
line: 'at async /app/backend/routes/api.js:170:38'
}
],
Message: "Cannot read properties of undefined (reading 'Id')",
url: undefined
}
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<link rel="icon" href="favicon.ico" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<meta name="theme-color" content="#000000" />
<meta name="description" content="Jellyfin stats for the masses" />
<link rel="apple-touch-icon" href="icon-b-192.png" />
<script src="env.js"></script>
<!--
manifest.json provides metadata used when your web app is installed on a
user's mobile device or desktop. See https://developers.google.com/web/fundamentals/web-app-manifest/
-->
<link rel="manifest" href="manifest.json" />
<!--
Notice the use of %PUBLIC_URL% in the tags above.
It will be replaced with the URL of the `public` folder during the build.
Only files inside the `public` folder can be referenced from the HTML.
all values are hidden
Unlike "favicon.ico" or "favicon.ico", "%PUBLIC_URL%/favicon.ico" will
work correctly both with client-side routing and a non-root public URL.
Learn how to configure a non-root public URL by running `npm run build`.
-->
<title>JellyStat</title>
<script type="module" crossorigin src="./assets/index-864c1f9d.js"></script>
<link rel="modulepreload" crossorigin href="./assets/vendor-2d4d1dd6.js">
<link rel="stylesheet" href="./assets/index-ac22111c.css">
</head>
<body>
<noscript>You need to enable JavaScript to run this app.</noscript>
<div id="root"></div>
</body>
</html>
all values are hidden
http://192.168.102.134:8096/ true
http://192.168.102.134:8096/ true
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<link rel="icon" href="favicon.ico" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<meta name="theme-color" content="#000000" />
<meta name="description" content="Jellyfin stats for the masses" />
<link rel="apple-touch-icon" href="icon-b-192.png" />
<script src="env.js"></script>
<!--
manifest.json provides metadata used when your web app is installed on a
user's mobile device or desktop. See https://developers.google.com/web/fundamentals/web-app-manifest/
-->
<link rel="manifest" href="manifest.json" />
<!--
Notice the use of %PUBLIC_URL% in the tags above.
It will be replaced with the URL of the `public` folder during the build.
Only files inside the `public` folder can be referenced from the HTML.
all values are hidden
Unlike "favicon.ico" or "favicon.ico", "%PUBLIC_URL%/favicon.ico" will
work correctly both with client-side routing and a non-root public URL.
Learn how to configure a non-root public URL by running `npm run build`.
-->
<title>JellyStat</title>
<script type="module" crossorigin src="./assets/index-864c1f9d.js"></script>
<link rel="modulepreload" crossorigin href="./assets/vendor-2d4d1dd6.js">
<link rel="stylesheet" href="./assets/index-ac22111c.css">
</head>
<body>
<noscript>You need to enable JavaScript to run this app.</noscript>
<div id="root"></div>
</body>
</html>
all values are hidden
[JELLYFIN-API] {
ErrorAt: 'at AxiosError.from (/app/node_modules/axios/dist/node/axios.cjs:841:14',
ErrorLines: [
{
TraceIndex: 1,
line: '/app/node_modules/axios/dist/node/axios.cjs:841:14'
},
{
TraceIndex: 2,
line: '/app/node_modules/axios/dist/node/axios.cjs:3106:25'
},
{ TraceIndex: 3, line: 'node:events:520:28' },
{
TraceIndex: 4,
line: '/app/node_modules/follow-redirects/index.js:38:24'
},
{ TraceIndex: 5, line: 'node:events:520:28' },
{ TraceIndex: 6, line: 'node:_http_client:103:11' },
{ TraceIndex: 7, line: 'node:_http_client:506:5' },
{ TraceIndex: 8, line: 'node:events:520:28' },
{ TraceIndex: 9, line: 'node:internal/streams/destroy:170:8' },
{ TraceIndex: 10, line: 'node:internal/streams/destroy:129:3' },
{
TraceIndex: 11,
line: '/app/node_modules/axios/dist/node/axios.cjs:4224:41'
},
{ TraceIndex: 12, line: 'node:internal/process/task_queues:105:5' },
{
TraceIndex: 13,
line: '/app/backend/classes/jellyfin-api.js:486:24'
},
{
TraceIndex: 14,
line: 'at async /app/backend/routes/api.js:279:24'
}
],
Message: 'connect ETIMEDOUT 192.168.102.134:8096',
url: undefined
}
[JELLYFIN-API] {
ErrorAt: 'at AxiosError.from (/app/node_modules/axios/dist/node/axios.cjs:841:14',
ErrorLines: [
{
TraceIndex: 1,
line: '/app/node_modules/axios/dist/node/axios.cjs:841:14'
},
{
TraceIndex: 2,
line: '/app/node_modules/axios/dist/node/axios.cjs:3106:25'
},
{ TraceIndex: 3, line: 'node:events:520:28' },
{
TraceIndex: 4,
line: '/app/node_modules/follow-redirects/index.js:38:24'
},
{ TraceIndex: 5, line: 'node:events:520:28' },
{ TraceIndex: 6, line: 'node:_http_client:103:11' },
{ TraceIndex: 7, line: 'node:_http_client:506:5' },
{ TraceIndex: 8, line: 'node:events:520:28' },
{ TraceIndex: 9, line: 'node:internal/streams/destroy:170:8' },
{ TraceIndex: 10, line: 'node:internal/streams/destroy:129:3' },
{
TraceIndex: 11,
line: '/app/node_modules/axios/dist/node/axios.cjs:4224:41'
},
{ TraceIndex: 12, line: 'node:internal/process/task_queues:105:5' },
{
TraceIndex: 13,
line: '/app/backend/classes/jellyfin-api.js:486:24'
},
{
TraceIndex: 14,
line: 'at async /app/backend/routes/api.js:279:24'
}
],
Message: 'connect ETIMEDOUT 192.168.102.134:8096',
url: undefined
It seems to be reporting the IP I had updated it to, here in the logs, but when I hit refresh on the Settings screen it just shows me to original one which has 8097 as the port (FYI - this is the port that I set Jellystat to)
Just to share the sequence..
After I make the change to the Jellyfin URL and API key I hit Update, and the log shows the following..
http://192.168.102.134:8096/ true
From there, I then hit refresh of the browser to see if it has saved, and then it gives me the following messages in the log - alluding to a javascript setting - FYI I’m using an iPAD (and Safari)
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<link rel="icon" href="favicon.ico" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<meta name="theme-color" content="#000000" />
<meta name="description" content="Jellyfin stats for the masses" />
<link rel="apple-touch-icon" href="icon-b-192.png" />
<script src="env.js"></script>
<!--
manifest.json provides metadata used when your web app is installed on a
user's mobile device or desktop. See https://developers.google.com/web/fundamentals/web-app-manifest/
-->
<link rel="manifest" href="manifest.json" />
<!--
Notice the use of %PUBLIC_URL% in the tags above.
It will be replaced with the URL of the `public` folder during the build.
Only files inside the `public` folder can be referenced from the HTML.
all values are hidden
Unlike "favicon.ico" or "favicon.ico", "%PUBLIC_URL%/favicon.ico" will
work correctly both with client-side routing and a non-root public URL.
Learn how to configure a non-root public URL by running `npm run build`.
-->
<title>JellyStat</title>
<script type="module" crossorigin src="./assets/index-864c1f9d.js"></script>
<link rel="modulepreload" crossorigin href="./assets/vendor-2d4d1dd6.js">
<link rel="stylesheet" href="./assets/index-ac22111c.css">
</head>
<body>
<noscript>You need to enable JavaScript to run this app.</noscript>
<div id="root"></div>
</body>
</html>
I checked my settings and javascript is enabled.,
Just to be sure you have all the information you need from my logs, he’s what’s occurred since my last failed saves ..
{ TraceIndex: 6, line: 'node:_http_client:103:11' },
{ TraceIndex: 7, line: 'node:_http_client:506:5' },
{ TraceIndex: 8, line: 'node:events:520:28' },
{ TraceIndex: 9, line: 'node:internal/streams/destroy:170:8' },
{ TraceIndex: 10, line: 'node:internal/streams/destroy:129:3' },
{
TraceIndex: 11,
line: '/app/node_modules/axios/dist/node/axios.cjs:4224:41'
},
{ TraceIndex: 12, line: 'node:internal/process/task_queues:105:5' },
{
TraceIndex: 13,
line: '/app/backend/classes/jellyfin-api.js:486:24'
},
{
TraceIndex: 14,
line: 'at async /app/backend/routes/api.js:279:24'
}
],
Message: 'connect ETIMEDOUT 192.168.102.134:8096',
url: undefined
}
[JELLYFIN-API] {
ErrorAt: 'at AxiosError.from (/app/node_modules/axios/dist/node/axios.cjs:841:14',
ErrorLines: [
{
TraceIndex: 1,
line: '/app/node_modules/axios/dist/node/axios.cjs:841:14'
},
{
TraceIndex: 2,
line: '/app/node_modules/axios/dist/node/axios.cjs:3106:25'
},
{ TraceIndex: 3, line: 'node:events:520:28' },
{
TraceIndex: 4,
line: '/app/node_modules/follow-redirects/index.js:38:24'
},
{ TraceIndex: 5, line: 'node:events:520:28' },
{ TraceIndex: 6, line: 'node:_http_client:103:11' },
{ TraceIndex: 7, line: 'node:_http_client:506:5' },
{ TraceIndex: 8, line: 'node:events:520:28' },
{ TraceIndex: 9, line: 'node:internal/streams/destroy:170:8' },
{ TraceIndex: 10, line: 'node:internal/streams/destroy:129:3' },
{
TraceIndex: 11,
line: '/app/node_modules/axios/dist/node/axios.cjs:4224:41'
},
{ TraceIndex: 12, line: 'node:internal/process/task_queues:105:5' },
{
TraceIndex: 13,
line: '/app/backend/classes/jellyfin-api.js:486:24'
},
{
TraceIndex: 14,
line: 'at async /app/backend/routes/api.js:279:24'
}
],
Message: 'connect ETIMEDOUT 192.168.102.134:8096',
url: undefined
}
[JELLYFIN-API] {
ErrorAt: 'at AxiosError.from (/app/node_modules/axios/dist/node/axios.cjs:841:14',
ErrorLines: [
{
TraceIndex: 1,
line: '/app/node_modules/axios/dist/node/axios.cjs:841:14'
},
{
TraceIndex: 2,
line: '/app/node_modules/axios/dist/node/axios.cjs:3106:25'
},
{ TraceIndex: 3, line: 'node:events:520:28' },
{
TraceIndex: 4,
line: '/app/node_modules/follow-redirects/index.js:38:24'
},
{ TraceIndex: 5, line: 'node:events:520:28' },
{ TraceIndex: 6, line: 'node:_http_client:103:11' },
{ TraceIndex: 7, line: 'node:_http_client:506:5' },
{ TraceIndex: 8, line: 'node:events:520:28' },
{ TraceIndex: 9, line: 'node:internal/streams/destroy:170:8' },
{ TraceIndex: 10, line: 'node:internal/streams/destroy:129:3' },
{
TraceIndex: 11,
line: '/app/node_modules/axios/dist/node/axios.cjs:4224:41'
},
{ TraceIndex: 12, line: 'node:internal/process/task_queues:105:5' },
{
TraceIndex: 13,
line: '/app/backend/classes/jellyfin-api.js:486:24'
},
{
TraceIndex: 14,
line: 'at async /app/backend/routes/api.js:279:24'
}
],
Message: 'connect ETIMEDOUT 192.168.102.134:8096',
url: undefined
}
Hey @nodecentral , just to confirm, this section,
<!DOCTYPE html> <html lang="en"> <head> <meta charset="UTF-8" /> <link rel="icon" href="favicon.ico" /> <meta name="viewport" content="width=device-width, initial-scale=1.0" /> <meta name="theme-color" content="#000000" /> <meta name="description" content="Jellyfin stats for the masses" /> <link rel="apple-touch-icon" href="icon-b-192.png" /> <script src="env.js"></script> <!-- manifest.json provides metadata used when your web app is installed on a user's mobile device or desktop. See https://developers.google.com/web/fundamentals/web-app-manifest/ --> <link rel="manifest" href="manifest.json" /> <!-- Notice the use of %PUBLIC_URL% in the tags above. It will be replaced with the URL of the
publicfolder during the build. Only files inside the
publicfolder can be referenced from the HTML. all values are hidden Unlike "favicon.ico" or "favicon.ico", "%PUBLIC_URL%/favicon.ico" will work correctly both with client-side routing and a non-root public URL. Learn how to configure a non-root public URL by running
npm run build`.
-->
<title>JellyStat</title>
<script type="module" crossorigin src="./assets/index-864c1f9d.js"></script>
<link rel="modulepreload" crossorigin href="./assets/vendor-2d4d1dd6.js">
<link rel="stylesheet" href="./assets/index-ac22111c.css">
</head>
<body>
<noscript>You need to enable JavaScript to run this app.</noscript>
<div id="root"></div>
</body> </html>`
Does that appear in the docker logs or console logs?
Hi @CyferShepard - it's from the Docker logs.
The Jellystat logs sadly tell me very little, they only reference the sync and any backups - nothing more. No updates to settings seem to be recorded ?
okay thanks, im not really sure how to replicate this so it may take me a while. can you try this but, change the api and url, then on another device, or even in incognito mode, go to the settings page and see if its still the old value or the new value
Sadly the same thing via Chrome and ingconito mode on the iPad
Hi @CyferShepard - is there anything else I can do to make this work, sadly I can’t use Jellystat until I can update the details. Is it perhaps in a config file I could manually access and change?
Hey @nodecentral , sorry i didnt actually debug this in depth, i initially got stuck on trying to replicate the error. not really sure whats causing it or how to replicate it in my test instance. theres no config for this. the only way is to manually set the values in the postgres db
Thanks so much for responding @CyferShepard, if it's not something you can reproduce then I completely appreciate it's not something you'd want to spend time on..
To try one final things - as I never considered or even know where to state to edit a value in the postgres db before, do you know if that is that possible? I'll try anything to help get this to work :-)
so i added 2 new environmental variables to allow you to override these values. it doesnt store it to the db, just replaces the db value when its being used. the new envs are called JF_HOST and JF_API_KEY. Just a heads up however. i dont have any validation on this field. and depending on the values you enter, if not formatted correctly. it could cause bugs or errors in the logs. an example of something that should work is
JF_HOST : http://192.168.0.1:8096
JF_API_KEY: xxxxxxxxxxxxxxxxx
Many Thanks @CyferShepard
I’ll give it a go with the latest image you have ..
version: '3'
services:
jellystat-db:
image: postgres:15.2
container_name: jellystat-db
restart: unless-stopped
environment:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: mypassword
volumes:
- /share/Container/jellystat/postgres-data:/var/lib/postgresql/data
jellystat:
image: cyfershepard/jellystat:latest
container_name: jellystat
restart: unless-stopped
environment:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: mypassword
POSTGRES_IP: jellystat-db
POSTGRES_PORT: 5432
JWT_SECRET: "my-secret-jwt-key"
JF_HOST: http://192.168.1.234:8096
JF_API_KEY: moienfoeifnoweifnwoeinfwoeifnwoeinf
TZ: Europe/London
volumes:
- /share/Container/jellystat/jellystat-backup-data:/app/backend/backup-data
ports:
- "8097:3000"
depends_on:
- jellystat-db
networks:
default:
volumes:
postgres-data:
jellystat-backup-data:
logging:
driver: "json-file"
options:
max-file: "5" # number of files or file count
max-size: "10m" # file size
```a
Hey @nodecentral , its not on latest
, it would be on unstable
. Only new releases have the latest
tag
Hi @CyferShepard
Sadly, no luck with the unstable version, even as environment variables they are not showing up. Ok, to try again from the start removed all web cache, delete all Postgres dbs - and even after that I can't get past it the initial 'validating' step?
The logs only show this..
It won't progress any further..
Any ideas are there more verbose logs I can check ?
can you check he browsers console log? its located in your browsers dev tools
Sure, here you go, reminder my primary device is an iPad
I checked my Safaris settings and javascript is (and always has been) enabled.
Other entries of interest are as follows
It’s important to note, that both Jellyfin and jellystat are running on the same host 192.168.102.134, Jellyfin is port :8096 and jellystat is port :8097
I did try using local host (see below) but got a 400 error
can you try host.docker.internal
instead of localhost, so it would be http://host.docker.internal:8096
Same 400 error with http://host.docker.internal:8096/
as it was with http://127.0.0.1:8096/
If i try the actual Jellyfin IP, on http://192.168.102.134:8096/
it shows validating, but that’s it, nothing more it stays there.
Describe the bug
Changes being made to the settings are not being saved, even though Update has been pressed (and occasional a save successfully message comes up)
Environment Details (please complete the following information):
To Reproduce Steps to reproduce the behavior:
Expected behavior Settings should be saved
Screenshots
Task Logs