We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
PlexClient
PlexServer
An unexpected argument is passed to PlexClient when server sessions are parsed.
>>> plex = PlexServer(...) >>> plex.sessions() Traceback (most recent call last): File "<stdin>", line 1, in <module> File "/home/jjlawren/src/plexapi/plexapi/server.py", line 817, in sessions return self.fetchItems('/status/sessions') File "/home/jjlawren/src/plexapi/plexapi/base.py", line 257, in fetchItems subresults = self.findItems(data, cls, ekey, **kwargs) File "/home/jjlawren/src/plexapi/plexapi/base.py", line 330, in findItems item = self._buildItemOrNone(elem, cls, initpath) File "/home/jjlawren/src/plexapi/plexapi/base.py", line 109, in _buildItemOrNone return self._buildItem(elem, cls, initpath) File "/home/jjlawren/src/plexapi/plexapi/base.py", line 101, in _buildItem return ecls(self._server, elem, initpath, parent=self) File "/home/jjlawren/src/plexapi/plexapi/base.py", line 62, in __init__ self._loadData(data) File "/home/jjlawren/src/plexapi/plexapi/video.py", line 1188, in _loadData PlexSession._loadData(self, data) File "/home/jjlawren/src/plexapi/plexapi/base.py", line 904, in _loadData self.player = self.findItem(data, etag='Player') File "/home/jjlawren/src/plexapi/plexapi/base.py", line 341, in findItem return self.findItems(data, cls, initpath, rtag, **kwargs)[0] File "/home/jjlawren/src/plexapi/plexapi/base.py", line 330, in findItems item = self._buildItemOrNone(elem, cls, initpath) File "/home/jjlawren/src/plexapi/plexapi/base.py", line 109, in _buildItemOrNone return self._buildItem(elem, cls, initpath) File "/home/jjlawren/src/plexapi/plexapi/base.py", line 101, in _buildItem return ecls(self._server, elem, initpath, parent=self) TypeError: __init__() got an unexpected keyword argument 'parent'
No response
This avoids the issue, but I'm unclear if this is the proper fix:
diff --git a/plexapi/client.py b/plexapi/client.py index 279b497..a1bf292 100644 --- a/plexapi/client.py +++ b/plexapi/client.py @@ -62,7 +62,7 @@ class PlexClient(PlexObject): key = '/resources' def __init__(self, server=None, data=None, initpath=None, baseurl=None, - identifier=None, token=None, connect=True, session=None, timeout=None): + identifier=None, token=None, connect=True, session=None, timeout=None, parent=None): super(PlexClient, self).__init__(server, data, initpath) self._baseurl = baseurl.strip('/') if baseurl else None self._clientIdentifier = identifier
Linux
Any
3.9
4.15.8
The text was updated successfully, but these errors were encountered:
Issue introduced by #1328.
Sorry, something went wrong.
Successfully merging a pull request may close this issue.
Describe the Bug
An unexpected argument is passed to
PlexClient
when server sessions are parsed.Code Snippets
Expected Behavior
No response
Additional Context
This avoids the issue, but I'm unclear if this is the proper fix:
Operating System and Version
Linux
Plex Media Server Version
Any
Python Version
3.9
PlexAPI Version
4.15.8
The text was updated successfully, but these errors were encountered: