Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

No User is passed through when playing #2115

Open
simonk83 opened this issue Oct 2, 2024 · 9 comments
Open

No User is passed through when playing #2115

simonk83 opened this issue Oct 2, 2024 · 9 comments

Comments

@simonk83
Copy link

simonk83 commented Oct 2, 2024

Help yourself

Describe the bug

When playing media, the current user doesn't seem to be passed through to plex (this is causing issues with a third party tool I'm using, Notifiarr, as it needs the current user for tracking etc)

@austinwbest

(Tagging Austin from Notifiarr as we were troubleshooting this earlier and he could see some useful info from his end)

Screenshot 2024-10-02 at 8 40 36 AM

To Reproduce

Steps to reproduce the behavior:

  1. Start something playing
  2. Go to the Dashboard in Plex
  3. See lack of user

Expected behavior

Current user should be displayed

You need to attach a KODI LOG FILE!

A Kodi debug log file is needed that you recorded while you reproduced the bug. Do clean your log of all Plex tokens (="Plex passwords")!!! .

  1. Activate Kodi's debug logging by going to the Kodi Settings -> System -> Logging. Then toggle the Enable debug logging setting.
  2. Restart Kodi to start with a "fresh" log file.
  3. Reproduce the bug.
  4. Follow the Kodi instructions to grab/share the Kodi log file. Usually only kodi.log is needed
  5. Delete all references to any of your Plex tokens by searching for X-Plex-Token and accesstoken and replacing the strings just after that!
    • It's easiest if you copy your token, then use Search&Replace for the entire log file
    • You don't want others to have access to your Plex installation....
  6. Drop your log file here in this issue. Or use a free pasting-service like https://pastebin.com and include the link to it here

kodi.log

I am aware that I can delete Plex tokens that I accidentially posted by following the instructions on the PKC wiki

@croneter
Copy link
Owner

croneter commented Oct 4, 2024

Thanks for the issue. What does the PMS do? Does it somehow mark playback progress for the wrong user, e.g. the main PMS user/"admin" instead of a home user?

@simonk83
Copy link
Author

simonk83 commented Oct 4, 2024

Thanks for the issue. What does the PMS do? Does it somehow mark playback progress for the wrong user, e.g. the main PMS user/"admin" instead of a home user?

I only have the one local user at the moment (the admin/me) so it does mark it correctly, but let me create a new user and see what happens there. I guess I should log into pkc with the new user rather than the admin user?

@croneter
Copy link
Owner

croneter commented Oct 4, 2024

Check both please. Please check whether playback progress is marked for the correct user on the PMS side of things. And maybe even what the PMS is reporting as "Currently playing" (your screenshot above)

@austinwbest
Copy link

austinwbest commented Oct 5, 2024

The completely missing user information from the plex API when using the PKC is the concern. Anything which consumes that information simply cant function. Trakt sync based on users, session management based on users, etc

Below is a snip from the plex session api response

[Player]
    [address] => 192.168.1.109
    [device] => 
    [local] => 1
    [machineIdentifier] => ef6811...-28a75cad8e97
    [model] => 
    [platform] => Generic
    [platformVersion] => 1.0.0
    [product] => PlexKodiConnect
    [profile] => Generic
    [relayed] => 
    [remotePublicAddress] => ...
    [secure] => 1
    [state] => playing
    [stateTime] => 1
    [title] => Kodi
    [userID] => 1
    [vendor] => 
    [version] => 3.10.4
[User]
    [id] => 
    [thumb] => 
    [title] => 
[addedAt] => 1726965378
[art] => /library/metadata/63236/art/1726965380```

@croneter
Copy link
Owner

croneter commented Oct 5, 2024

@austinwbest can you share how that API response looks like for other Plex players where everything works please?

@austinwbest
Copy link

Sure bud, here is a couple. I can likely find them for just about any device but i think you'll get the idea. There are basically two kinds of usernames that it should send

  • Home user
  • Plex user

So home users will typically be normal names (first example below "Kye") and plex users are the accounts you make with plex.tv since home users do not have a plex.tv account

Shield

[Player]
	[address] =>  [removed]
	[device] => SHIELD Android TV
	[local] => 1
	[machineIdentifier] => c4cda9a42a370521-com-plexapp-android
	[model] => sif
	[platform] => Android
	[platformVersion] => 11
	[product] => Plex for Android (TV)
	[profile] => Android
	[relayed] => 
	[remotePublicAddress] =>  [removed]
	[secure] => 1
	[state] => playing
	[stateTime] => 4369
	[title] => Family Shield
	[userID] => 46365618
	[vendor] => NVIDIA
	[version] => 10.22.0.1579
[User]
	[id] => 46365618
	[thumb] => https://plex.tv/users/e5a19b4e6b8af5a0/avatar?c=1728127188
	[title] => Kye

LG Smart TV

[Player]
	[address] =>  [removed]
	[device] => webOS 3.9.0
	[local] => 1
	[machineIdentifier] => qpfr9zrvsj9ssjors7vn12eg
	[model] => OLED65C7T-T
	[platform] => webOS
	[platformVersion] => 3.9.0
	[product] => Plex for LG
	[profile] => 
	[relayed] => 
	[remotePublicAddress] =>  [removed]
	[secure] => 
	[state] => playing
	[stateTime] => 1
	[title] => LG OLED65C7T-T
	[userID] => 1
	[vendor] => LG
	[version] => 5.88.1
[User]
	[id] => 1
	[thumb] => https://plex.tv/users/31a52c7ac53832fd/avatar?c=1728075603
	[title] => simonk83

Chrome browser

[Player]
	[address] =>  [removed]
	[device] => Windows
	[local] => 
	[machineIdentifier] => y4eo25yb919lcagethmicli2
	[model] => hosted
	[platform] => Chrome
	[platformVersion] => 129.0
	[product] => Plex Web
	[profile] => Web
	[relayed] => 
	[remotePublicAddress] =>  [removed]
	[secure] => 1
	[state] => playing
	[stateTime] => 1
	[title] => Chrome
	[userID] => 24319218
	[vendor] => 
	[version] => 4.139.0
[User]
	[id] => 24319218
	[thumb] => [removed]
	[title] => chad_r7

@simonk83
Copy link
Author

simonk83 commented Oct 6, 2024

Apologies I've been away for a few days, I'll try and get the details later tonight (if you still need them? Perhaps not judging from the above)

@austinwbest
Copy link

austinwbest commented Oct 6, 2024

The above is just 3 other devices that pass in the user info since examples where asked for.

The problem is still relevant where this player is not passing any user info to plex

Edit: I realized after i answered you where just talkign about the examples. Yea, that part should be handled above

@simonk83
Copy link
Author

simonk83 commented Oct 10, 2024

Ok, interesting. With the admin user logged into PKC, it doesn't pass through a user (as above). With a home user selected as below, it does pass it through:

image

IMG_7291

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants