-
Notifications
You must be signed in to change notification settings - Fork 200
Open
Description
Describe the Bug
The Libraries disappear from Plex WebUI and Apps everytime I use a PlexApi script. However I dont see any errors in Plex service or logs. The Libraries appear after I restart the Plex Service, which is a bit tedious to do every time.
Ths issue specifically come after runng the "switchUser" class from PlexServer:
userPlex = plex.switchUser("Normal User")
Code Snippets
from plexapi.server import PlexServer
baseurl = 'http://192.168.1.1:32400'
token = 'xxxxxxxxxxxxxx'
plex = PlexServer(baseurl, token)
userPlex = plex.switchUser("MyUser")
library = ['My Movies','Tv Shows']
for lib in library:
print(lib,'\n')
movies = userPlex.library.section(lib)
for video in movies.search(userRating=1):
print("Deleting: ", video.title, "Rating: ", video.userRating)
print(video.locations)
#video.deleteExpected Behavior
Plex Libraries should not disappear after running plexapi's switchuser function.
Additional Context
No response
Operating System and Version
Raspbian GNU/Linux 11 (bullseye) Kernel 6.1.47-v8+ aarch64 GNU/Linux
Plex Media Server Version
Version 4.116.1
Python Version
Python 3.9.2
PlexAPI Version
4.15.7
Metadata
Metadata
Assignees
Labels
No labels
