rvs76 / tvdblib

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

GetEpisode #17

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
I think there's an issue with the cache. Here is what I've found:

I found that if I already have the episode downloaded (and in the cache)
and then call :

tvdbhandler.getepisode(seriesid, season, episode#, ...,...,...) 

that it will instead return something like this is supposed to return:

tvdbhandler.getepisode(seriesid, MAXSEASON, episode#, ...,...,...)

I got different results depending on the "order" clause, but it seemed to
always vary somewhat--though always wrong:

For example, I was using the shows Futurama and 30 Rock. I then called

TvdbHandler.GetSeries(idofshow, DefaultLanguage, true, false true);
that obviously returns all of the proper information and I was able to
iterate through it with a foreach loop and add each item to a listview for
example and see the proper information.

Afterwards, I call TvdbHandler.GetEpisode(id, 2, 3, DefaultOrder,
DefaultLanguage). 

What I expect to get back is a an episode equal to Season#2 Episode#3,
However what I get back is an episode equal to, in the case of futurama,
Season #6 Episode #3  or in the case of 30 Rock, Season #3 Episode #3 
where the season numbers in both cases is the Max(SeasonNumber) 

Again, if I then called TvdbHandler.GetEpisode(id, 1, 3, DefaultOrder,
DefaultLanguage) I would get back Season #6, Episode #3 (in futurama's
case) or Season #3, Episode #3 (in the case of 30 rock) [same results as
above]. Notice the episode number seems to always come back as the correct
episode #, just in the wrong season.

I tried it again later with different ordering (DVD, I believe it was) and
I got Season#1 Episode#3 in both cases.

If I called TvdbHandler.ClearCache() and then used GetEpisode( ) as listed
above, I then received the correct information.

Original issue reported on code.google.com by hul...@gmail.com on 30 Jun 2009 at 2:34

GoogleCodeExporter commented 9 years ago
I see this may be intended in ID #16. In my project I SOMETIMES need the whole 
series
and SOMETIMES I don't, which is why I use both GetSeries() and GetEpisode() in
different areas of my application. Occasionally use of the program will result 
in the
features overlapping.

Original comment by hul...@gmail.com on 30 Jun 2009 at 2:39

GoogleCodeExporter commented 9 years ago

Original comment by bgmei...@gmail.com on 30 Jun 2009 at 10:09

GoogleCodeExporter commented 9 years ago
Should be fixed with commit r105. Can you check if you run into any problems 
with the
attached version?

Original comment by bgmei...@gmail.com on 30 Jun 2009 at 11:29

Attachments:

GoogleCodeExporter commented 9 years ago
Fixes it, except it either adds a new problem or I've found a new problem. will 
post
the issue in a second.

Original comment by hul...@gmail.com on 30 Jun 2009 at 7:41