get_imdbMovieID never returns ID

43 views
Skip to first unread message

Fabian Winter

unread,
Mar 19, 2013, 6:29:52 AM3/19/13
to imdbpy...@googlegroups.com
Hi ,

I am trying to get the imdb IDs for some of my sql entries, but instead of the id, I get an error which seems to be related to the mobile parser.
 

i = IMDb('sql', uri='mysql://xxx:x...@yyy.yyy.yyy.yyy/imdb')
>>> i.get_movie(2272426)
<Movie id:2272426[sql] title:_Terminator 3: Rise of the Machines (2003)_>
>>> i.get_imdbMovieID(2272426)2013-03-19 11:07:10,325 ERROR [imdbpy.parser.mobile] C:\Python27\lib\site-packages\imdb\parser\mobile\__init__.py:205: no direct hit title/movieID for title Find - IMDb




The movie id exists in the sql database, but retreiving the imdb_id doesn't work. 



Searching for "Terminator 3: Rise of the Machines" via sql works, 

>>> i.search_movie("Terminator 3: Rise of the Machines")
[<Movie id:2272427[sql] title:_Terminator 3: Rise of the Machines (2003) (VG)_>, <Movie id:2272426[sql] title:_Terminator 3: Rise of the Machines (2003)_>, <Movie id:1220315[sql] title:_"Terminator Salvation: The Machinima Series" (2009)_>, <Movie id:2272424[sql] title:_Terminator 2: The Arcade Game (1993) (VG)_>, <Movie id:1220322[sql] title:_"Terminator: The Sarah Connor Chronicles" (2008)_>, <Movie id:2272442[sql] title:_Terminator: The Last Battle (2006) (V)_>, <Movie id:2272425[sql] title:_Terminator 3: Redemption (2004) (VG)_>, <Movie id:2350942[sql] title:_The Terminator: Dawn of Fate (2002) (VG)_>, <Movie id:2272422[sql] title:_Terminator 2: Judgment Day (1991)_>, <Movie id:2272432[sql] title:_Terminator Salvation (2009)_>, <Movie id:2350941[sql] title:_The Terminator: Anatoly Onoprienko (2007) (TV)_>, <Movie id:2272438[sql] title:_Terminator Salvation: Maximum Movie Mode (2009) (V)_>, <Movie id:2458003[sql] title:_Terminator 2: Judgment Day (1992) (VG)_>, <Movie id:2361637[sql] title:_Theorem: A Dream of Change (1984)_>, <Movie id:2272423[sql] title:_Terminator 2: Judgment Day (1991) (VG)_>, <Movie id:2272428[sql] title:_Terminator 3: Sky Net Database (2003) (V)_>, <Movie id:2381455[sql] title:_TrinityRoots Music Is Choice (2010)_>, <Movie id:2272855[sql] title:_Terror in the Outer Zone (2005)_>, <Movie id:2187855[sql] title:_Rudranetra (1989)_>, <Movie id:1767117[sql] title:_Det er ikke appelsiner, det er heste (1967)_>]




but searching via http (or mobile) returns an empty set as well...

>>> i = IMDb('http')
>>> i.search_movie("Terminator 3: Rise of the Machines")
    
[]


>>> ... i = IMDb('mobile')
>>> i.search_movie("Terminator 3: Rise of the Machines")
[]
2013-03-19 11:28:29,520 ERROR [imdbpy.parser.mobile] C:\Python27\lib\site-packages\imdb\parser\mobile\__init__.py:205: no direct hit title/movieID for title Find - IMDb



Any suggestions?

Fabian

Davide Alberani

unread,
Mar 19, 2013, 2:48:23 PM3/19/13
to imdbpy...@googlegroups.com, Fabian Winter
On Tue, Mar 19, 2013 at 11:29 AM, Fabian Winter
<winter....@googlemail.com> wrote:
>
> I am trying to get the imdb IDs for some of my sql entries, but instead of
> the id, I get an error which seems to be related to the mobile parser.

Yep, a mobile search for the title is done and the first result (if it's the
only one) or the first perfect match (if more than one) is used to get
the imdbID.

> but searching via http (or mobile) returns an empty set as well...

Are you sure to be using the latest version from the repository?
I get different results. For 'http':
[<Movie id:0181852[http] title:_Terminator 3: Rise of the Machines
(2003)_>, <Movie id:0364056[http] title:_Terminator 3: Rise of the
Machines (2003) (VG)_>, <Movie id:0391240[http] title:_Inside
'Terminator 3: Rise of the Machines' (2003) (TV)_>, <Movie
id:0498209[http] title:_"HBO First Look" Inside 'Terminator 3: Rise of
the Machines' (2003)_>]

For 'mobile':
[<Movie id:0181852[mobile] title:_Terminator 3: Rise of the Machines
(2003)_>, <Movie id:0364056[mobile] title:_Terminator 3: Rise of the
Machines (2003) (VG)_>, <Movie id:0391240[mobile] title:_Inside
'Terminator 3: Rise of the Machines' (2003) (TV)_>, <Movie
id:0498209[mobile] title:_"HBO First Look" Inside 'Terminator 3: Rise
of the Machines' (2003)_>]

Maybe adding loggingLevel='debug' to your imdb.IMDb() will provide more
information.


--
Davide Alberani <davide....@gmail.com> [PGP KeyID: 0x465BFD47]
http://www.mimante.net/
Reply all
Reply to author
Forward
0 new messages