trakt-tools / universal-trakt-scrobbler

MIT License
551 stars 54 forks source link

Error with Netflix-Sync #265

Closed crazy-daddy closed 1 year ago

crazy-daddy commented 1 year ago

When trying to import my Netflix history it throws me back to the selection screen. Here's the log from Chrome: ehlckfimahifadnbecobagimllmbdmde-1674136387599.log

I also tried Firefox - this spits out: ff.log

I'm not really sure how to extract more useful logs - very happy to try if someone could point me to a how-to or sth. like that :-)

justkorix commented 1 year ago

Came here to say this, it almost feels like it gets overloaded. I'm trying to import years of Netflix history so my assumption is that that is maybe just not possible? Would be cool if there was a way to manually import

crazy-daddy commented 1 year ago

Would have been my assumption as well - it dies when scrolling down. But it doesn't seem to be an API-lockout, as I can immediately retry and it fails at the same location (would expect it to fail right at the start if it were a lockout of some sort).

AviDuda commented 1 year ago

I'm getting the same issue. It's because of these lines checking for summary.

It seems that unavailable IDs (doesn't matter if it's a season or not) don't have the summary in the response.
Example here with Superstore not being available anymore in my country (Czech Republic):

Toggle response from pathEvaluator

```json { "value": { "videos": { "81059939": { "seasonList": { "current": [ "seasons", "81165490" ] } }, "81425010": { "releaseYear": 2022, "summary": { "idx": 1, "id": 81425010, "type": "episode", "isOriginal": true, "episode": 1, "season": 1, "isPlayable": true, "$type": "leaf" } }, "81471764": { "releaseYear": 2020 }, "81471765": { "releaseYear": 2020 }, "81471766": { "releaseYear": 2020 }, "81471767": { "releaseYear": 2020 }, "81471768": { "releaseYear": 2020 }, "81471769": { "releaseYear": 2020 }, "81471770": { "releaseYear": 2020 }, "81471771": { "releaseYear": 2020 }, "81471772": { "releaseYear": 2020 } }, "seasons": { "81165490": { "summary": { "id": 81165490, "name": "Heartstopper", "shortName": "S1", "hiddenEpisodeNumbers": false, "length": 8, "$type": "leaf" } } } }, "error": { "innerErrors": [ { "message": "OnError while emitting onNext value: [Lrx.Observable;.class", "pql": [ "videos", [ 81471772 ], "summary" ] }, { "message": "OnError while emitting onNext value: [Lrx.Observable;.class", "pql": [ "videos", [ 81471771 ], "summary" ] }, { "message": "OnError while emitting onNext value: [Lrx.Observable;.class", "pql": [ "videos", [ 81471770 ], "summary" ] }, { "message": "OnError while emitting onNext value: [Lrx.Observable;.class", "pql": [ "videos", [ 81471769 ], "summary" ] }, { "message": "OnError while emitting onNext value: [Lrx.Observable;.class", "pql": [ "videos", [ 81471768 ], "summary" ] }, { "message": "OnError while emitting onNext value: [Lrx.Observable;.class", "pql": [ "videos", [ 81471767 ], "summary" ] }, { "message": "OnError while emitting onNext value: [Lrx.Observable;.class", "pql": [ "videos", [ 81471766 ], "summary" ] }, { "message": "OnError while emitting onNext value: [Lrx.Observable;.class", "pql": [ "videos", [ 81471765 ], "summary" ] }, { "message": "OnError while emitting onNext value: [Lrx.Observable;.class", "pql": [ "videos", [ 81471764 ], "summary" ] } ] }, "paths": [ [ "videos", "81425010", [ "releaseYear", "summary" ] ], [ "videos", "81471772", [ "releaseYear", "summary" ] ], [ "videos", "81471771", [ "releaseYear", "summary" ] ], [ "videos", "81471770", [ "releaseYear", "summary" ] ], [ "videos", "81471769", [ "releaseYear", "summary" ] ], [ "videos", "81471768", [ "releaseYear", "summary" ] ], [ "videos", "81471767", [ "releaseYear", "summary" ] ], [ "videos", "81471766", [ "releaseYear", "summary" ] ], [ "videos", "81471765", [ "releaseYear", "summary" ] ], [ "videos", "81471764", [ "releaseYear", "summary" ] ], [ "videos", "81059939", "seasonList", "current", "summary" ], [ "videos", "80061132", "seasonList", "current", "summary" ] ] } ```

MrMamen commented 1 year ago

Interesting. The lines were supposed to fix this issue #232

AviDuda commented 1 year ago

Ah I see, the Firefox addon wasn't updated for almost 2 months (last update on Dec 10, 2022), so this fix merged on January 6 isn't available there. I tried running it locally, it worked. And for Chrome, there's currently no GitHub release as seen in #270, but I guess it would work there too.

MrMamen commented 1 year ago

Sorry. I forgot to run the release manually again. Please verify and close if it works.

AviDuda commented 1 year ago

The manual installation from the provided release works for me.

crazy-daddy commented 1 year ago

Managed to set up node.js and compiled it here. It still crashed so I tried my non-existent JS skills and tried to dump pretty much everything I could think of...

Very much the same error as #232 but slightly different flavor. Crashing item is:

{ "bookmark": 1212, "country": "DE", "date": 1653675501341, "dateStr": "5/27/22", "deviceType": 1725, "duration": 1560, "episodeTitle": "Benjamin Blümchen im Krankenhaus", "estRating": "47", "index": 13, "movieID": 80227732, "seasonDescriptor": "Season 2", "series": 80227721, "seriesTitle": "Benjamin Blümchen", "title": "Season 2: \"Benjamin Blümchen im Krankenhaus\"", "topNodeId": "80227721", "videoTitle": "Benjamin Blümchen im Krankenhaus", "releaseYear": 2002, "season": { "summary": { "id": 81620106, "name": "Season 5", "shortName": "S5", "hiddenEpisodeNumbers": false, "length": 6, "$type": "leaf" } } },

So here the whole "summary" property is missing. My naïve solution would be season = historyItem.summary?.season || 0; number = historyItem.summary?.episode || 0;

This works for me. Created a PR - though I'm highly inexperienced with TS, so please triplecheck if that breaks sth. :-)