m5n / netflix-queue-sorter

Greasemonkey script for Chrome, Firefox, Opera, Safari: shuffle, reverse, and sort your DVD Queue or Instant Queue by star rating, average rating, title, length, year, genre, format, availability, playability, language, etc.
MIT License
28 stars 3 forks source link

Average Ratings doesn't work anymore #1

Closed wsheng closed 10 years ago

wsheng commented 10 years ago

Maybe the markup changed?

m5n commented 10 years ago

I only have the Instant plan and it works for me there: http://www.netflix.com/MyList Unfortunately I cannot test the page for the DVD plan. What is the URL you're running the script on and which browser are you using?

Could you enable debug mode and capture the output? Here are the steps:

Let me know if you run into trouble.

matt-henderson commented 10 years ago

URL: http://dvd.netflix.com/Queue?prioritized=true&qtype=DD Average sort:

prepSort: [{"command":"sort","fields":["avgRating","starRating","title"],"sortFns":["defaultSortFn","defaultSortFn","defaultSortFn"],"dirs":[-1,-1,1]}] VM178:248

Fetch queue data retrievers need. VM178:248 Retrieved 498 elts VM178:248 netflix-queue: retrieved data: [{"order":1,"movieId":70098149,"seriesId":70087091,"title":"JOHN ADAMS: DISC 1","starRating":3.9,"genre":"Drama","availability":""},{"order":2,"movieId":70100380,"title":"CURIOUS CASE OF BENJAMIN BUTTON, THE","starRating":3.1,"genre":"Drama","availability":""},{"order":3,"movieId":70059639,"title":"IN THE SHADOW OF THE MOON","starRating":3.9,"genre":"Documentary","availability":"VERY LONG WAIT"},{"order":4,"movieId":70114342,"title":"BOOK OF ELI, THE","starRating":3,"genre":"Action & Adventure","availability":""},{"order":5,"movieId":332286,"title":"BRIDGE TOO FAR, A","starRating":3,"genre":"Action & Adventure","availability":""}] VM178:248 netflix-queue: backup fields: {"starRating2":"starRating"} VM178:248 netflix-queue: series lookup: {"70087091":{"order":1,"movieId":70098149,"seriesId":70087091,"title":"JOHN ADAMS: DISC 1","starRating":3.9,"genre":"Drama","availability":""}} VM178:248 netflix-queue: backup data to retrieve: {} VM178:248 netflix-queue: extra retrievers to call: [] VM178:248 data for retrievers: [{"order":1,"movieId":70098149,"seriesId":70087091,"title":"JOHN ADAMS: DISC 1","starRating":3.9,"genre":"Drama","availability":""},{"order":2,"movieId":70100380,"title":"CURIOUS CASE OF BENJAMIN BUTTON, THE","starRating":3.1,"genre":"Drama","availability":""},{"order":3,"movieId":70059639,"title":"IN THE SHADOW OF THE MOON","starRating":3.9,"genre":"Documentary","availability":"VERY LONG WAIT"},{"order":4,"movieId":70114342,"title":"BOOK OF ELI, THE","starRating":3,"genre":"Action & Adventure","availability":""},{"order":5,"movieId":332286,"title":"BRIDGE TOO FAR, A","starRating":3,"genre":"Action & Adventure","availability":""}] VM178:248

Fetch retriever data. VM178:248 Retrieve fields: ["avgRating","starRating","title"] from: netflix-details-page VM178:248 Retrieving: http://dvd.netflix.com/Movie/70098149 VM178:248 Uncaught TypeError: Cannot read property 'innerHTML' of undefined VM178:712 NetflixDetailsPageRetriever.extractRating VM178:712 NetflixDetailsPageRetriever.extractAvgRating VM178:728 parsePage VM178:1075 req.onreadystatechange

matt-henderson commented 10 years ago

URL: http://dvd.netflix.com/Queue?prioritized=true&qtype=DD Star/Average sort: prepSort: [{"command":"sort","fields":["avgRating","starRating","title"],"sortFns":["defaultSortFn","defaultSortFn","defaultSortFn"],"dirs":[-1,-1,1]}] VM178:248

