Skip to content
This repository has been archived by the owner on Oct 11, 2022. It is now read-only.

Traktflix reports "invalid URL" when manually pasting URL from Trakt #148

Open
brycied00d opened this issue Jul 7, 2020 · 0 comments
Open

Comments

@brycied00d
Copy link

brycied00d commented Jul 7, 2020

Chrome 84.0.4147.38
Traktflix 2.1.1

Netflix URL: https://www.netflix.com/watch/81209539
Trakt URL: https://trakt.tv/movies/patton-oswalt-i-love-everything-2020

image

Traktflix fails to find a match so I provide the URL to Trakt manually and click "Update Item". The response is the error "An error happened, please make sure you are entering a valid URL and try again"

Chrome's inspector panel shows Traktflix making 2 requests after I click "Update item":

This seems to make sense, it's listed as a "movie" on Trakt so a 404 from Trakt's "/shows" endpoint is logical.

Based on the API Netflix's "viewingactivity" API response viewedItems:

{"title":"Special: \"Patton Oswalt: I Love Everything\"","videoTitle":"Patton Oswalt: I Love Everything","movieID":81209539,"country":"US","bookmark":3925,"duration":4002,"date":1593830508487,"deviceType":1731,"dateStr":"7/3/20","index":2,"topNodeId":"81206879","series":81206879,"seriesTitle":"Patton Oswalt: I Love Everything","seasonDescriptor":"Special","episodeTitle":"Patton Oswalt: I Love Everything","estRating":"18"}

And src/class/NetflixApiUtils.js'

const type = typeof activity.series === `undefined` ? `movie` : `show`;
we understand why Traktflix interpreted this as a "show" from Netflix's API response (because the "movie" has a "series" element).

The discrepancy between Netflix and Trakt is not the issue I'm raising, however. The issue I'm raising is that a URL that I, the the user, have painstakingly and meticulously gone to the effort to procure (okay so it was a simple Trakt search), and verify that it's the correct Trakt URL, is "invalid". I believe that Traktflix should "assume" that the user's manual override is correct and valid, at least so long as Trakt returns a valid API response with JSON object.

Please let me know how else I can assist troubleshooting and resolving this.

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

No branches or pull requests

1 participant