raunot / plex-rewind Goto Github PK
View Code? Open in Web Editor NEWPresent Plex user statistics and habits in a beautiful and organized manner à la Spotify Wrapped.
License: GNU General Public License v3.0
Present Plex user statistics and habits in a beautiful and organized manner à la Spotify Wrapped.
License: GNU General Public License v3.0
When i launch plex-rewind all i see is placeholder images instead of real covers. No idea what i am missing.
Also file size for plex is only shown for Movies and 0 Bytes for everything else, but i guess thats unrelated :)
No response
desktop
Desktop
Docker throug ubuntu WLS2 on windows 11
Chrome 120.0.6099.130
No response
Would be more inline with what users see on Plex.
I got the error below initially
=> ERROR [plex-rewind deps 4/4] RUN if [ -f yarn.lock ]; then yarn --frozen-lockfile; elif [ -f package-lock.json ]; then npm ci; elif [ -f pn 1.6s
------
> [plex-rewind deps 4/4] RUN if [ -f yarn.lock ]; then yarn --frozen-lockfile; elif [ -f package-lock.json ]; then npm ci; elif [ -f pnpm-lock.yaml ]; then yarn global add pnpm && pnpm i --frozen-lockfile; else echo "Lockfile not found." && exit 1; fi:
0.537 yarn global v1.22.19
0.561 [1/4] Resolving packages...
0.828 [2/4] Fetching packages...
1.106 [3/4] Linking dependencies...
1.235 [4/4] Building fresh packages...
1.238 success Installed "[email protected]" with binaries:
1.238 - pnpm
1.238 - pnpx
1.238 Done in 0.70s.
1.598 ERR_PNPM_FROZEN_LOCKFILE_WITH_OUTDATED_LOCKFILE Cannot perform a frozen installation because the version of the lockfile is incompatible with this version of pnpm
1.598
1.598 Try either:
1.598 1. Aligning the version of pnpm that generated the lockfile with the version that installs from it, or
1.598 2. Migrating the lockfile so that it is compatible with the newer version of pnpm, or
1.598 3. Using "pnpm install --no-frozen-lockfile".
1.598 Note that in CI environments, this setting is enabled by default.
------
failed to solve: process "/bin/sh -c if [ -f yarn.lock ]; then yarn --frozen-lockfile; elif [ -f package-lock.json ]; then npm ci; elif [ -f pnpm-lock.yaml ]; then yarn global add pnpm && pnpm i --frozen-lockfile; else echo \"Lockfile not found.\" && exit 1; fi" did not complete successfully: exit code: 1
I ran
pnpm install --no-frozen-lockfile
then
docker compose build
and
docker compose up
The application spins but has no error on the terminal or browser console
Running on Ubuntu 22.04, please let me know how I can help debug!
Testing bug report template
main-179-77349b5710ce588cf739-plex-4.116.1.34756-a4ce464.js:1 [Parser] Unable to parse JSON: "undefined" is not valid JSON (no response)
onLogMessage @ main-179-77349b5710ce588cf739-plex-4.116.1.34756-a4ce464.js:1
onLog @ main-179-77349b5710ce588cf739-plex-4.116.1.34756-a4ce464.js:1
m @ main-179-77349b5710ce588cf739-plex-4.116.1.34756-a4ce464.js:1
trigger @ main-179-77349b5710ce588cf739-plex-4.116.1.34756-a4ce464.js:1
(anonymous) @ main-179-77349b5710ce588cf739-plex-4.116.1.34756-a4ce464.js:1
ke @ main-179-77349b5710ce588cf739-plex-4.116.1.34756-a4ce464.js:1
jh @ main-179-77349b5710ce588cf739-plex-4.116.1.34756-a4ce464.js:1
(anonymous) @ 6654-6654-5e6fe91a4045853ab3e9-plex-4.116.1.34756-a4ce464.js:2
u @ 6654-6654-5e6fe91a4045853ab3e9-plex-4.116.1.34756-a4ce464.js:2
add @ 6654-6654-5e6fe91a4045853ab3e9-plex-4.116.1.34756-a4ce464.js:2
(anonymous) @ 6654-6654-5e6fe91a4045853ab3e9-plex-4.116.1.34756-a4ce464.js:2
each @ 6654-6654-5e6fe91a4045853ab3e9-plex-4.116.1.34756-a4ce464.js:2
(anonymous) @ 6654-6654-5e6fe91a4045853ab3e9-plex-4.116.1.34756-a4ce464.js:2
Deferred @ 6654-6654-5e6fe91a4045853ab3e9-plex-4.116.1.34756-a4ce464.js:2
then @ 6654-6654-5e6fe91a4045853ab3e9-plex-4.116.1.34756-a4ce464.js:2
(anonymous) @ main-179-77349b5710ce588cf739-plex-4.116.1.34756-a4ce464.js:1
38373 @ main-179-77349b5710ce588cf739-plex-4.116.1.34756-a4ce464.js:1
r @ auth-form/?utm_source=Plex%20Apps&utm_medium=Plex%20Web&utm_campaign=Plex%20Apps:26
t @ main-179-77349b5710ce588cf739-plex-4.116.1.34756-a4ce464.js:1
(anonymous) @ main-179-77349b5710ce588cf739-plex-4.116.1.34756-a4ce464.js:1
r.O @ auth-form/?utm_source=Plex%20Apps&utm_medium=Plex%20Web&utm_campaign=Plex%20Apps:26
(anonymous) @ main-179-77349b5710ce588cf739-plex-4.116.1.34756-a4ce464.js:1
a @ auth-form/?utm_source=Plex%20Apps&utm_medium=Plex%20Web&utm_campaign=Plex%20Apps:26
(anonymous) @ main-179-77349b5710ce588cf739-plex-4.116.1.34756-a4ce464.js:1
desktop
PC
Windows 11
Chrome 120.0.6099.129
No response
latest: v1.8.7
Build installs [email protected] then fails because expecting [email protected] which is the version used to generate the lockfile
[+] Building 11.0s (13/21) docker:default
=> [plex-rewind internal] load build definition from Dockerfile 0.0s
=> => transferring dockerfile: 2.17kB 0.0s
=> [plex-rewind internal] load metadata for docker.io/library/node:18-alpine 0.8s
=> [plex-rewind internal] load .dockerignore 0.0s
=> => transferring context: 120B 0.0s
=> [plex-rewind internal] load build context 0.1s
=> => transferring context: 497.86kB 0.1s
=> [plex-rewind base 1/2] FROM docker.io/library/node:18-alpine@sha256:4837c2ac8998cf172f5892fb45f229c328e4824c4 4.4s
=> => resolve docker.io/library/node:18-alpine@sha256:4837c2ac8998cf172f5892fb45f229c328e4824c43c8506f8ba9c7996d 0.0s
=> => sha256:4837c2ac8998cf172f5892fb45f229c328e4824c43c8506f8ba9c7996d702430 1.43kB / 1.43kB 0.0s
=> => sha256:267ef0e247ce1ace38e92d80c5c0ebb0aa2ce34e8ba28998f8f1acd886451e49 1.16kB / 1.16kB 0.0s
=> => sha256:1835bef2bac85b1699df958a9ee9d867ec68551e192317c0a36f5e8d8987280b 7.21kB / 7.21kB 0.0s
=> => sha256:4abcf20661432fb2d719aaf90656f55c287f8ca915dc1c92ec14ff61e67fbaf8 3.41MB / 3.41MB 0.5s
=> => sha256:45a0166cf96b2a4f328191f78f73e68e0e340450a962ff6fc34013111c014d26 39.82MB / 39.82MB 2.0s
=> => sha256:832e0dc1fe41d061d47d41e00abf6a9dab0c399d69bae854ef1bffe1976c2df0 1.38MB / 1.38MB 0.2s
=> => sha256:8ae971f79f99381da4a83f2cb63aa502fb847cc81a2f270326753f6289562dfc 454B / 454B 0.2s
=> => extracting sha256:4abcf20661432fb2d719aaf90656f55c287f8ca915dc1c92ec14ff61e67fbaf8 0.3s
=> => extracting sha256:45a0166cf96b2a4f328191f78f73e68e0e340450a962ff6fc34013111c014d26 2.1s
=> => extracting sha256:832e0dc1fe41d061d47d41e00abf6a9dab0c399d69bae854ef1bffe1976c2df0 0.1s
=> => extracting sha256:8ae971f79f99381da4a83f2cb63aa502fb847cc81a2f270326753f6289562dfc 0.0s
=> [plex-rewind base 2/2] RUN npm install -g pnpm 2.9s
=> [plex-rewind deps 1/4] RUN apk add --no-cache libc6-compat 1.3s
=> [plex-rewind runner 1/8] WORKDIR /app 0.0s
=> [plex-rewind runner 2/8] RUN addgroup --system --gid 1001 nodejs 0.5s
=> [plex-rewind runner 3/8] RUN adduser --system --uid 1001 nextjs 0.5s
=> [plex-rewind deps 2/4] WORKDIR /app 0.0s
=> [plex-rewind deps 3/4] COPY package.json yarn.lock* package-lock.json* pnpm-lock.yaml* ./ 0.0s
=> ERROR [plex-rewind deps 4/4] RUN if [ -f yarn.lock ]; then yarn --frozen-lockfile; elif [ -f package-lock 1.5s
------
> [plex-rewind deps 4/4] RUN if [ -f yarn.lock ]; then yarn --frozen-lockfile; elif [ -f package-lock.json ]; then npm ci; elif [ -f pnpm-lock.yaml ]; then pnpm i --frozen-lockfile; else echo "Lockfile not found." && exit 1; fi:
1.455 ERR_PNPM_BAD_PM_VERSION This project is configured to use v8.13.1 of pnpm. Your current pnpm is v9.0.6
1.455
1.455 If you want to bypass this version check, you can set the "package-manager-strict" configuration to "false" or set the "COREPACK_ENABLE_STRICT" environment variable to "0"
desktop
Windows PC
Windows 10
N/A
No response
Could you put together a brief configuration guide and, ideally, a sample docker-compose.yml
?
Any chance you'll be publishing and maintaining a docker image for this?
Would be cool if the users could see how many movies, shows or music items they've watched during the year.
We could show it after the total duration stat in Rewind for movies, shows and music. Something like "You've watched 82 movies this year".
No response
We should have automated tests for important flows.
v1.8.7
Upon authenticating and then clicking on Rewind "Uh oh.. something went wrong!" error appears.
Spinup a docker compose
▲ Next.js 14.0.4
- Local: http://localhost:8383
- Network: http://0.0.0.0:8383
✓ Ready in 59ms
Error fetching from Tautulli API. The query was 'get_library_media_info'.
Error: Tautulli API request failed: 500 Internal Server Error
at s (/app/.next/server/app/api/auth/[...nextauth]/route.js:1:6117)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async c (/app/.next/server/app/dashboard/(route)/[slug]/page.js:1:6348)
at async Promise.all (index 2)
at async f (/app/.next/server/app/dashboard/(route)/[slug]/page.js:1:6955)
Error: Tautulli API request failed: 500 Internal Server Error
at s (/app/.next/server/app/api/auth/[...nextauth]/route.js:1:6117)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async c (/app/.next/server/app/dashboard/(route)/[slug]/page.js:1:6348)
at async Promise.all (index 2)
at async f (/app/.next/server/app/dashboard/(route)/[slug]/page.js:1:6955)
Error fetching from Tautulli API. The query was 'get_library_media_info'.
Error: Tautulli API request failed: 500 Internal Server Error
at s (/app/.next/server/app/api/auth/[...nextauth]/route.js:1:6117)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async Promise.all (index 5)
at async d (/app/.next/server/app/rewind/page.js:1:31575)
at async Promise.all (index 3)
at async g (/app/.next/server/app/rewind/page.js:1:33498)
Error: Tautulli API request failed: 500 Internal Server Error
at s (/app/.next/server/app/api/auth/[...nextauth]/route.js:1:6117)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async Promise.all (index 5)
at async d (/app/.next/server/app/rewind/page.js:1:31575)
at async Promise.all (index 3)
at async g (/app/.next/server/app/rewind/page.js:1:33498)
Error fetching from Tautulli API. The query was 'get_library_media_info'.
Error: Tautulli API request failed: 500 Internal Server Error
at s (/app/.next/server/app/api/auth/[...nextauth]/route.js:1:6117)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async Promise.all (index 0)
Error fetching from Tautulli API. The query was 'get_library_media_info'.
Error: Tautulli API request failed: 500 Internal Server Error
at s (/app/.next/server/app/api/auth/[...nextauth]/route.js:1:6117)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async Promise.all (index 2)
Error fetching from Tautulli API. The query was 'get_library_media_info'.
Error: Tautulli API request failed: 500 Internal Server Error
at s (/app/.next/server/app/api/auth/[...nextauth]/route.js:1:6117)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async Promise.all (index 4)
desktop
Desktop
Windows 10
Firefox 121.0.1 (64-bit)
Will enable the user to navigate more easily, akin to Instagram Stories/Spotify Wrapped
Currently all the configuration for the app has to be done inside .env
. It works, but it's not very user friendly.
Additionally, since .env
is bundled at build time, it is blocking #32 due to missing variables at build time.
Upon first booting up the app, the user is greeted with a configuration screen where he can set up his variables. After these are set, the user can later change them under a settings page.
We should make sure that settings are persisted after updating.
Often times these types of applications will be deployed as a complement to a full stack of applications that use Plex to authenticate users.
It would be very useful to be able to have SSO for these scenarios to provide a better user experience.
SSO providers include Organize, Authentik, etc.
A user signs in through an authentication done upstream where a cookie with the Plex token is set, e.g. X-Plex-Token
plex-rewind then looks for this cookie and authenticates the user session thereby skipping the login page.
I would be happy to test out assist with developing this feature. I am not very familiar with nextjs so if you can point me in the right direction I'll be happy to take a stab at it!
Currently when getting libraries total values, for example in movies Rewind, we get the stats for the section_id
of the first library from all libraries array that matches type movie
. Same is true for the rest of the Rewind total stats and Dashboard user statistics.
Currently, we're showing library size even when it's 0, there's no point in doing that.
No response
desktop
N/A
N/A
N/A
No response
Would make sense to have a refresh button available.
Either a pull-down to mimic browser functionality (a.la Overseerr) or a separate refresh button.
No response
Testing feature request template
Testing feature request template
Additonal context
Looks like there's quite a bit of community interest in this:
https://www.reddit.com/r/PleX/comments/18pd48j/comment/kenv74z/?utm_source=share&utm_medium=web2x&context=3
I have a login for my admin account on Plex that no one uses but I use a managed user and because I use the login of the admin account to access my managed user I cannot see the rewind for the managed user.
Improve loading states, so that we only show loaders for data that's actually fetching.
The issue only occurs when you scroll fast (flick). It's most likely due to the Story reading it as a click event, which in turn triggers the prev/next Story action. Maybe we can add some sort of a short timeout before the click action is run?
No response
No response
smartphone
iPhone 13 mini
iOS 17.2.1
Safari
No response
Need to implement some type of login to allow users on the same server to access the app.
We should consider publishing an already built Docker image instead of having the user build it.
This project is currently the best to show an overall dashboard to users all year. But i want to hide statistics in dashboard such as number of plays and number of users who watched a specific item. I think like everything else using an env variable for this is the best way but It would be great even if there is a pointer to implement by changing inside code in any way first?
Using an env variable, users can tweak few things off that appear in dashboard
No response
I forked the project and got it up and running to the login with plex page but plex returns "We were unable to complete this request.
You will be redirected automatically." and the goes to plex.tv.
We should be able to optionally set the year for which we want to see the Rewind for.
Currently it's showing it for the ongoing year only.
The Rewind year could be set in the .env file.
No response
I've got multiple servers and my users use both. Is it possible to refactor this to allow for multiple tautulli servers, and combine the information from them all?
The app is currently expecting your Plex libraries to have section_id
of 3 for movies, 2 for shows and 1 for music.
v1.8.6
Returns the following in docker logs:
⨯ Error: 'sharp' is required to be installed in standalone mode for the image optimization to function correctly. Read more at: https://nextjs.org/docs/messages/sharp-missing-in-production
TypeError: Cannot read properties of undefined (reading 'id')
at /app/.next/server/app/rewind/page.js:1:36458
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async Promise.all (index 2)
at async o (/app/.next/server/app/rewind/page.js:1:36246)
at async m (/app/.next/server/app/rewind/page.js:1:32508)
at async Promise.all (index 0)
at async g (/app/.next/server/app/rewind/page.js:1:33471)
current .env
NODE_ENV=production
2
3 NEXT_PUBLIC_TAUTULLI_URL=http://192.168.1.99:8181
4 TAUTULLI_API_KEY=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
5 NEXT_PUBLIC_OVERSEERR_URL=0.0.0.0:5055
6 OVERSEERR_API_KEY=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxZi1hMmY3LTM5NTJmMzUzZDYwYyk
7 TMDB_API_KEY=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
8 PLEX_HOSTNAME=192.168.1.99
9 PLEX_PORT=32400
10
11 NEXT_PUBLIC_SITE_URL=http://192.168.1.99:8383
12 NEXTAUTH_URL=http://192.168.1.99:8383
13 NEXTAUTH_SECRET=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
14
15 NEXT_PUBLIC_GOOGLE_ANALYTICS_ID=
16 NEXT_PUBLIC_IS_REWIND_DISABLED=false
17 NEXT_PUBLIC_IS_DASHBOARD_DISABLED=false
18 NEXT_PUBLIC_IS_DASHBOARD_USERS_DISABLED=false
19 NEXT_PUBLIC_EXCLUDED_DASHBOARD_STATS=
20 NEXT_PUBLIC_EXCLUDED_LIBRARIES=
21 NEXT_PUBLIC_STATISTICS_START_DATE=2018-01-01
⨯ Error: 'sharp' is required to be installed in standalone mode for the image optimization to function correctly. Read more at: https://nextjs.org/docs/messages/sharp-missing-in-production
TypeError: Cannot read properties of undefined (reading 'id')
at /app/.next/server/app/rewind/page.js:1:36458
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async Promise.all (index 2)
at async o (/app/.next/server/app/rewind/page.js:1:36246)
at async m (/app/.next/server/app/rewind/page.js:1:32508)
at async Promise.all (index 0)
at async g (/app/.next/server/app/rewind/page.js:1:33471)
On the last run this appended to the error:
[Error: An error occurred in the Server Components render. The specific message is omitted in production builds to avoid leaking sensitive details. A digest property is included on this error instance which may provide additional details about the nature of the error.] {
digest: '3846803662'
desktop
Desktop
Ubuntu 22.04
Firefox 121.0 Chrome 120.0.6099.200
No response
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.