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

Can't sync liked playlists : unexpected keyword argument 'type' #941

Closed
2 tasks done
steffenbb opened this issue Jun 16, 2022 · 13 comments · Fixed by #1124
Closed
2 tasks done

Can't sync liked playlists : unexpected keyword argument 'type' #941

steffenbb opened this issue Jun 16, 2022 · 13 comments · Fixed by #1124
Labels
bug Something isn't working

Comments

@steffenbb
Copy link

steffenbb commented Jun 16, 2022

Confirmation

  • I have read the README.md on the project homepage
  • I have checked if identical issue already exists

The problem

Hello, I'm trying to set up the python script, I've succesfully got it working with another trakt account (different computer) with my liked lists and everything. Now I've freshly installed python and the script on a different computer, but whenever I try to sync (with having liked playlists on trakt) the following happens. If I unlike them on trakt and run the script again, it succeeds.

Error trace / logs

console log: 
INFO     PlexTraktSync [0.20.x]
Sync Movie sections: [<PlexLibrarySection:movie:Concerts>, <PlexLibrarySection:movie:Documentarys>, <PlexLibrarySection:movie:Movies>]
Traceback (most recent call last):
  File "C:\Users\lulu\AppData\Local\Programs\Python\Python37\lib\runpy.py", line 193, in _run_module_as_main
    "__main__", mod_spec)
  File "C:\Users\lulu\AppData\Local\Programs\Python\Python37\lib\runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "C:\PlexTraktSync\Lulu\plextraktsync\__main__.py", line 18, in <module>
    cli()
  File "C:\Users\lulu\AppData\Local\Programs\Python\Python37\lib\site-packages\click\core.py", line 1130, in __call__
    return self.main(*args, **kwargs)
  File "C:\Users\lulu\AppData\Local\Programs\Python\Python37\lib\site-packages\click\core.py", line 1055, in main
    rv = self.invoke(ctx)
  File "C:\Users\lulu\AppData\Local\Programs\Python\Python37\lib\site-packages\click\core.py", line 1635, in invoke
    rv = super().invoke(ctx)
  File "C:\Users\lulu\AppData\Local\Programs\Python\Python37\lib\site-packages\click\core.py", line 1404, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "C:\Users\lulu\AppData\Local\Programs\Python\Python37\lib\site-packages\click\core.py", line 760, in invoke
    return __callback(*args, **kwargs)
  File "C:\Users\lulu\AppData\Local\Programs\Python\Python37\lib\site-packages\click\decorators.py", line 26, in new_func
    return f(get_current_context(), *args, **kwargs)
  File "C:\PlexTraktSync\Lulu\plextraktsync\cli.py", line 46, in cli
    sync()
  File "C:\Users\lulu\AppData\Local\Programs\Python\Python37\lib\site-packages\click\core.py", line 1130, in __call__
    return self.main(*args, **kwargs)
  File "C:\Users\lulu\AppData\Local\Programs\Python\Python37\lib\site-packages\click\core.py", line 1055, in main
    rv = self.invoke(ctx)
  File "C:\Users\lulu\AppData\Local\Programs\Python\Python37\lib\site-packages\click\core.py", line 1404, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "C:\Users\lulu\AppData\Local\Programs\Python\Python37\lib\site-packages\click\core.py", line 760, in invoke
    return __callback(*args, **kwargs)
  File "C:\PlexTraktSync\Lulu\plextraktsync\cli.py", line 28, in wrap
    cmd(*args, **kwargs)
  File "C:\PlexTraktSync\Lulu\plextraktsync\commands\sync.py", line 60, in sync
    runner.sync(walker=w, dry_run=config.dry_run)
  File "C:\PlexTraktSync\Lulu\plextraktsync\sync.py", line 64, in sync
    listutil.addList(lst["username"], lst["listname"])
  File "C:\PlexTraktSync\Lulu\plextraktsync\trakt_list_util.py", line 88, in addList
    self.lists.append(TraktList(username, listname))
  File "C:\PlexTraktSync\Lulu\plextraktsync\trakt_list_util.py", line 47, in __init__
    for elem in LazyUserList._get(listname, username)._items
  File "C:\Users\lulu\AppData\Local\Programs\Python\Python37\lib\site-packages\trakt\core.py", line 554, in inner
    return generator.send(json_data)
  File "C:\PlexTraktSync\Lulu\plextraktsync\trakt_list_util.py", line 35, in _get
    ulist = LazyUserList(creator=creator, **data)
TypeError: __new__() got an unexpected keyword argument 'type'

plextraktsync.log:
2022-06-16 15:12:58,091 INFO[PlexTraktSync]:PlexTraktSync [0.20.x]

Expected behavior

Expect the script to go through even if there's liked scripts on trakt

Steps to reproduce the behavior

Like a list on trakt
Run sync command

Inspect of problematic items

No response

Workarounds

Not having liked lists on trakt

Install method

zip download

Version

0.20.1

Python Version

3.10.5

Operating System and Version

Windows 11

@steffenbb steffenbb closed this as not planned Won't fix, can't repro, duplicate, stale Jun 16, 2022
@steffenbb steffenbb reopened this Jun 16, 2022
@steffenbb
Copy link
Author

Just updated python hence the edit, still same issue

@simonc56
Copy link
Collaborator

There's been an update of Trakt API on 14 June 2022 adding a type value to lists :

Each list object contains a type value set to personal or official.

See official trakt changelog.

We will need to wait for a PyTrakt update to solve this.

@simonc56
Copy link
Collaborator

This was referenced Jun 30, 2022
@simonc56 simonc56 changed the title Can't sync with liked playlists Can't sync with liked playlists : unexpected keyword argument 'type' Jul 1, 2022
@simonc56 simonc56 pinned this issue Jul 1, 2022
@simonc56 simonc56 changed the title Can't sync with liked playlists : unexpected keyword argument 'type' Can't sync liked playlists : unexpected keyword argument 'type' Jul 1, 2022
@simonc56 simonc56 added the bug Something isn't working label Jul 1, 2022
@memnos
Copy link

memnos commented Jul 21, 2022

Has this been solved? Is there anyone manages to sync? I cannot.

@simonc56
Copy link
Collaborator

simonc56 commented Jul 21, 2022

We have to wait until PyTrakt maintainer get back and update its trakt module.
You can go there and upvote the Maintenance issue.

@ashepp
Copy link

ashepp commented Jul 21, 2022

Apologies for not checking for dupe / following template. Will track this thread.
I'm not clear on if there's a short term fix or whether we have to wait for the PyTraky fix?
Whenever I try and run the container I'm getting the following error in the console (I reinstalled and still get the same).

Error response from daemon: Container 86b194fdf69e42e5b0fc69e1a416e037e4748d133b6591148f220e441467d416 is not running.

Log shows the same as reported previously regarding missing type.

Any suggestions?

@simonc56
Copy link
Collaborator

simonc56 commented Jul 21, 2022

For now you can disable liked_lists and watchlist sync in config file.

@ashepp

This comment was marked as off-topic.

@simonc56

This comment was marked as off-topic.

@marksie1988
Copy link

I updated pytrakt locally as per the PR, I assume additional changes are also needed to plextraktsync for it to work?

@YDeltagon
Copy link

any news ?

@abb0r
Copy link

abb0r commented Aug 30, 2022

For now you can disable liked_lists and watchlist sync in config file.

I disabled it, but still get the error.

@glensc

This comment was marked as outdated.

@simonc56 simonc56 unpinned this issue Oct 29, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
8 participants