Fetch queue data retrievers need. VM178:248 Retrieved 498 elts VM302:248 netflix-queue: retrieved data: [{"order":1,"movieId":70098149,"seriesId":70087091,"title":"JOHN ADAMS: DISC 1","starRating":3.9,"genre":"Drama","availability":""},{"order":2,"movieId":70100380,"title":"CURIOUS CASE OF BENJAMIN BUTTON, THE","starRating":3.1,"genre":"Drama","availability":""},{"order":3,"movieId":70059639,"title":"IN THE SHADOW OF THE MOON","starRating":3.9,"genre":"Documentary","availability":"VERY LONG WAIT"},{"order":4,"movieId":70114342,"title":"BOOK OF ELI, THE","starRating":3,"genre":"Action & Adventure","availability":""},{"order":5,"movieId":332286,"title":"BRIDGE TOO FAR, A","starRating":3,"genre":"Action & Adventure","availability":""}] VM178:248 netflix-queue: backup fields: {"starRating2":"starRating"} VM178:248 netflix-queue: series lookup: {"70087091":{"order":1,"movieId":70098149,"seriesId":70087091,"title":"JOHN ADAMS: DISC 1","starRating":3.9,"genre":"Drama","availability":""}} VM178:248 netflix-queue: backup data to retrieve: {} VM178:248 netflix-queue: extra retrievers to call: [] VM178:248 data for retrievers: [{"order":1,"movieId":70098149,"seriesId":70087091,"title":"JOHN ADAMS: DISC 1","starRating":3.9,"genre":"Drama","availability":""},{"order":2,"movieId":70100380,"title":"CURIOUS CASE OF BENJAMIN BUTTON, THE","starRating":3.1,"genre":"Drama","availability":""},{"order":3,"movieId":70059639,"title":"IN THE SHADOW OF THE MOON","starRating":3.9,"genre":"Documentary","availability":"VERY LONG WAIT"},{"order":4,"movieId":70114342,"title":"BOOK OF ELI, THE","starRating":3,"genre":"Action & Adventure","availability":""},{"order":5,"movieId":332286,"title":"BRIDGE TOO FAR, A","starRating":3,"genre":"Action & Adventure","availability":""}] VM178:248 Fetch retriever data. VM178:248 Retrieve fields: ["avgRating","starRating","title"] from: netflix-details-page VM178:248 Retrieving: http://dvd.netflix.com/Movie/70098149 VM178:248 Uncaught TypeError: Cannot read property 'innerHTML' of undefined VM178:712 NetflixDetailsPageRetriever.extractRating VM178:712 NetflixDetailsPageRetriever.extractAvgRating VM178:728 parsePage VM178:1075 req.onreadystatechange

matt-henderson commented 10 years ago

URL: http://dvd.netflix.com/Queue?qtype=DD&fcld=true Length sort: prepSort: [{"command":"sort","fields":["length","title"],"sortFns":["defaultSortFn","defaultSortFn"],"dirs":[1,1]}] VM382:248

Fetch queue data retrievers need. VM382:248 Retrieved 498 elts VM382:248 netflix-queue: retrieved data: [{"order":1,"movieId":70098149,"seriesId":70087091,"title":"JOHN ADAMS: DISC 1","starRating":3.9,"genre":"Drama","availability":""},{"order":2,"movieId":70100380,"title":"CURIOUS CASE OF BENJAMIN BUTTON, THE","starRating":3.1,"genre":"Drama","availability":""},{"order":3,"movieId":70059639,"title":"IN THE SHADOW OF THE MOON","starRating":3.9,"genre":"Documentary","availability":"VERY LONG WAIT"},{"order":4,"movieId":70114342,"title":"BOOK OF ELI, THE","starRating":3,"genre":"Action & Adventure","availability":""},{"order":5,"movieId":332286,"title":"BRIDGE TOO FAR, A","starRating":3,"genre":"Action & Adventure","availability":""}] VM382:248 netflix-queue: backup fields: {} VM382:248 netflix-queue: series lookup: {} VM382:248 netflix-queue: backup data to retrieve: {} VM382:248 netflix-queue: extra retrievers to call: [] VM382:248 data for retrievers: [{"order":1,"movieId":70098149,"seriesId":70087091,"title":"JOHN ADAMS: DISC 1","starRating":3.9,"genre":"Drama","availability":""},{"order":2,"movieId":70100380,"title":"CURIOUS CASE OF BENJAMIN BUTTON, THE","starRating":3.1,"genre":"Drama","availability":""},{"order":3,"movieId":70059639,"title":"IN THE SHADOW OF THE MOON","starRating":3.9,"genre":"Documentary","availability":"VERY LONG WAIT"},{"order":4,"movieId":70114342,"title":"BOOK OF ELI, THE","starRating":3,"genre":"Action & Adventure","availability":""},{"order":5,"movieId":332286,"title":"BRIDGE TOO FAR, A","starRating":3,"genre":"Action & Adventure","availability":""}] VM382:248

