jbmoore1216 / embermediamanager

Automatically exported from code.google.com/p/embermediamanager
0 stars 0 forks source link

imdb rating not pulled #58

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
I guess it's better to open a ticket for this and debug it here.

So actually none of my freshly scraped movie has the imdb rating.
It's not just a gui misunderstanding, as the created .nfo don't include it
as well:

<?xml version="1.0" encoding="utf-8"?>
<movie xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xsd="http://www.w3.org/2001/XMLSchema">
  <id>tt0286516</id>
  <title>Respiro</title>
  <originaltitle>Respiro</originaltitle>
  <year>2002</year>
  <rating>0</rating>
  <votes>2,378</votes>
  <mpaa>Rated PG-13 for nudity and thematic elements.</mpaa>
  <top250 />
  <outline>On an impoverished Italian island, a free-spirited woman is
accused of madness by townspeople fed up with her antics.</outline>

Original issue reported on code.google.com by nadas.bence@gmail.com on 22 May 2009 at 7:11

GoogleCodeExporter commented 8 years ago
Looking at the code, the only way the rating would be set to "0" is through the 
edit
dialog.... and only if it couldn't convert the rating to an actual number. Can 
you do
me a favor and remove all current sources, then add only that movie folder as a
source (if you have all of your movies in one folder, you'll need to make a 
folder
for that movie and copy it into it), then use the automatic update to rescan it
(can't use rescrape or else the movie editor pops up). After than, tell me what 
the
nfo shows the rating as.

Maybe IMDB displays the pages differently for different countries? Wait.... I 
bet
that's it. Does IMDB show the rating using a , or a .? For instance, does it 
show
4,9/10 or 4.9/10. If it shows with a comma, then that's the problem. Easy fix. 
Please
let me know.

Original comment by jason.schnitzler on 22 May 2009 at 8:46

GoogleCodeExporter commented 8 years ago
Fixed this for next version, but I'm in the middle of making custom Cert/MPAA 
images
so I can't upload to SVN yet. Maybe another hour or so.

Original comment by jason.schnitzler on 22 May 2009 at 9:14

GoogleCodeExporter commented 8 years ago
hmmmmm, there seems to be a multiple/ mixed problems here.

Actually I was wrong. Sorry for this.
The reason why I mixed up the symphtoms:

 - IMDB rating is always going to be pulled during auto-update
 - During single re-scrape it's not going to be pulled at all. In this case .nfo is
always created with "0" at rating tag
 - Ratings are never displayed in the GUI. Nor in browsing window, nor in edit
window. Nor with stars, nor in numeric way.

Original comment by nadas.bence@gmail.com on 22 May 2009 at 9:24

GoogleCodeExporter commented 8 years ago
It's because you use a comma as a decimal point and not a period. The code was
written around periods, so it wasn't able to convert the rating to a usable 
number.
It should work with the next SVN version... once I get it uploaded.

Original comment by jason.schnitzler on 22 May 2009 at 9:29

GoogleCodeExporter commented 8 years ago
OK, I will test it tomorrow morning. I am going to bed now.

Just a thought, something to you to verify.
I guess the decimal point fix will correct the bug concerning display the 
rating on
the gui.

However I think the issue with single scraping is an other bug to check. As I
mentioned it always returns 0, while auto-update is pulling the rating fine.
Or is this also becuase of the decimal issue?

Original comment by nadas.bence@gmail.com on 22 May 2009 at 9:41

GoogleCodeExporter commented 8 years ago
yep, they're all the same issue. When you do auto update it just dumps the 
rating as
found on IMDB into the nfo. When you single scrape, it puts it into the movie 
editor
first. Since the movie editor couldn't convert it to a number format it would 
just
make it a 0. Then when you hit ok, it saves that 0 to the nfo.

Original comment by jason.schnitzler on 22 May 2009 at 9:46

GoogleCodeExporter commented 8 years ago
Ahhh, ok, now I understand.

Thank you for your patient explanation.

Original comment by nadas.bence@gmail.com on 22 May 2009 at 9:55

GoogleCodeExporter commented 8 years ago
Ok... it's in the SVN now.

Original comment by jason.schnitzler on 22 May 2009 at 10:34

GoogleCodeExporter commented 8 years ago
It's still not ok, with the same symphtom.

Original comment by nadas.bence@gmail.com on 23 May 2009 at 5:55

GoogleCodeExporter commented 8 years ago
What is the format of the rating on IMDB for you? Is it #.# or #,#? I tried 
both and
they work for me. Can you do an update auto or ask and see what the rating is 
in the
nfo without opening the movie editor?

Original comment by jason.schnitzler on 23 May 2009 at 6:01

GoogleCodeExporter commented 8 years ago
During auto-update, the nfo created by "." 
If I looked at imdb, I see the rating with ".".

But I have "," as decimal separator in windows/regional settings.

Original comment by nadas.bence@gmail.com on 23 May 2009 at 6:08

GoogleCodeExporter commented 8 years ago
hmmmm ok... that helps. I was looking at it the opposite way, where IMDB is 
using a
comma but the program tries to use a period. In fact, IMDB is using a period 
and the
program is trying to use a comma.... but I have it hard coded as period. I'll 
have to
think of a way to fix that one.

Original comment by jason.schnitzler on 23 May 2009 at 6:14

GoogleCodeExporter commented 8 years ago
Ok, should be fixed for real in r133. Thanks for your help in figuring this out!

Original comment by jason.schnitzler on 23 May 2009 at 7:41

GoogleCodeExporter commented 8 years ago
It still returns 0 on single-scrape and ratings are not showing on the gui

Original comment by nadas.bence@gmail.com on 23 May 2009 at 9:09

GoogleCodeExporter commented 8 years ago
Ok, yet another attempt to fix this is in the SVN.

Original comment by jason.schnitzler on 23 May 2009 at 6:25

GoogleCodeExporter commented 8 years ago
Nope... still not working fully.... aaaaaaaaalmost there.

Original comment by jason.schnitzler on 23 May 2009 at 6:45

GoogleCodeExporter commented 8 years ago
That should do it. Now I can switch my computer back to English (U.S.). lol 
It's hard
to type when my keyboard is trying to type French (especially since I don't know
French lol)

Original comment by jason.schnitzler on 23 May 2009 at 6:54

GoogleCodeExporter commented 8 years ago
wooohhooooooo, you get it, it's there! 

Thank you for the hard trying! 

Now I am just confused a little bit how you converted the 10 points imdb scale 
to a 5
stars scale. lol

Original comment by nadas.bence@gmail.com on 23 May 2009 at 7:41

GoogleCodeExporter commented 8 years ago
That's where all the problems come from. lol If it was just showing 10 stars it 
would
be fine, but I divide the rating by 2 (5 stars fits the interface a little 
better
than 10). The division/comparison was causing the error if the end user's 
computer
used a comma for a decimal separator. To fix it, I just temporarily change the
decimal separator to a period.

Marking as verified. Thanks!!

Original comment by jason.schnitzler on 23 May 2009 at 7:48