Fetch retriever data. VM382:248 Retrieve fields: ["length","title"] from: netflix-details-page VM382:248 Retrieving: http://dvd.netflix.com/Movie/70098149 VM382:248 Uncaught TypeError: Cannot read property 'innerHTML' of undefined VM382:712 NetflixDetailsPageRetriever.extractRating VM382:712 NetflixDetailsPageRetriever.extractAvgRating VM382:728 parsePage VM382:1075 req.onreadystatechange

matt-henderson commented 10 years ago

URL: http://dvd.netflix.com/Queue?qtype=DD&fcld=true Year sort: prepSort: [{"command":"sort","fields":["year","title"],"sortFns":["defaultSortFn","defaultSortFn"],"dirs":[-1,1]}] VM664:248

Fetch queue data retrievers need. VM664:248 Retrieved 498 elts VM664:248 netflix-queue: retrieved data: [{"order":1,"movieId":70098149,"seriesId":70087091,"title":"JOHN ADAMS: DISC 1","starRating":3.9,"genre":"Drama","availability":""},{"order":2,"movieId":70100380,"title":"CURIOUS CASE OF BENJAMIN BUTTON, THE","starRating":3.1,"genre":"Drama","availability":""},{"order":3,"movieId":70059639,"title":"IN THE SHADOW OF THE MOON","starRating":3.9,"genre":"Documentary","availability":"VERY LONG WAIT"},{"order":4,"movieId":70114342,"title":"BOOK OF ELI, THE","starRating":3,"genre":"Action & Adventure","availability":""},{"order":5,"movieId":332286,"title":"BRIDGE TOO FAR, A","starRating":3,"genre":"Action & Adventure","availability":""}] VM664:248 netflix-queue: backup fields: {} VM664:248 netflix-queue: series lookup: {} VM664:248 netflix-queue: backup data to retrieve: {} VM664:248 netflix-queue: extra retrievers to call: [] VM664:248 data for retrievers: [{"order":1,"movieId":70098149,"seriesId":70087091,"title":"JOHN ADAMS: DISC 1","starRating":3.9,"genre":"Drama","availability":""},{"order":2,"movieId":70100380,"title":"CURIOUS CASE OF BENJAMIN BUTTON, THE","starRating":3.1,"genre":"Drama","availability":""},{"order":3,"movieId":70059639,"title":"IN THE SHADOW OF THE MOON","starRating":3.9,"genre":"Documentary","availability":"VERY LONG WAIT"},{"order":4,"movieId":70114342,"title":"BOOK OF ELI, THE","starRating":3,"genre":"Action & Adventure","availability":""},{"order":5,"movieId":332286,"title":"BRIDGE TOO FAR, A","starRating":3,"genre":"Action & Adventure","availability":""}] VM664:248

Fetch retriever data. VM664:248 Retrieve fields: ["year","title"] from: netflix-details-page VM664:248 Retrieving: http://dvd.netflix.com/Movie/70098149 VM664:248 Uncaught TypeError: Cannot read property 'innerHTML' of undefined VM664:712 NetflixDetailsPageRetriever.extractRating VM664:712 NetflixDetailsPageRetriever.extractAvgRating VM664:728 parsePage VM664:1075 req.onreadystatechange

m5n commented 10 years ago

Hi Matt, could you go to your queue, and click on "John Adams: Disc 1". Then please "View Source" and send it to me. Hopefully that'll let me figure out what HTML changes were made. Thanks!

m5n commented 10 years ago

Email received, thanks Matt. I uploaded v2.102 (on GitHub as Userscripts.org is down), could you give it a try?

matt-henderson commented 10 years ago

Yes, thanks! The sorts work now!

m5n commented 10 years ago

Excellent!