[Imdbpy-help] Cinemagoer 2023.05.01

2023-05-01 Thread Davide Alberani
Hi all,
We have just released version 2023.05.01 of Cinemagoer.

It mostly consists of many little fixes to the parsers.
The complete changelog:
https://github.com/cinemagoer/cinemagoer/blob/master/CHANGELOG.txt

As usual, any help is welcome!

-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/


___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


[Imdbpy-help] Cinemagoer 2022.12.04

2022-12-04 Thread Davide Alberani
Hi,
I've release version 2022.12.04 of Cinemagoer:
https://github.com/cinemagoer/cinemagoer/releases/tag/2022.12.04

It's also available on pypi.

There are a lot of bug fixed, especially for the latest changes that
broke searches and person parsers.

Please notice that the person parser will now return a limited amount
of data: the list of movies for each role is now limited to the latest
15 titles, and there is not much we can do about it.

There are surely a lot of other bugs, but now most of the features
should work again.

As always, any help is welcome!

-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/


___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] intermittent Error 405

2022-11-22 Thread Davide Alberani
Hi Ben,
There's an issue for this:
https://github.com/cinemagoer/cinemagoer/issues/415

A possible fix was already committed, we will see if it's enough.

Hope this helps,

Il mar 22 nov 2022, 14:15 Ben Co  ha scritto:

> Hello,
>
> Since yesterday, I'm facing an intermittent 405 error when wearching for
> movies with search_movie  method.
>
> This doesn't happen all the time, and with several IP addresses.
>
> Here is the whole exception stack:
>
> 2022-11-22 14:13:24,863 CRITICAL [imdbpy]
> C:\tools\Anaconda3\lib\site-packages\imdb\_exceptions.py:32:
> IMDbDataAccessError exception raised; args: ({'errcode': None, 'errmsg':
> 'None', 'url': 'https://www.imdb.com/find?q=Taxi+2&s=tt', 'proxy': '',
> 'exception type': 'IOError', 'original exception':  Allowed'>},); kwds: {}
> Traceback (most recent call last):
>   File
> "C:\tools\Anaconda3\lib\site-packages\imdb\parser\http\__init__.py", line
> 221, in retrieve_unicode
> response = uopener.open(url)
>   File "C:\tools\Anaconda3\lib\urllib\request.py", line 523, in open
> response = meth(req, response)
>   File "C:\tools\Anaconda3\lib\urllib\request.py", line 632, in
> http_response
> response = self.parent.error(
>   File "C:\tools\Anaconda3\lib\urllib\request.py", line 561, in error
> return self._call_chain(*args)
>   File "C:\tools\Anaconda3\lib\urllib\request.py", line 494, in _call_chain
> result = func(*args)
>   File "C:\tools\Anaconda3\lib\urllib\request.py", line 641, in
> http_error_default
> raise HTTPError(req.full_url, code, msg, hdrs, fp)
> urllib.error.HTTPError: HTTP Error 405: Not Allowed
> Traceback (most recent call last):
>   File
> "C:\tools\Anaconda3\lib\site-packages\imdb\parser\http\__init__.py", line
> 221, in retrieve_unicode
> response = uopener.open(url)
>   File "C:\tools\Anaconda3\lib\urllib\request.py", line 523, in open
> response = meth(req, response)
>   File "C:\tools\Anaconda3\lib\urllib\request.py", line 632, in
> http_response
> response = self.parent.error(
>   File "C:\tools\Anaconda3\lib\urllib\request.py", line 561, in error
> return self._call_chain(*args)
>   File "C:\tools\Anaconda3\lib\urllib\request.py", line 494, in _call_chain
> result = func(*args)
>   File "C:\tools\Anaconda3\lib\urllib\request.py", line 641, in
> http_error_default
> raise HTTPError(req.full_url, code, msg, hdrs, fp)
> urllib.error.HTTPError: HTTP Error 405: Not Allowed
>
> During handling of the above exception, another exception occurred:
>
> Traceback (most recent call last):
>   File "", line 1, in 
>   File "C:\tools\Anaconda3\lib\site-packages\imdb\__init__.py", line 450,
> in search_movie
> res = self._search_movie(title, results)
>   File
> "C:\tools\Anaconda3\lib\site-packages\imdb\parser\http\__init__.py", line
> 409, in _search_movie
> cont = self._get_search_content('tt', title, results)
>   File
> "C:\tools\Anaconda3\lib\site-packages\imdb\parser\http\__init__.py", line
> 397, in _get_search_content
> cont = self._retrieve(self.urls['find'] % params)
>   File
> "C:\tools\Anaconda3\lib\site-packages\imdb\parser\http\__init__.py", line
> 380, in _retrieve
> ret = self.urlOpener.retrieve_unicode(url, size=size)
>   File
> "C:\tools\Anaconda3\lib\site-packages\imdb\parser\http\__init__.py", line
> 249, in retrieve_unicode
> raise IMDbDataAccessError(
> imdb._exceptions.IMDbDataAccessError: {'errcode': None, 'errmsg': 'None',
> 'url': 'https://www.imdb.com/find?q=Taxi+2&s=tt', 'proxy': '', 'exception
> type': 'IOError', 'original exception': }
>
> ___
> Imdbpy-help mailing list
> Imdbpy-help@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/imdbpy-help
>
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Can't add an isssue to GitHub

2022-10-15 Thread Davide Alberani
Hi Ben,
pardon the long delay.

I think this bug was already fixed in the repository, please try using
the latest version.

To install from Github: pip install git+https://github.com/cinemagoer/cinemagoer


Hope this helps,

On Tue, Oct 4, 2022 at 6:52 PM Ben Co  wrote:
>
> Hello,
>
>
>
> I’m a user of Cinemagoer, and I encountered a bug using it, but I don’t know 
> why, I can’t create a new issue on GitHub (submit button remains disabled). 
> So here below is the issue (in the format that is asked for on GitHub).
>
> And thanks for this library !
>
>
>
>  Issue description
>
>
>
> Search movie by title fails when searching for "Serenity"
>
>
>
>
>
>  Version of Cinemagoer, Python and OS
>
>
>
> **NOTICE: please always try the latest version from the repository before 
> submitting a bug.**
>
>
>
> - **Python:** 3.9.13
>
> - **Cinemagoer:** 2022.02.11
>
> - **OS:** system='Windows', release='10', version='10.0.22621', 
> machine='AMD64'
>
>
>
>
>
>  Steps to reproduce the issue
>
>
>
> *if possible, provide a minimal code to reproduce the problem*
>
>
>
> ```python
>
> #!/usr/bin/env python
>
>
>
> # your code here
>
> import imdb
>
> ia = imdb.Cinemagoer()
>
> movies = ia.search_movie('Serenity')
>
> ```
>
>
>
>  What's the expected result?
>
>
>
> - No exception raised
>
>
>
>
>
>  What's the actual result?
>
> 2022-10-04 16:40:19,435 CRITICAL [imdbpy] 
> C:\tools\Anaconda3\lib\site-packages\imdb\_exceptions.py:32: IMDbParserError 
> exception raised; args: ('invalid title: """"',); kwds: {}
>
> NoneType: None
>
> Traceback (most recent call last):
>
>   File "D:\Utilisateurs\benco\Desktop\Drive In\test.py", line 3, in 
>
> movies = ia.search_movie('Serenity')
>
>   File "C:\tools\Anaconda3\lib\site-packages\imdb\__init__.py", line 444, in 
> search_movie
>
> res = self._search_movie(title, results)
>
>   File "C:\tools\Anaconda3\lib\site-packages\imdb\parser\http\__init__.py", 
> line 409, in _search_movie
>
> return self.smProxy.search_movie_parser.parse(cont, 
> results=results)['data']
>
>   File "C:\tools\Anaconda3\lib\site-packages\imdb\parser\http\utils.py", line 
> 434, in parse
>
> data = self.parse_dom(dom)
>
>   File "C:\tools\Anaconda3\lib\site-packages\imdb\parser\http\utils.py", line 
> 526, in parse_dom
>
> return Rules(self.rules).extract(dom)
>
>   File "C:\tools\Anaconda3\lib\site-packages\imdb\parser\http\piculet.py", 
> line 373, in extract
>
> value = self.apply(element)
>
>   File "C:\tools\Anaconda3\lib\site-packages\imdb\parser\http\piculet.py", 
> line 517, in apply
>
> extracted = rule.extract(subroot)
>
>   File "C:\tools\Anaconda3\lib\site-packages\imdb\parser\http\piculet.py", 
> line 589, in extract
>
> list(map(self.extractor.transform, values))
>
>   File 
> "C:\tools\Anaconda3\lib\site-packages\imdb\parser\http\searchMovieParser.py", 
> line 64, in 
>
> analyze_title(x.get('info', '')),
>
>   File "C:\tools\Anaconda3\lib\site-packages\imdb\utils.py", line 327, in 
> analyze_title
>
> series_d = analyze_title(series_title, canonical=canonicalSeries)
>
>   File "C:\tools\Anaconda3\lib\site-packages\imdb\utils.py", line 432, in 
> analyze_title
>
> raise IMDbParserError('invalid title: "%s"' % original_t)
>
> imdb._exceptions.IMDbParserError: invalid title: """"
>
>
>
>  Additional details
>
> ___
> Imdbpy-help mailing list
> Imdbpy-help@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/imdbpy-help



-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/


___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Duplicate titles, other issues

2022-01-01 Thread Davide Alberani
Hi,
As a minor update I've updated the answer in
https://stackoverflow.com/a/70549011/253358
to take care of how the Django templates work.

On Sat, Jan 1, 2022 at 1:48 PM Davide Alberani
 wrote:
>
> Hi Joseph,
>
> You are iterating over k1, v1 of a dict with the format
> {'movie_110': }
> Then you iterate over the keys and values k2, v2 of the Movie instance
> (which behaves like a dict)
> From there, you filter only the k2 keys which contains 'title'; there
> are various, like 'title', 'canonical title',
> 'long imdb canonical title' and various others (see the
> _additional_keys method of the Movie class).
> And then you print its value.
>
> You don't need the second for cycle.
> Just print v1['title'] or the key that you need (you can obviously
> check if it exists, beforehand).
>
>
> Hope this helps,
>
>
>
>
> On Fri, Dec 31, 2021 at 3:50 PM Joseph H  wrote:
> >
> > Hello--
> >
> > I am putting together a project utilizing IMDBPy. The early issues I'm 
> > having I've covered on StackOverflow, although not all of what I mention 
> > there is specific to IMDBPy. One of the big problems I've encountered is 
> > with duplicate titles appearing, as you can see here:
> >
> >
> > I'm using Django templating language to create the output, like so:
> >
> >
> >
> > I just don't understand why there are so many redundant titles for the same 
> > movie id. I would like to remove them if possible. I was thinking about 
> > utilizing the fuzzywuzzy package to recognize similarity in titles, and 
> > remove redundancies, but I also don't fully understand why they exist in 
> > the first place. When I run a print statement for the little "slice" of 
> > movie title database that I've created, it shows 15 objects, just like I'd 
> > anticipated. And when I encounter the problem with displaying only unique 
> > titles later on, many of the titles ARE similar, but not the same, i.e. 
> > like "Animal House" and "Animal House (1978)".
> >
> > I can provide further background on the project if you desire.
> >
> > Many thanks for any insight that you can provide!
> >
> > Joseph Hooker
> > ___
> > Imdbpy-help mailing list
> > Imdbpy-help@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/imdbpy-help
>
>
>
> --
> Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
> http://www.mimante.net/



-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/


___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Duplicate titles, other issues

2022-01-01 Thread Davide Alberani
Hi Joseph,

You are iterating over k1, v1 of a dict with the format
{'movie_110': }
Then you iterate over the keys and values k2, v2 of the Movie instance
(which behaves like a dict)
>From there, you filter only the k2 keys which contains 'title'; there
are various, like 'title', 'canonical title',
'long imdb canonical title' and various others (see the
_additional_keys method of the Movie class).
And then you print its value.

You don't need the second for cycle.
Just print v1['title'] or the key that you need (you can obviously
check if it exists, beforehand).


Hope this helps,




On Fri, Dec 31, 2021 at 3:50 PM Joseph H  wrote:
>
> Hello--
>
> I am putting together a project utilizing IMDBPy. The early issues I'm having 
> I've covered on StackOverflow, although not all of what I mention there is 
> specific to IMDBPy. One of the big problems I've encountered is with 
> duplicate titles appearing, as you can see here:
>
>
> I'm using Django templating language to create the output, like so:
>
>
>
> I just don't understand why there are so many redundant titles for the same 
> movie id. I would like to remove them if possible. I was thinking about 
> utilizing the fuzzywuzzy package to recognize similarity in titles, and 
> remove redundancies, but I also don't fully understand why they exist in the 
> first place. When I run a print statement for the little "slice" of movie 
> title database that I've created, it shows 15 objects, just like I'd 
> anticipated. And when I encounter the problem with displaying only unique 
> titles later on, many of the titles ARE similar, but not the same, i.e. like 
> "Animal House" and "Animal House (1978)".
>
> I can provide further background on the project if you desire.
>
> Many thanks for any insight that you can provide!
>
> Joseph Hooker
> ___
> Imdbpy-help mailing list
> Imdbpy-help@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/imdbpy-help



-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/


___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Request to Implement imdb api in My project

2021-08-28 Thread Davide Alberani
Hi Y'S,
nice project!

You don't need any permission to use the IMDbPY code.

However, you have to respect the IMDb license and terms of service:
https://www.imdb.com/conditions

IMDbPY is in no way affiliated with IMDb, and we do not own the data.
If the project is not for commercial use, I would not worry too much,
but I'm not a lawyer.


Best regards.

On Wed, Aug 18, 2021 at 6:38 AM Y'S  wrote:
>
> Project name :  Telegram AutoFilterBot
> Project Url : https://github.com/VaishnavMS/TGautofilterimdb
>
> Author : VaishnavMS
>
>
> This is a python code for a telegram bot which later function as Telegram 
> Autofilter bot(suggest YouTube for more details).
> The autofilter functions as if when the user ask for a word the telegram 
> button with url of filtered content from connected channel will be shown as 
> the reply to user. I want the imdb plugin to add on this reply such that when 
> the user  searches movies, the imdb details shown as  similiar to that of 
> imdb bot with the buttons..
> Like this :
> ___
> Imdbpy-help mailing list
> Imdbpy-help@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/imdbpy-help



-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/


___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


[Imdbpy-help] IMDbPY 2021.04.18

2021-04-18 Thread Davide Alberani
Hi,
thanks to many contributors we are releasing IMDbPY 2021.04.18.

It can be downloaded from
https://github.com/alberanid/imdbpy/releases/tag/2021.04.18

As always, any contribution to the code is welcome.

* What's new in release 2021.04.18 (Black Sails)
  [general]
  - #289: Serbian translations
  - #290: update Portuguese translations
  - #291: allow direct access to filmography keys
  - #299: add pagination to get_movie_list
  - #300: any iterable can be used as season_nums parameter of
update_series_seasons
  - #305: fix ability to set logging level
  - #310: fix build of locales .mo files
  - #312: extract localized title

  [sql]
  - #287: fix missing logger


-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/


___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


[Imdbpy-help] IMDbPY 2020.09.25

2020-09-25 Thread Davide Alberani
Hi,
I hope everyone is doing fine in this complicated timeline.

I've just released IMDbPY 2020.09.25, since the last official release
was over a year old.

There are many fixes and some improvements, and we also switched to a
calendar versioning schema.


All the best.

-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/


___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] s32imdbpy.py Error message: "'charmap' codec can't encode character"

2020-09-21 Thread Davide Alberani
Hi Ambrose,

Can you specify the complete command line and the database you are using?

Yes, I fear you have lost 1000 entries for each error.

I'm not sure about the root cause of the problem; maybe you need to specify
some additional parameter to the database URI?
See https://imdbpy.readthedocs.io/en/latest/usage/s3.html for an example.

Another obvious source of information is the logs of the database.
Anything useful there?

Hope this helps,

On Thu, Sep 17, 2020 at 12:21 PM Ambrose Chapel
 wrote:
>
> I'm running the s32imdbpy.py script to import the gz files into my SQL 
> database.
>
> I'm seeing this error a lot, example, when processing name.basics.tsv.gz:
>
> ERROR::error processing data: 1 entries lost: 'charmap' codec 
> can't encode characters in position 0-9: character maps to 
>
>
> My database table is set to charset utf8_unicode_ci as per instructions.
>
> I guess my obvious question is how can I prevent this, but also, have I 
> really lost 1,000 database entries? Or have I got those 1,000 database 
> entries in my database but with some problem unicode characters missing, and 
> the message is misleading?
>
> TIA
> ___
> Imdbpy-help mailing list
> Imdbpy-help@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/imdbpy-help



-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/


___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] new project using IMDbPY

2020-08-29 Thread Davide Alberani
Hi Nikolaos,
that's really cool!  Nice project, and great post: I've added it to
the list of IMDbPY-based papers. :-)


Thanks.

On Tue, Aug 25, 2020 at 12:22 PM Nikolaos Diamantis  wrote:
>
> https://nikos7am.com/posts/movie_connections_quiz/
> "A movie connection quiz in Python"
> by Nikolaos Diamantis.
> Using Python to create movie quizzes.
>
> Best regards and thanks for your awesome work and module!
> Nikos
>
> ___
> Imdbpy-help mailing list
> Imdbpy-help@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/imdbpy-help



-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/


___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] [error found] getting imdb award data

2020-07-24 Thread Davide Alberani
Hi Min,
I've replied in the Github issue:
https://github.com/alberanid/imdbpy/issues/277

Hope this helps.

On Tue, Jul 21, 2020 at 9:39 AM Min Seong  wrote:

> [image: result.png]
> Hello IMDbpy, I'm writing a thesis using IMDb data and having trouble
> getting award data.
> I wanted to get an award data of stars but it keeps showing the error
> message above.
>
> Do you know which part of the code is wrong? or is it a bug in the library?
>
> Thank you.
>
> Min Seong
>
> e-mail: min91...@gmail.com
> ___
> Imdbpy-help mailing list
> Imdbpy-help@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/imdbpy-help
>


-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Issue with Top 250 TV shows in IMDbPy

2020-07-24 Thread Davide Alberani
Hi Evan,
the other methods were introduced 3 months ago; if you need them, you
should install the version from the Github repository.


Hope this helps.

On Sat, Jul 18, 2020 at 9:45 PM Evan Rittner  wrote:
>
> Hi,
>
> Not sure if this is the right way to get support, but anyway: this section on 
> readthedocs suggests multiple methods to get top/bottom lists, but only the 
> two demonstrated in the example work. ('ia.get_top250_tv()' doesn't, for 
> example.) I double-checked this with dir(ia), and as I suspected, those 
> methods aren't defined.
>
> Thanks.
> ___
> Imdbpy-help mailing list
> Imdbpy-help@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/imdbpy-help



-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/


___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Urgent: Retrieving all movies with specific genre,

2020-07-17 Thread Davide Alberani
Hi Camille,
Your idea to import the data you need into a SQL database sounds good,
and IMDbPY could help.

There are, however, some caveats: first of all, the document you found
(README.sqldb.txt)
refers to an obsolete set of data no longer updated by IMDb since some years.
A new, up-to-date, dataset exists ( https://www.imdb.com/interfaces/ )
and IMDbPY is able to import it
into a SQL database of your choice; you can find the documentation
here: https://imdbpy.readthedocs.io/en/latest/usage/s3.html

But you may face another problem: IMDb includes very little
information, in this new dataset.
Look at it, and decide if it's okay for your project.
If it is, you can proceed.

More or less, the workflow would be as follow:

1.
install the latest version of https://github.com/alberanid/imdbpy/ -
see https://imdbpy.readthedocs.io/en/latest/#installation

2.
Download the dataset.
You can do it manually or, if you prefer, you can use the
"download-from-s3" script you'll find in the docs/goodies directory
(it requires a Linux system)

3.
import the dataset; as an example, to import the data into a SQLite
database, you can do something like:
s32imdbpy.py /path/to/the/imdb-dataset-2020-07-17/ sqlite:///imdb.db --verbose

(notice the three / in sqlite:///imdb.db - they are all needed)
After a while, you will have an "imdb.db" file in the current
directory, containing the imported data.

4.
you can now search and analyze the data in this file using the
Python's "sqlite3" module.


Let me know if you have questions or something is not clear.

Hope this helps.

On Fri, Jul 17, 2020 at 3:33 PM Camille Sanchez
 wrote:
>
> Hi team,
>
> For a python class, I am trying to sort the IMDb films through different 
> criteria (such as title types, genre, keywords, plot, etc. - similar to this 
> page of the IMDb website) and get a list of movies that match these criteria. 
> However, I am not quite sure how to start, could you help? I have downloaded 
> IMDbPy but I am not sure what to do next.
>
> I saw on different post such as "Retrieving all movies and csv file" and " 
> Retrieving a List of Movies in a Given Year" that it is possible to retrieve 
> the data without having a specific movie ID or movie title.
>
> Logically, I would assume that it is easy to query the data from a database. 
> I have done it on smaller projects with SQL database for instance, but I am 
> not sure I understand what is the best approach to do such a task. Is it:
> - to store all the movies into a server like AWS and then do the searches 
> directly from it
> - to access directly the database using this README.sqldb.txt file
> Or is there another way?
>
> Are there steps anywhere I can follow? Sorry I am a beginner at all this.
>
> Thank you for your help!
>
> Best.
> Camille
>
>
> _______
> Imdbpy-help mailing list
> Imdbpy-help@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/imdbpy-help



-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/


___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Wrong Information fetched

2020-07-12 Thread Davide Alberani
Hi Punit,
is it possible that you are using an old version of IMDbPY?

Please try installing the release from github:
https://github.com/alberanid/imdbpy/

I've tested it with this script:
#!/usr/bin/env python3

from imdb import IMDb

ia = IMDb()

for id_ in '10182822', '10228168', '10699362', '10696320':
m = ia.get_movie(id_)
print()
#print(sorted(m.keys()))
print('movieID:', id_)
print('title:', m['title'])
print('year:', m['year'])
print('rating:', m.get('rating'))
print('director:', m.get('director'))

And the results seem okay:
movieID: 10182822
title: Loro
year: 2018
rating: 6.7
director: []

movieID: 10228168
title: First Love
year: 2019
rating: 6.8
director: []

movieID: 10699362
title: Moffie
year: 2019
rating: 7.2
director: []

movieID: 10696320
title: Krabi, 2562
year: 2019
rating: 6.5
director: [, ]



Hope this helps.


On Sun, Jul 12, 2020 at 3:20 PM Punit Singh  wrote:
>
> Hello
>
> I have been using IMDbPY for a while and it has been fairly accurate in 
> retrieving the results.
>
> However, I have recently noticed that some information being fetched is 
> incorrect when I try to match it with the details shown on IMDb page for the 
> same title.
>
> For example: Try fetching the movie details for following IMDB id's
>
> https://www.imdb.com/title/tt10182822/
> https://www.imdb.com/title/tt10228168/
> https://www.imdb.com/title/tt10699362/
> https://www.imdb.com/title/tt10696320/
>
> title , year being fetched is incorrect. rating value is not fetched.
>
> Is there something wrong that I am doing?
>
> Thanks
> Punit
>
>
> ___
> Imdbpy-help mailing list
> Imdbpy-help@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/imdbpy-help



-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/


___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] issue with movie's goofs and quotes

2020-06-11 Thread Davide Alberani
Hi Noa,

It should work.  Is it possible that you are using an old version?
It's always better to use the version from the github repository.
To install it, please run: pip install git+https://github.com/alberanid/imdbpy


As an example, this script:
#!/usr/bin/env python3
import sys
import imdb
ia = imdb.IMDb()
matrix = ia.get_movie('0133093')
ia.update(matrix, ['quotes', 'goofs', 'trivia'])
print('QUOTES: ', len(matrix['quotes']))
print('GOOFS:', len(matrix['goofs']))
print('TRIVIA', len(matrix['trivia']))


will produce:
QUOTES:  110
GOOFS: 137
TRIVIA 197


Hope this helps.

On Thu, Jun 11, 2020 at 10:59 AM noa roy <0nus...@gmail.com> wrote:
>
> Hello,
> I am running the following code line: ia.update(movie, ['quotes', 
> 'goofs','trivia']) (taken from documentation) but it does not update both 
> goofs and quotes - only trivia.
> I found an old (2016) question regarding this issue but it was not answered.
> Any advice?
> Tnx!
> Noa
> _______
> Imdbpy-help mailing list
> Imdbpy-help@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/imdbpy-help



-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/


___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Urgent help required

2019-09-16 Thread Davide Alberani
Hi Aparajito,
depending on the data that you need, you may work with the dataset
distributed by IMDb: https://www.imdb.com/interfaces/
If needed, it's accessible using IMDbPY with this interface:
https://imdbpy.readthedocs.io/en/latest/usage/s3.html

To install and use IMDbPY, please refer to the documentation:
https://imdbpy.readthedocs.io/en/latest/

Not being familiar with Anaconda, I can't help on that matter.


Best regards,

On Sun, Sep 15, 2019 at 7:58 AM aparajito sengupta via Imdbpy-help
 wrote:
>
> Dear Sir,
> I am Aparajito Sengupta a data science student from India.
> I am pursuing my masters in data analytics from IISWBM, Calcutta University 
> and I am pretty new to the field of data science.
> I wish to do a sentiment analysis of all the movie released from 2012 to 2018 
> and need the data set for the same. But I don't know how should I go about it.
> Since the number of movies released from 2012 to 2019 is huge I can not 
> extract individual movies as shown in you example.
>
> Kindly help me getting the dataset asap so that I can start my analysis.
>
> I use anaconda platform . Kindly also share how can I install IMDB package . 
> I need the conda codes.
>
> Thanks a lot in advance for all your supports.
>
> Yours sincerely ,
> Aparajito
>
>
> ___
> Imdbpy-help mailing list
> Imdbpy-help@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/imdbpy-help



-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/


___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Getting parents guide

2019-08-04 Thread Davide Alberani
Hi Anupam,
asking for help always include what you want to do and what you have
already tried.

Most of the parental guide parsers are broken, at the moment.
The correct way to access what's available is:
#!/usr/bin/env python3
# -*- coding: utf-8 -*-

import sys

from imdb import IMDb
ia = IMDb()

tm = ia.get_movie('0133093', info=['parents guide'])
print(sorted(tm.keys()))


On Thu, Aug 1, 2019 at 6:49 PM Anupam Yedida  wrote:
>
> Hi
>
> I am having trouble accessing the parents guide. Can you kindly help me out?
> ___
> Imdbpy-help mailing list
> Imdbpy-help@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/imdbpy-help



-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/


___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


[Imdbpy-help] IMDbPY 6.8

2019-07-20 Thread Davide Alberani
Hi all,
I had some spare time, so I released IMDbPY 6.8.

In this version:
  - #224: introduce the search_movie_advanced(title, adult=None,
results=None, sort=None, sort_dir=None) method
  - #145: names are stored in normal format (Name Surname)
  - #225: remove obsolete cookie
  - #182: box office information
  - #168: parse series and episode number searching for movies
  - #217: grab poster from search
  - #218: extract MPAA rating
  - #220: extract actor headshot from full credits


As always, IMDbPY is looking for developers; if you want to
contribute, contact us!

-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/


___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Can't retrieve original title

2019-06-30 Thread Davide Alberani
Hi Kamiku,
there are a couple of things to notice:

1.
the bug with the parser of the AKAs from the reference page (the one
we parse by default) is fixed in the repository version; please use
that one from Github.

2.
as you have noticed, when information about a movie is fetched, only
the "main" reference page is parsed (e.g.
https://www.imdb.com/title/tt0133093/reference ) and that one only
contains a small number of AKAs.

You can also parse the "release info" page (e.g.
https://www.imdb.com/title/tt0133093/releaseinfo ) which contains the
complete list. To do so:

>>> from imdb import IMDb
>>> i = IMDb()
>>> m = i.get_movie("0097694")
>>> akas = m.get('akas', [])
>>> i.update(m, 'release info')
>>> complete_akas = m.get('akas from release info', [])


Hope this helps,

On Sun, Jun 23, 2019 at 7:27 AM Kamiku  wrote:
>
> Hi Davide,
>
> thank you very much for your answer.
> It seems the movie.get('akas', []) method doesn't return the whole list 
> (anymore?).
>
> For instance, if I'm trying to retrieve the AKAs from the Japanese movie 
> "Kuroi ame": https://www.imdb.com/title/tt0097694/releaseinfo#akas
> Please note that when visiting the page you can find 19 items, "original 
> title" included.
> But the method below returned only 6 of them, one of which is not even a 
> title, it is "See more »".
>
> >>> from imdb import IMDb
> >>> i = IMDb()
> >>> m = i.get_movie("0097694")
> >>> akas = m.get('akas', [])
>
> Here the list returned contains only 1 element, that isn't correctly split:
> ['Black Rain\n(World-wide, English title)\n   
>  \n\n
> Black Rain\n(United Kingdom)\n
> \n\nPluie noire\n 
>(France)\n\n   
>  \nLluvia negra\n
> (Spain)\n\n\n 
>Pioggia nera\n(Italy)\n
> \n\nSee more »']
>
> And even if I split it after that, I still haven't got the whole list of akas:
> >>> a = akas[0].split("\n\n\n 
> >>>")
> >>> len(a)
> 6
>
> Is there any way to retrieve the complete list of akas, including the IMDb 
> "(original title)" item?
> Or to fix the method that's already there?
>
> Kind regards,
>
>
> Le jeu. 20 juin 2019 à 21:39, Davide Alberani  a 
> écrit :
>>
>> Hi Kamiku,
>> searching for a movie, if it's available, the original title will be
>> in the 'akas' key (a list of strings, if present).
>>
>> As an example, see the output for ID 0270841 from the following script:
>>
>> from imdb import IMDb
>> ia = IMDb()
>> for movie in ia.search_movie('matrix'):
>> print('id: %s; title: %s; akas: %s' % (movie.movieID,
>> movie.get('title'), ', '.join(movie.get('akas', []
>>
>> OUTPUT:
>> id: 0133093; title: The Matrix; akas:
>> id: 0106062; title: Matrix; akas:
>> id: 5274778; title: Matrix; akas:
>> id: 0234215; title: The Matrix Reloaded; akas:
>> id: 0242653; title: The Matrix Revolutions; akas:
>> id: 0295432; title: The Matrix Revisited; akas:
>> id: 0270841; title: Cyber Wars; akas: Matrix Hunters: Kynigoi ston 
>> kyvernohoro
>> id: 1842414; title: Matrix IV; akas:
>> id: 9642498; title: The Matrix; akas:
>> id: 0328832; title: The Animatrix; akas:
>> id: 0277828; title: Enter the Matrix; akas:
>> id: 6301452; title: Matriarch; akas:
>> id: 0390244; title: The Matrix Online; akas:
>> id: 0364888; title: Threat Matrix; akas:
>> id: 0451118; title: The Matrix: Path of Neo; akas:
>> id: 9851526; title: The Matrix; akas:
>> id: 0211096; title: V-World Matrix; akas:
>> id: 1499960; title: The Living Matrix; akas:
>> id: 0274085; title: Sex and the Matrix; akas:
>> id: 8793748; title: Matrixx; akas:
>>
>>
>> Notice that there's no guarantee that the 'akas' key is present, and
>> no way to tell if it contains the original title or another very
>> popular title for the same movie.
&

Re: [Imdbpy-help] Can't retrieve original title

2019-06-20 Thread Davide Alberani
Hi Kamiku,
searching for a movie, if it's available, the original title will be
in the 'akas' key (a list of strings, if present).

As an example, see the output for ID 0270841 from the following script:

from imdb import IMDb
ia = IMDb()
for movie in ia.search_movie('matrix'):
print('id: %s; title: %s; akas: %s' % (movie.movieID,
movie.get('title'), ', '.join(movie.get('akas', []

OUTPUT:
id: 0133093; title: The Matrix; akas:
id: 0106062; title: Matrix; akas:
id: 5274778; title: Matrix; akas:
id: 0234215; title: The Matrix Reloaded; akas:
id: 0242653; title: The Matrix Revolutions; akas:
id: 0295432; title: The Matrix Revisited; akas:
id: 0270841; title: Cyber Wars; akas: Matrix Hunters: Kynigoi ston kyvernohoro
id: 1842414; title: Matrix IV; akas:
id: 9642498; title: The Matrix; akas:
id: 0328832; title: The Animatrix; akas:
id: 0277828; title: Enter the Matrix; akas:
id: 6301452; title: Matriarch; akas:
id: 0390244; title: The Matrix Online; akas:
id: 0364888; title: Threat Matrix; akas:
id: 0451118; title: The Matrix: Path of Neo; akas:
id: 9851526; title: The Matrix; akas:
id: 0211096; title: V-World Matrix; akas:
id: 1499960; title: The Living Matrix; akas:
id: 0274085; title: Sex and the Matrix; akas:
id: 8793748; title: Matrixx; akas:


Notice that there's no guarantee that the 'akas' key is present, and
no way to tell if it contains the original title or another very
popular title for the same movie.


Hope this helps,


On Tue, Jun 18, 2019 at 10:35 AM Kamiku  wrote:
>
> Hello,
>
> is there any way to retrieve the original title instead of the English title 
> when searching a movie with the http methods?
>
> The Changelog says "searching for a movie, the original titles are returned, 
> instead of AKAs" about the sql version, but I can't find anything about that 
> same feature for http.
>
> I'm trying to retrieve original titles from non-English titled movies, but so 
> far no luck.
>
> Kind regards,
>
> Kamiku
> _______
> Imdbpy-help mailing list
> Imdbpy-help@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/imdbpy-help



-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/


___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


[Imdbpy-help] IMDbPY 6.7 released

2019-05-19 Thread Davide Alberani
Hi,
it's been a long since the last release, so I've published 6.7:
https://imdbpy.sourceforge.io/
This version is dedicated to all Game of Thrones fans waiting for the
end of the show. ;-)

There are still a lot of fixes and improvements to be done; if anyone
wants to contribute, please look at
https://github.com/alberanid/imdbpy/issues

For the next release, I hope we can switch to a calendar-based
versioning schema as suggested by Uyar
https://github.com/alberanid/imdbpy/issues/112 and we'll probably have
a new homepage.


Best regards,

-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/


___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Movie Research

2018-11-18 Thread Davide Alberani
On Sat, Nov 17, 2018 at 9:59 PM Joshua Horsley  wrote:
>
> I am a student research assistant and very new to python. I am wanting to use 
> your database to put together a collection of data on movies released since 
> 2000. Some of the data I am looking for includes genre, release date, 
> revenue(US and World), when it was released to streaming services, and 
> budget. Any advice you have would be greatly appreciated.

Hi Joshua,
It's not so simple, since the data you need is not in a single place.

Maybe you can try a combined approach: use the dataset released on
https://datasets.imdbws.com/ and use
https://imdbpy.readthedocs.io/en/latest/usage/s3.html
to collect a list of movies released since the year 2000.
With that, you can use IMDbPY to access the web site information and
gather the other data.
See the documentation to know how to download the various pieces of information.

Please beware that some parsers may be broken, so you better test it
on a single movie before to see if you can really collect anything you
need.
If something is broken or you have doubts, feel free to ask.


Best regards,

-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/


___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] IMDbPy Question

2018-11-13 Thread Davide Alberani
Hi Jacob,
unfortunately that feature is missing: we do not parse reviews.

To make things more complex, a page like this
https://www.imdb.com/user/ur2467618/reviews
shows only a small amount of data, and more is loaded dynamically on request.

So... I fear we'll never support this, sorry.

On Tue, Nov 13, 2018 at 7:57 PM Jacob Higgins  wrote:
>
> Hi,
>
> My name is Jacob, and I was wondering: is there a way to access an individual 
> user's reviews for different movies? For example, can I use IMDbPy to access 
> the score of every movie rated by imdb_user1978 (a made-up user)?
>
> I've been playing around with a project where I rate movies on my own, then 
> go through top users of IMDb to try and find people who have the same taste 
> in movie as I do. That way, whenever a new movie comes out I can see their 
> reviews and determine if I would enjoy it!
>
> I am a big-time amateur at this kind of stuff, so its easy for me to get lost 
> in the documentation trying to find what I 'm looking for.
>
> Thanks!
> Jacob Higgins
>
> ___
> Imdbpy-help mailing list
> Imdbpy-help@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/imdbpy-help



-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/


___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


[Imdbpy-help] IMdbPY 6.6

2018-08-05 Thread Davide Alberani
Hi everyone,
IMDbPY 6.6 is out!

A lot of parsers fixed, a solution for the certificate verification problems
and improvements to the new dataset.

Plus, now our tests are automatically run at each commit using
https://travis-ci.org/alberanid/imdbpy


Enjoy the summer,

-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


[Imdbpy-help] IMDbPY on readthedocs

2018-06-24 Thread Davide Alberani
Hi all,
I've just added IMDbPY to readthedocs: https://imdbpy.readthedocs.io/

The build was done in a full-automated fashion, so maybe something is
missing or not correctly organized.

For the moment, it's better than nothing. :-)
The docs should be automatically updated with new commits.

Hope this helps,

-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Getting SSL Error

2018-05-09 Thread Davide Alberani
Hi Anurag,
it seems to be an issue that is difficult to spot.

I've reopened a previous bug with a similar report; if possible,
follow the instructions in my last post, here:
https://github.com/alberanid/imdbpy/issues/155


Thanks for the report,


On Tue, May 8, 2018 at 8:36 PM, Anurag Gupta  wrote:
> Hi,
>
> I am getting SSL Error while trying to get the movie details.
> Please have a look at the attached file.
>
> Your help is needed.
>
>
>
> Thanks & regards,
> Anurag Gupta.
>
> --
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> ___
> Imdbpy-help mailing list
> Imdbpy-help@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/imdbpy-help
>



-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Docs Location

2018-05-06 Thread Davide Alberani
Hi Ayrton,
IMDbPY is mostly documented in the main README (
https://github.com/alberanid/imdbpy/blob/master/README.rst )
and in the various files in the docs directory:
https://github.com/alberanid/imdbpy/tree/master/docs

We'll probably publish them on readthedocs, soon.


Hope this helps,


On Tue, May 1, 2018 at 8:56 PM, Ayrton Bourn  wrote:
> Hey there,
>
>
>
> Love the module! Just wondering where the full docs are, can’t seem to find
> them on GitHub or your website?
>
>
>
> Kind regards,
>
> Ayrton
>
>
> --
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> ___
> Imdbpy-help mailing list
> Imdbpy-help@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/imdbpy-help
>



-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


[Imdbpy-help] IMDbPY 6.5

2018-04-15 Thread Davide Alberani
Hi all,
I've released IMDbPY, which comes with two main features, both
developed by H. Turgut Uyar:
- the web parsers are now based on hi project piculet
- the documentation was converted to the sphinx format

Besides this, some minor fixed.


Enjoy it,

-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] IMDbPY 6.4

2018-03-16 Thread Davide Alberani
Hi all,
packaged and released version 6.4.1 to remove some debug code
that I forgot.


Enjoy,

On Wed, Mar 14, 2018 at 10:37 PM, Davide Alberani
 wrote:
> Hello,
> We have just released IMDbPY 6.4 to fix some serious problems
> with the search parsers: https://imdbpy.sourceforge.io/downloads.html
>
> As always, IMDbPY is looking for developers; if you want to
> contribute, let us know. :-)
>
> Thanks to anyone involved!
>
> --
> Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
> http://www.mimante.net/



-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] 6.4 parse error

2018-03-16 Thread Davide Alberani
2 in the South', 'kind': 'short', 'year': 1935}, None), ('8134432',
> {'episode of': "Scooby's Mystery Funhouse", 'series year': 1985, 'title':
> 'Beauty Contest Caper/The Fall Dog/The Scooby Coupe', 'kind': 'episode',
> 'year': 1985}, None), ('5881246', {'episode of': 'Beyond Today', 'series
> year': 2005, 'title': 'The Shofar, the Rapture and the Feast of Trumpets',
> 'kind': 'episode', 'year': 2009}, None), ('4475778', {'title': 'Speed
> Dreams: The Fastest Place on Earth', 'kind': 'tv series', 'year': 2013},
> None), ('4619488', {'episode of': 'Starship Icarus', 'series year': 2014,
> 'title': 'The Fatal Flaw in the Star Trek Universe', 'kind': 'episode',
> 'year': 2014}, None), ('1313449', {'episode of': 'Samurai Girl: Real Bout
> High School', 'series year': 2001, 'title': 'The Strongest Man on Earth
> Joins the Fight', 'kind': 'episode', 'year': 2001}, None), ('0005272',
> {'title': 'The Fable of the Escape of Arthur and the Salvation of Herbert',
> 'kind': 'short', 'year': 1915}, None), ('2329389', {'episode of': 'Die
> Pfotenbande', 'series year': 2011, 'title': 'Auf dem Bauernhof Teil 1: Die
> Kälbchengeburt (At the farm part 1: Birth of a calf)', 'kind': 'episode',
> 'year': 2011}, None), ('6370536', {'episode of': 'Space Pirate Captain
> Herlock: Outside Legend - The Endless Odyssey', 'series year': 2002,
> 'title': 'Voyage 12: The Soul Drifts to the Far Ends, with No Words at
> Parting', 'kind': 'episode', 'year': 2002}, None), ('6637796', {'episode
> of': '20/20', 'series year': 1978, 'title': 'National Parks: Crime
> Wave/After the Storm/Before the Fall', 'kind': 'episode', 'year': 2003},
> None), ('2203516', {'episode of': 'Casper and Friends', 'series year': 1990,
> 'title': 'Keep Your Grin Up/Herman The Cartoonist/Fiesta Time/Clown On The
> Farm', 'kind': 'episode', 'year': 1990}, None), ('1413597', {'title':
> 'Walking for the Stars: The Foley Artistry of Nancy Anne Cianci', 'kind':
> 'short', 'year': 2007}, None), ('6130574', {'episode of': 'Siskel & Ebert',
> 'series year': 1986, 'title': 'Heaven and Earth/Grumpy Old
> Men/Shadowlands/In the Name of the Father/The Summer House', 'kind':
> 'episode', 'year': 1993}, None), ('5441068', {'episode of': '60 Minutes
> Wednesday', 'series year': 1999, 'title': 'Martha Stewart: Past and
> Present/The Fattest Americans/Reviving the Dead', 'kind': 'episode', 'year':
> 2004}, None), ('5118756', {'episode of': 'The Dr. Oz Show', 'series year':
> 2009, 'title': 'How You Can Change the Fate of Your Heart and the Statin
> Answers You Need Now', 'kind': 'episode', 'year': 2015}, None), ('2354066',
> {'title': 'Into the Fire: The Birth of the Studio Art Glass Movement',
> 'kind': 'short', 'year': 2012}, None), ('3366830', {'episode of': 'Steve
> Harvey', 'series year': 2012, 'title': 'Steve Helps a Lumberjack Lady Find
> Love/Chef Art Smith/Dog Causes Big Problems/Dunk-Fest', 'kind': 'episode',
> 'year': 2013}, None), ('3784424', {'episode of': 'The Coolest Places on
> Earth', 'series year': 2013, 'title': 'Beaches, Castles, and the Happiest
> Place on Earth: The Florida Keys, Norway, Scotland, and Croatia', 'kind':
> 'episode', 'year': 2013}, None), ('1477881', {'episode of': 'Across
> Indiana', 'series year': 1988, 'title': "Mia Farrow: Witness for Darfur/The
> Art of Living/Santa Claus in Baghdad/Who Makes the Sun Rise?/The Widow's
> Journey/Kaitlynne", 'kind': 'episode', 'year': 2009}, None), ('4132412',
> {'episode of': 'Just Seen It', 'series year': 2011, 'title': 'The Skeleton
> Twins, the Most Disappointing Movies of 2014 So Far, Interview with Nicholas
> McCarthy & Ashley Rickards, More of the Best of 2014 So Far', 'kind':
> 'episode', 'year': 2014}, None), ('6213270', {'title': 'Dom u poslednego
> fonarya', 'kind': 'tv miniseries', 'year': 2017}, '"Sketch of a Murder: The
> House by the Farthest Streetlight"')]}
> 20 results for "the farthest":
> movieID : imdbID : title
> 6223974 : 6223974 : The Farthest (2017)
> 7168140 : 7168140 : The Farthest place of the world (2017)
> 590 : 590 : The Farthest Apple from the Tree (2015)
> 6169424 : 6169424 : The Farthest I Could Find (2016)
> 0706377 : 0706377 : "Space: Above and Beyond" The Farthest Man from Home
> (1995)
> 6538134 : 6538134 : "Fractale" The Farthest Town (2011)
> 1605791 : 1605791 : Beyond the Farthest Star (2015)
> 1315219 : 1315219 : Walter the Farting Dog (in development) (None)
> 1383902 : 1383902 : "Eyewitness to History" The Farthest Neighbors (1960)
> 6509760 : 6509760 : "Suspense" To the Farthest Shore (2016)
> 6762336 : 6762336 : "CBS Reports" Farthest Frontier (1967)
> 6522138 : 6522138 : Farthest North (in development) (None)
> 0827626 : 0827626 : "Star Trek: The Animated Series" Beyond the Farthest
> Star (1973)
> 1560191 : 1560191 : The Farther, the Dearer (2007)
> 3682684 : 3682684 : The Farther You Go (2014)
> 4177286 : 4177286 : The Luckiest Man on the Face of the Earth (None)
> 0168197 : 0168197 : Sugar: The Fall of the West (1998)
> 0613891 : 0613891 : "Jackanory" The Star of the Farmyard (1993)
> 0687010 : 0687010 : "Rita and Wally" The Farther the Better (1968)
> 1992103 : 1992103 : Carmen: In the Land Farthest from (2011)
>
> Which seems like a lot of extra info is contained in it, but it does
> produces the titles iI’m interested in.
>
> When I run it via an AppleScript, I get the following error:
>
> Result:
>
> error "2018-03-15 15:27:03,218 ERROR [imdbpy.parser.http.domparser]
> /usr/local/lib/python3.6/site-packages/imdb/parser/http/utils.py:519:
> DOMHTMLSearchMovieParser: caught exception postprocessing data
> Traceback (most recent call last):
>   File \"/usr/local/lib/python3.6/site-packages/imdb/parser/http/utils.py\",
> line 516, in parse
> data = self.postprocess_data(data)
>   File
> \"/usr/local/lib/python3.6/site-packages/imdb/parser/http/searchMovieParser.py\",
> line 84, in postprocess_data
> print(data)
> UnicodeEncodeError: 'ascii' codec can't encode character '\\xa2' in position
> 6468: ordinal not in range(128)
> Traceback (most recent call last):
>   File \"/usr/local/bin/search_movie.py\", line 34, in 
> results = i.search_movie(title)
>   File \"/usr/local/lib/python3.6/site-packages/imdb/__init__.py\", line
> 427, in search_movie
> accessSystem=self.accessSystem) for mi, md in res][:results]
>   File \"/usr/local/lib/python3.6/site-packages/imdb/__init__.py\", line
> 427, in 
> accessSystem=self.accessSystem) for mi, md in res][:results]
> ValueError: too many values to unpack (expected 2)" number 1
>
>
> Sent from my iPhone
>
> --
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> ___
> Imdbpy-help mailing list
> Imdbpy-help@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/imdbpy-help
>



-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


[Imdbpy-help] IMDbPY 6.4

2018-03-14 Thread Davide Alberani
Hello,
We have just released IMDbPY 6.4 to fix some serious problems
with the search parsers: https://imdbpy.sourceforge.io/downloads.html

As always, IMDbPY is looking for developers; if you want to
contribute, let us know. :-)

Thanks to anyone involved!

-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


[Imdbpy-help] IMDbPY 6.3

2018-02-27 Thread Davide Alberani
Hi all,
I've just release IMDbPY 6.3.

While the development on the new web pages of IMDb is
probably far from complete, I feel confident that the current
set of features are already good enough.

Plus, in this release, there's support to the new dataset
distributed by IMDb: https://www.imdb.com/interfaces/

The new version can be downloaded from https://imdbpy.sourceforge.io/


Enjoy it!

-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Generating the HTML parsers

2018-02-27 Thread Davide Alberani
On Tue, Feb 27, 2018 at 9:05 AM, H. Turgut Uyar  wrote:
>
> So I decided to develop a parser generator that will read a
> specification for a parser and generate the necessary code

That's really cool, I plan to give a look at it as soon as possible.

What kind of help you need, mostly?


-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


[Imdbpy-help] parsing the new IMDb database

2018-02-07 Thread Davide Alberani
Hi,
since the end of 2017 IMDb is not updating the old dataset
files anymore.
It was replace with a new set of files, with much less information
in it, but at least much easier to parse.

Today I've committed on master the support for this new
dataset (I've called it "s3", since initially the files were
distributed only on AWS S3).

The usage is very similar to the old "sql" data access system;
it's still based on SQLAlchemy, and uses a custom script to
import the files: bin/s32imdbpy.py in this case.

The code is still a bit immature, but all (?) the features should be here.

For all the information, see:
https://github.com/alberanid/imdbpy/blob/master/docs/README.s3.txt

Anyone interested in using this new dataset can now try it
(cloning the version from the repository) and let us know
if something is broken.

I've not too clear the status of the http parsers, but I'll probably
do a new major release (6.3) soon, since this is a major feature.


-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Number of movie scripts in the database

2018-01-27 Thread Davide Alberani
Hi Arunima,
cool project!

It depends on what you consider a "script" and a "database". :-)

Options for script:
- plot summary: the first entries in the page
http://www.imdb.com/title/tt0133093/plotsummary
- synopsis: the entries in the "synopsis" section of the same page:
http://www.imdb.com/title/tt0133093/plotsummary?ref_=tt_ql_stry_2
- the full movie script; something that can be downloaded from other
sites (we do not parse them), like:
  http://www.imsdb.com/scripts/Matrix,-The.html
  http://www.dailyscript.com/scripts/the_matrix.pdf

Options for "database":
- the web pages of the IMDb site: http://www.imdb.com/
- the old plain text data files released by IMDb until the end of
2017: ftp://ftp.funet.fi/pub/mirrors/ftp.imdb.com/pub/frozendata/
- the new s3 dataset released since then: http://www.imdb.com/interfaces/


Talking about numbers, on the web pages we have:
- I'd say about 1.4mln movies with a plot summary:
http://www.imdb.com/search/title?has=plot
  the downside is that they are not easy to parse, at least not with
IMDbPY, since it's intented
  to be used to fetch a movie at a time, and not as a tool for
mass-import/scraping
- an unknown number of synopses (can't find a way to search only for them)
- zero full scripts

On the old plain text data files, that IMDbPY is still able to parse
and put on a SQL database, for
later consumption (but obviously are no longer updated):
- about 590.000 movies with a plot summary
- zero synopses
- zero full script

On the new dataset distributed by IMDb, that for the moment we're still unable
to parse (but this will change in a few weeks):
- zero plot summaries
- zero synopses
- zero full scripts


Hope this helps.

Let us know if you need help,



On Sat, Jan 27, 2018 at 6:37 PM, Arunima Kayath  wrote:
>
> I am a student at UC Berkeley. I would like to do a project to predict movie
> ratings based on the script (age appropriateness). I need a meaningful
> number of scripts to do that. Can you tell me how many authentic movie
> scripts are available in the database ?
>
> Thanks
>
> Arunima
>
> --
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> ___
> Imdbpy-help mailing list
> Imdbpy-help@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/imdbpy-help
>



-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] [imdbpy-help] After i.update(movie) wrong (and always the same) title is returned

2018-01-01 Thread Davide Alberani
Hi all,
yes: since a recent redesign of the web pages, IMDbPY is badly broken.

We started working on master to fix it, but there's still much to do;
see https://github.com/alberanid/imdbpy/issues/103

As always, any help is welcome.

If you want to start fixing something, run the tox and chose one of
the parsers you want to work on (and tell us on that issue, so that we
can avoid duplicate work).

Thanks!


On Sat, Dec 30, 2017 at 12:08 PM, Filip Bačić  wrote:
> Hi,
>
> Lately, after i.update(movie), I always get the same movie title "The
> leading information resource for the entertainment industry".
> I used some old imdbpy package, but I also now tried it with the latest one
> and I am getting the same result.
>
> For example, for this code:
>
> import imdb
>
> i = imdb.IMDb()
>
> movie_list = i.search_movie('pacific rim')
>
> first_match = movie_list[0]
>
> print(first_match)
>
> i.update(first_match)
>
> print(first_match)
>
> I get this output:
>
> Pacific Rim
> The leading information resource for the entertainment industry
>
> Does anyone else have this problem?
>
> Best Regards,
>
> Filip
>
> --
> You received this message because you are subscribed to the Google Groups
> "imdbpy-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to imdbpy-users+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.



-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Presentation and windows problem

2017-11-19 Thread Davide Alberani
On Sun, Nov 19, 2017 at 4:36 PM, Martín Torre Castro
 wrote:
>
> Installing from the gitHub clone did work perfectly.

Great!
I've also just release version 6.2, since the previous one contained
some critical bugs.


-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Presentation and windows problem

2017-11-18 Thread Davide Alberani
Hi Martin,
Please clone the GitHub repository and install that version. I do not make
a new release every time I introduce some fixes.


Il 18 nov 2017 19:42, "Martín Torre Castro" 
ha scritto:

> The output is 6.0, all installed with pip.
>
> I'm uninstalling and downloading the latest version later following
> instructions on the web.
>
> I'm letting you know the result
>
> El 18 nov. 2017 9:57 a. m., "Davide Alberani" 
> escribió:
>
>> On Thu, Nov 16, 2017 at 7:55 PM, Martín Torre Castro
>>  wrote:
>> >
>> >>  The above one should already be fixed in the repository
>> >> version:
>> >> https://github.com/alberanid/imdbpy
>> >>
>> > IMDbPY==6.0
>> >
>> > I'm checking now. It says everything is 'already-up-to-date'.
>>
>> Hi Martin,
>> this does not seem to be the latest version.
>>
>> Executing this command:
>> python3 -c 'import imdb ; print(imdb.__version__)'
>>
>> the output should be something like 6.1dev2017118
>>
>> I've also fixed to bug parsing the imdbpy.cfg file.
>>
>> > Finally, I was trying the file from a very little gui in a '.pyw' file.
>> Now
>> > I tried only the text-mode script and it gives this error at the command
>> > line. It's happening at the IMDb() call.
>>
>> As Turgut said, that was due to the fact that cookies were moved to a
>> separated JSON file.
>> I've reverted it, splitting the long lines, to prevent other similar
>> cases.
>>
>> Let us know if it fixes. :-)
>>
>>
>> --
>> Davide Alberani   [PGP KeyID:
>> 0x3845A3D4AC9B61AD]
>> http://www.mimante.net/
>>
>
--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Presentation and windows problem

2017-11-18 Thread Davide Alberani
On Thu, Nov 16, 2017 at 7:55 PM, Martín Torre Castro
 wrote:
>
>>  The above one should already be fixed in the repository
>> version:
>> https://github.com/alberanid/imdbpy
>>
> IMDbPY==6.0
>
> I'm checking now. It says everything is 'already-up-to-date'.

Hi Martin,
this does not seem to be the latest version.

Executing this command:
python3 -c 'import imdb ; print(imdb.__version__)'

the output should be something like 6.1dev2017118

I've also fixed to bug parsing the imdbpy.cfg file.

> Finally, I was trying the file from a very little gui in a '.pyw' file. Now
> I tried only the text-mode script and it gives this error at the command
> line. It's happening at the IMDb() call.

As Turgut said, that was due to the fact that cookies were moved to a
separated JSON file.
I've reverted it, splitting the long lines, to prevent other similar cases.

Let us know if it fixes. :-)


-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Presentation and windows problem

2017-11-16 Thread Davide Alberani
On Thu, Nov 16, 2017 at 1:07 AM, Madtyn  wrote:
>
> I started using imdbPY and I was very happy with the low difficulty in
> larning how to use this tool.

Hi Martin, I'm glad IMDbPY is useful to you!


> The problem came when I did want to make a Windows '.exe' file for
> distributing it.

I'll try to build it on Windows, in the next days.
Can you tell me how you have set up the environment?
Which version of Python?
Which command you run to build the .exe?


> 2017-11-16 00:44:46,732 WARNING [imdbpy] C:\Program Files
> (x86)\Python36-32\lib\site-packages\imdb\__init__.py:165: Unable to read
> configuration file; complete error: 'ConfigParserWithCase' object has no
> attribute '_boolean_states'

Nice; this seems to be a problem related to the parsing of the
imdbpy.cfg file: remove it (I'll try to reproduce and fix the bug later),
since you don't really need it.


> grParser = GatherRefs(useModule=self._useModule)
> AttributeError: 'DOMHTMLPlotParser' object has no attribute '_useModule'

It seems you're using an old version.
IMDbPY just came out of a huge set of changes, and it still have some bugs here
and there.  The above one should already be fixed in the repository version:
https://github.com/alberanid/imdbpy


Hope this helps,

-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] IMDbPY revamp

2017-11-11 Thread Davide Alberani
On Wed, Nov 1, 2017 at 3:02 PM, Davide Alberani
 wrote:
>
> as many of you know, IMDbPY is in need of a revamp. :-)

A quick update: I've just merged back into master the many changes of
the "codename-simply" branch (which should now be considered closed;
I'll delete it soon).

The old version, suitable for Python 2.7, is available in the
"imdbpy-legacy" branch, and probably will receive very little updates
from now on.

Main changes:
- Python 3 support (and only Python 3: no Python 2.7 compatibility, sorry)
- removed the 'mobile' set of parsers
- removed dependencies: SQLObject, C compiler, BeautifulSoup
- introduced a testsuite, please help with it:
https://sourceforge.net/p/imdbpy/mailman/message/36107729/

I want to thanks all the contributors, and especially H. Turgut Uyar
for such a huge amount of work!

I hope to be able to update the website and pypi tomorrow.
There are for sure many many bugs, please help and report them.

-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


[Imdbpy-help] IMDbPY revamp

2017-11-01 Thread Davide Alberani
Hi all,
as many of you know, IMDbPY is in need of a revamp. :-)

So, while I (again and again) have very little time to devote to it, I
try to slowly improve it.

Right now I've created a "codename-simply" branch, with the intent of
reducing the amount of legacy code and some of the oddities of my
previous choices:
https://github.com/alberanid/imdbpy/tree/codename-simplify
See also issue https://github.com/alberanid/imdbpy/issues/61

My plan is more or less as follow:
* remove the "mobile" parser (done)
* remove SQLObject support (done)
* remove cutils, the utilities written in C (done, not sure it will
not be useful again in the future)
* introduce support for the new data set (to be done:
https://github.com/alberanid/imdbpy/issues/60 )
* move to Python 3 (to be done: https://github.com/alberanid/imdbpy/issues/27 )

Another possible point is:
* remove the BeautifulSoup dependency (python-lxml will be required)

but on this I wait the opinion of Turgut, the main author of that code.

The rationale is to remove unneeded dependencies (like the old SQLObject).
For the moment I've set lxml as a mandatory dependency, but I can
revert it to an optional one.
It has to be said that _bsoup is shipped with our package, so maybe we
can leave it there.

After this little clean-up, I'd like to work, in this order on:
1. the switch to Python 3
2. the new dataset, using SQLAlchemy (unless there are strong opinions
and helping hands to switch to a no-SQL db)

If you have other ideas and/or if you want to help, let us know. :-)


-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] 404 code returned

2017-10-08 Thread Davide Alberani
Hi Anthony,

Uh... the choice to raise a warning was poor, I admit it. :-)

You can do something like that:

m = ia.get_movie()
if not m.keys():
print('this movie does not exist')

Anyway, I have some plans about simplifying / extending IMDbPY.
Who knows if I'll ever have the time to act.

(I'll try to send a mail to imdbpy-devel in the next 2 weeks, about it)


On Fri, Oct 6, 2017 at 6:06 PM, Anthony Pecoraro  wrote:
> Greetings,
>
> Is there a way to have the following code return a recognizable error in my
> program? Trying to generate a random movie using a random integer.
>
> m = ia.get_movie()
>
> Thanks,
>
>
>
>



-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Imdbpy help

2017-07-18 Thread Davide Alberani
On Tue, Jul 18, 2017 at 8:24 PM, Personal  wrote:
>
> Thank you for creating imdbpy. When I tried to retrieve box office gross by 
> ia.update(m,'business'), the key business is always empty. Could you tell me 
> what I should do to get box office info and budget info? Thank you!

Hi Qianyu,
what you're doing seems to work for me.

Only thing I'd do, is to be sure that you're using the version from
the repository: https://github.com/alberanid/imdbpy

Also notice that there's a distinction between 'data sets' (like "business")
and the keys that will be added when you fetch a given data set (like "gross",
"budget" and so on).
For more information, see this thread:
https://sourceforge.net/p/imdbpy/mailman/imdbpy-help/thread/CAMWn9PRmzniiu%3Dkt7dbRgj8AGT2p30s6%2BP_N21zAcZotDG2ViA%40mail.gmail.com/#msg35935475

My test:

>>> from imdb import IMDb
>>> ia = IMDb()
>>> bh = ia.get_movie('0112573')

# let's update business information
>>> ia.update(bh, 'business')

# now check which keys were added by the 'business' info set
>>> print bh.infoset2keys['business']
[u'gross', u'copyright holder', u'filming dates', u'budget',
u'admissions', u'opening weekend', u'rentals', u'production dates']

# print the gross key
>>> print bh.get('gross')
[u'$75,609,945 (USA) (13 June 1996)', u'\xa310,812,243 (UK) (19
November 1995)', u'\xa33,342,433 (UK) (12 September 1995)',
u'$16,679,000 (UK)', u'$210,409,945 (Worldwide) (31 May 2012)',
u'\u20ac6,878,567 (Spain) (10 July 2003)', u'ESP 1,136,000,000
(Spain)']


Hope this helps,

-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Box Office

2017-07-15 Thread Davide Alberani
On Thu, Jul 13, 2017 at 10:32 PM, Juan Mantica  wrote:
>
> I am trying to get the box office for some movies, could you help me out.

Sure, please write on the imdbpy-help list what you've tried to do and
what's not working.



-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] IMDbPY

2017-07-09 Thread Davide Alberani
On Sat, Jul 8, 2017 at 11:41 PM, Anthony Pecoraro  wrote:
>
> Just wondering if there is a list of data points that are retrievable using
> IMDbPY. Specifically, wondering if there is a way to pull by user rating, or
> number of users who rated a film.

Hi Anthony,
not exactly: data are grouped in 'info sets' based on the web page (or
table) you can
find them on, and a simple page/table can obviously contains a lot of
information.

Let's say that we have the usual ia handler:
from imdb import IMDb
ia = IMDb()

You can now know which info sets are available:
ia.get_movie_infoset()

(there are matching methods for company, person, character)

Now, let's fetch information about a movie:
m = ia.get_movie('0078748')

You can add a new info set to the available information with:
ia.update(m, 'trivia')

To know which info set are now available:
m.current_info

You can also associate info sets to keys:
m.infoset2keys

(unfortunately, you can't do it before fetching a data set.  I.e.:
there's no fixed association
between info sets and keys)

That's more or less everything.


Hope this helps,


-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] IMDb: alternative interfaces now on S3 (with a different format)

2017-07-01 Thread Davide Alberani
On Sat, Jul 1, 2017 at 11:53 AM, Davide Alberani
 wrote:
>
> from their description, I fear that many, many, many information are missing.

Some stats.
Old files: 49 files, 1.9 GB
New files: 6 files, 361 MB

Talking about movies, it seems that less than 32k titles are missing
(not much, over ~4.4 mln).

There seems to be ~1.8 mln *more* people, and that was unexpected;
maybe they came
from crew roles that were not previously present.

So yes, I can confirm that we're missing a lot of information about
movies, companies,
characters and persons, here. :-/


-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


[Imdbpy-help] IMDb: alternative interfaces now on S3 (with a different format)

2017-07-01 Thread Davide Alberani
Hi all,
some partially bad news from IMDb (thanks to Ori for pointing it to me).

Table of Content:
* bad news
* good news
* temporary fix
* how to download the datasets
* what's next?

[bad news]

The http://www.imdb.com/interfaces page states that from now on the plain text
data files are released as a set of files in a S3 bucket named 'imdb-datasets'.

There are some things that are not nice:

1.
they require the users to pay according to the data transfert pricing
explained here: https://aws.amazon.com/s3/pricing/

I still haven't downloaded all the data, so I don't know how big it is
and can't tell
how much you'll spend, but I guess no more than a few cents.

2.
the format of the data is completely different from the old one, so it
can't be used
with imdbpy2sql.py, sorry. (that's the moment where we hate them, if
you are wondering ;))

3.
from their description, I fear that many, many, many information are missing.
No trivia, biographies, certificates, color info, crazy-credits,
country (!), goofs,
keywords, plot, mpaa ratings, movie links, companies, quotes, sound mix,
sound tracks, taglines, technical details and may be more.


[good news]

In this land of sorrow, there's also a good news: now titles and
persons are identified
using their real imdbID (nm001 / tt001), so you can link a web page
to an entry in this dataset.

Plus, the dataset is updated daily and seems much more db-friendly to parse.


[temporary fix]

It seems that for the moment the old ftp mirrors are still updated.
I'm quite sure they will be shut down soon, but for now you can still
download the data in the old format from:
ftp://ftp.funet.fi/pub/mirrors/ftp.imdb.com/pub/


[how to download the datasets]

To access the data, you have to create an Amazon AWS account; then,
on "My Security Credentials", go to IAM Users and add a new user.
Also add a separate, new, group for that user and grant it the
"AmazonS3FullAccess" policy.
(I'm pretty sure it can be limited to more granular permissions, but
for the moment we don't care).

Creating the user, an Access Key will be created: please store the
Access key ID and the Secret Key.

Now, with those keys, you can download the objects in the
'imdb-datasets' bucket.

There are various ways.  For example you can use s3cmd.
Install it and configure it (one time only) with: s3cmd --configure

Then, to download a file (all on the same line):
s3cmd --requester-pays --continue get
s3://imdb-datasets/documents/v1/current/title.basics.tsv.gz

the available objects are: title.basics.tsv.gz, title.crew.tsv.gz,
title.episode.tsv.gz, title.principals.tsv.gz, title.ratings.tsv.gz,
name.basics.tsv.gz


[what's next?]

Uhhh... who knows.
I have to give a better look at the data format.

We can introduce a new script to import the new datasets.
If we use a completely new db schema, I'm sure we can import the data
very quickly,
but that would mean that a new 'parser' module must be written to read it.
Probably not too complex, but more code to write.
If we stay with the current db schema, the importer will be more complex, but
we can still use the 'sql' parser.

Not sure... the first road means a fresh start, that sometime is
needed to improve. ;-)

What do you think?
Any opinion?
Anyone willing to help with the new code?

IMDbPY summer of code is open: we pay in (little) exposure!
http://theoatmeal.com/comics/exposure ;-)


-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] merging with weekly updates

2017-05-28 Thread Davide Alberani
Hi Philip,
I've thought about it many times, and I don't think it can be done,
especially not with good performances.

Those diffs are just normal, unix-style, patches.  Many times the
reference to the movie/person/character/company a changed line
refers to is completely missing, and you should apply it to the
complete file and analyze it just to know which entry to update.
From there, you should find the match in the db, which is another
complex task and decide to add/update/delete the data.

Just to download and apply the diff files to an existing sets
of files, you may try the applydiffs.sh and download_applydiffs.py
scripts in the docs/goodies directory.


HTH,


On Sat, May 27, 2017 at 9:15 PM, Philip Earvolino  wrote:
> IMDB creates weekly updates in the “diffs” folder on the imdb host ftp 
> site(s).  Has anyone tried running this script on these files and merging the 
> created SQL db with the existing db?  If “diffs" is not only adding new 
> records but updating existing ones will a merge properly key on the 
> as-created imdb ids?
> --
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> ___
> Imdbpy-help mailing list
> Imdbpy-help@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/imdbpy-help



-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] API Key

2017-05-27 Thread Davide Alberani
Hi Sutirtha,
IMDbPY doesn't require API keys.  Plus, we are in no way associated to IMDb.

If you need to get access to their data for research purposes, try
contacting them, starting from http://www.imdb.com/licensing/index


HTH,


On Wed, May 24, 2017 at 12:29 PM, Sutirtha Malakar
 wrote:
> Hi Team,
>
> How can I get an API key.
>
> I am doing for my research purpose and can I get image also if I call by a 
> movie name(Image).
>
> Regards,
> Sutirtha.
> --
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> ___
> Imdbpy-help mailing list
> Imdbpy-help@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/imdbpy-help



-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] encoding

2017-05-16 Thread Davide Alberani
On Sun, May 14, 2017 at 10:36 PM, Philip Earvolino  wrote:
>
> Hello.  I am now working with the mySQL db and the titles do not, apparently, 
> have the right encoding (i.e., certain characters do not appear properly).  
> The encoding is cp1252 West European (latin1) and the collation is latin1_bin 
> which are what is specified in the flat file IMDB export and, I think(?), in 
> the imdb sql creation script.

IMDbPY takes the iso-8859-1 plain text files and convert them to utf-8.

If I remember correctly, we don't force the db collections to be utf-8 - and we
didn't document it :-/ - so if you've created your db and tables as cp1252, it's
normal that the data seems messy.

> Any suggestions?

I don't know what happens if you change your collation encoding to
utf8_unicode_ci (or something like that).
If MySQL doesn't touch the data, great, otherwise you will have an
even bigger mess, I fear.


HTH,

-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Failing on Python 3.6.1

2017-05-14 Thread Davide Alberani
On Sun, May 14, 2017 at 4:35 PM, Jayendran  wrote:
>
> Not sure if this has been reported before as I'm getting a "Error 404"
> "We're sorry but we weren't able to process this request" on accessing the
> mail archive at
> https://sourceforge.net/mailarchive/forum.php?forum=imdbpy-help.

Hi Jayendran,
thanks for the notice, I've updated the links.

> Are there any plans to fix in/port to 3.6.x?

Right now, IMDbPY must be used with Python 2.7.
If you look at the pull requests
https://github.com/alberanid/imdbpy/pulls there are
various attempts at porting it to 3.x, but they are all partial.

I'd be more than glad to see it happen, but basically we need someone that does
the bulk of the work (and it's not a simple effort).


Bye,

-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] imdbpy2sql output errors

2017-05-14 Thread Davide Alberani
On Fri, May 12, 2017 at 10:19 AM, Giovanni Bianchi  wrote:
>
> I searched on google and I found a comment on this suggesting to
> increase the max_allowed_packet value in mysql server. I did it (brought
> up to 500M) but still the problem represent itself.
> Any other hint?

Hi Giovanni,
which version are you using?
Maybe you can try with the one from the repository:
https://github.com/alberanid/imdbpy

Besides this, you can try adding the "-c /path/to/an/empty/directory"
argument to
the command line: it will store a set of CSV files in that directory,
to be used later
to import everything in a single pass.
(pardon, don't remember if you've to enable this option in MySQL or if
it's on by default)


Hope this helps,

-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Proxy Error

2017-05-09 Thread Davide Alberani
thon2.7/site-packages/imdb/__init__.py", line
> 772, in update
> ret = method(mopID)
>   File
> "/Users/eric/test/lib/python2.7/site-packages/imdb/parser/http/__init__.py",
> line 506, in get_movie_main
> cont = self._retrieve(self.urls['movie_main'] % movieID + 'combined')
>   File
> "/Users/eric/test/lib/python2.7/site-packages/imdb/parser/http/__init__.py",
> line 453, in _retrieve
> ret = self.urlOpener.retrieve_unicode(url, size=size)
>   File
> "/Users/eric/test/lib/python2.7/site-packages/imdb/parser/http/__init__.py",
> line 202, in retrieve_unicode
> uopener = self.open(url)
>   File
> "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib.py",
> line 213, in open
> return getattr(self, name)(url)
>   File
> "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib.py",
> line 364, in open_http
> return self.http_error(url, fp, errcode, errmsg, headers)
>   File
> "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib.py",
> line 381, in http_error
> return self.http_error_default(url, fp, errcode, errmsg, headers)
>   File
> "/Users/eric/test/lib/python2.7/site-packages/imdb/parser/http/__init__.py",
> line 255, in http_error_default
> 'proxy': self.get_proxy()})
> IMDbDataAccessError: {'url':
> 'http://akas.imdb.com/title/tt001/combined', 'error type':
> 'http_error_default', 'errcode': 409, 'headers':  instance at 0x10c64bc20>, 'proxy': 'http://openwebproxy.pw/browse.php?u=/',
> 'errmsg': 'Conflict'}
> 2017-05-05 14:58:48,794 CRITICAL [imdbpy]
> /Users/eric/test/lib/python2.7/site-packages/imdb/__init__.py:777: caught an
> exception retrieving or parsing "plot" info set for mopID "001"
> (accessSystem: http)
> Traceback (most recent call last):
>   File "/Users/eric/test/lib/python2.7/site-packages/imdb/__init__.py", line
> 772, in update
> ret = method(mopID)
>   File
> "/Users/eric/test/lib/python2.7/site-packages/imdb/parser/http/__init__.py",
> line 514, in get_movie_plot
> cont = self._retrieve(self.urls['movie_main'] % movieID + 'plotsummary')
>   File
> "/Users/eric/test/lib/python2.7/site-packages/imdb/parser/http/__init__.py",
> line 453, in _retrieve
> ret = self.urlOpener.retrieve_unicode(url, size=size)
>   File
> "/Users/eric/test/lib/python2.7/site-packages/imdb/parser/http/__init__.py",
> line 202, in retrieve_unicode
> uopener = self.open(url)
>   File
> "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib.py",
> line 213, in open
> return getattr(self, name)(url)
>   File
> "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib.py",
> line 364, in open_http
> return self.http_error(url, fp, errcode, errmsg, headers)
>   File
> "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/urllib.py",
> line 381, in http_error
> return self.http_error_default(url, fp, errcode, errmsg, headers)
>   File
> "/Users/eric/test/lib/python2.7/site-packages/imdb/parser/http/__init__.py",
> line 255, in http_error_default
> 'proxy': self.get_proxy()})
> IMDbDataAccessError: {'url':
> 'http://akas.imdb.com/title/tt001/plotsummary', 'error type':
> 'http_error_default', 'errcode': 409, 'headers':  instance at 0x10c5f3dd0>, 'proxy': 'http://openwebproxy.pw/browse.php?u=/',
> 'errmsg': 'Conflict'}
>
>
> --
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> ___
> Imdbpy-help mailing list
> Imdbpy-help@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/imdbpy-help
>



-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Person - "Known For" support

2017-05-02 Thread Davide Alberani
Hi Johmphot,
no currently IMDbPY doesn't parse the "known for" section of persons.

It should not be too difficult to add it to imdb/parser/http/movieParser.py,
using the other parsers as examples.


Hope this help,


On Mon, May 1, 2017 at 7:42 AM, Johmphot Tantawichien
 wrote:
> Hi,
>
> Does IMDbPY support "Known For" tag for Person?
>
> Thank you,
> Johmphot Tantawichien
>
> --
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
> ___
> Imdbpy-help mailing list
> Imdbpy-help@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/imdbpy-help
>



-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Ratings corrected

2017-04-28 Thread Davide Alberani
On Thu, Apr 27, 2017 at 5:09 PM, Philip Earvolino  wrote:
> Upon looking at the imdbpy2sql.py script I determined that ratings get
> inserted in the movie_info_idx table.  Problem solved.

Correct - pardon for the late reply.
I guess we should revise the decision to have two separated tables, just to
have more indexes on one. :-/


-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Setting up IMDBPY on Windows

2017-04-23 Thread Davide Alberani
Hi Amy and Gonzalo,
does this happens also without --ms-sqlserver?

Another option is to run it with the -o sqlalchemy to use another ORM
(shouldn't change much...)

Besides this, I fear you have to debug this issue looking at the logs
of the db, and see why it get stuck.

Basically, imdbpy2sql.py before writing of a batch of data executes,
for some tables, something like:
  SET IDENTITY_INSERT $table ON;
and after the insert:
  SET IDENTITY_INSERT $table off;

if I remember correctly, it was needed for tables with auto-increment values.
Maybe something was changed in the latest versions of MSSQL?

HTH,

On Sat, Apr 22, 2017 at 7:49 PM, Amy Garcia Kennedy  wrote:
> Hey Gonzalo,
>
> did you find a solution to this? I have the same problem.
>
> thanks!
>
> El viernes, 6 de enero de 2017, 16:48:07 (UTC+1), Gonzalo Martinez escribió:
>>
>> Hi,
>>
>> I ran "pip install pymssql" and it is working now but it makes me wonder
>> why it did not install when running "pip install imdbpy" in the first place?
>>
>> Now, I have some issues because the following line "imdbpy2sql.py -d
>> S:/imdbData/ -u
>> mssql://GMDATASERVER\Administrator:Pa$$w0rd@GMDATASERVER/imdbGM
>> --ms-sqlserver" stalled an is stuck at this point...
>>
>> EXECUTING "BEFORE_MOVIES_TODB:SET IDENTITY_INSERT %(table)s
>> ON;"...EXECUTING "SET IDENTITY_INSERT title ON;"...
>>
>> It's been 2h+ and it  hasn't moved so there something wrong I'm sure.
>>
>> I'm using python 2.7 (the latest available at the moment from python.org),
>> Windows Server 2012R2 and SQL Server 2016 trial... all is fully patched.
>>
>>
>>
>>
>> Thanks for any help you guys can provide me.
>>
>>
>>
>>
>>
>>  On Fri, 06 Jan 2017 07:28:24 -0500 Davide Alberani
>>  wrote 
>>
>> On Wed, Jan 4, 2017 at 6:31 PM, Gonzalo Martinez 
>> wrote:
>> >
>> > ImportError: Cannot find an MSSQL driver, tried adodb,pymssql
>>
>> Hi Gonzalo,
>> have you also installed the pymssql package?
>>
>> HTH,
>>
>> --
>> Davide Alberani  [PGP KeyID: 0x3845A3D4AC9B61AD]
>> http://www.mimante.net/
>>
>>
>



-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] switch to git and the future of bitbucket

2017-04-17 Thread Davide Alberani
Hi all,
I've just moved the main repository of IMDbPY from Mercurial to Bitbucket,
please take notice (below, the reasons for this action).

I've moved the old Mercurial repository of IMDbPY to
https://bitbucket.org/alberanid/imdbpy-mercurial-repository
Then I've created a new Git repo, https://bitbucket.org/alberanid/imdbpy/

>From now on, the source code of IMDbPY can be taken from
github ( https://github.com/alberanid/imdbpy ) or this new Git repo
on Bitbucket: they will be kept in sync.

I hope this doesn't cause too much trouble. :-)


Best regards,


On Sun, Apr 9, 2017 at 10:14 AM, Davide Alberani
 wrote:
> Hi all,
> While I'm still not able to devote to IMDbPY the resources it needs,
> I'm glad to see that some pull requests are being open and there's
> still interest in the project. :-)
>
> Historically, IMDbPY has been hosted as a Mercurial repository
> on Bitbucket.
> Some years ago, when the future of Bitbucket was unclear,
> to allow more contributors a Git mirror on Github was created.
>
> Since today most of the pull requests and open issues
> comes from there, I have some problems keeping
> everything in sync.
> The sync requires the mercurial-git plugin, which works fine,
> but also has to keep its own meta-data to match the different
> schema of commit IDs, and I fear it will break, sooner or later
> (plus, it makes my *local* clone of the Mercurial repository a
> single point of failure for this sync: no one else would be able
> to do it).
>
> So, if there're no valid reason to do otherwise, my plan is:
> - rename the mercurial repository on Bitbucket
> - create a new *Git* Bitbucket project
> - keep them in sync as different origins.
>
> Sure, we could also close the Bitbucket account, but with
> Git is easy enough to keep everything aligned.
> Another option would be a switch to Gitlab, but we would
> have to pay for our own hosting, and right now I don't see
> any reason to do so.
>
> Any opinions on this?
> I plan to do the switch within a few days.
>
>
> (also, I have deleted an outdated repository on Sourceforge)
>
> --
> Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
> http://www.mimante.net/



-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Adding foreign keys exceptions caught when loading imdb data to mysql using imdbpy

2017-04-17 Thread Davide Alberani
On Sun, Apr 9, 2017 at 5:37 PM, Zhongjun Jin  wrote:
>
> The two suggested option might not applicable in my case, where the complete
> schema information (primary keys and foreign keys) is most important to me.

The main hint was to follow the fix proposed by Roberto Larcher.

I quote:


To solve the issue I commented the line
params['local_infile'] = 1

inside the fucntion
setConnection

of the alchemyadapter.py file.

In my system the file is located in the following directory:
/usr/lib/python2.7/dist-packages/imdb/parser/sql/alchemyadapter.py

I don't know if this will influence other processes but after this
modification the imdbpy2sql.py script is correctly running

Note that my mysql server is configured in order to allow local infile command.



> Do you know if any of the old version of imdbpy has no such bugs?

I'm not convinced it's a problem in IMDbPY (well, besides for how it
uses third-party libraries),
SQLAlchemy or SQLObject.
I think it's more due to the settings of MySQL and/or the Python
mysqldb library.

Anyway, it's a bug that must be fixed, at some point...


-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Adding foreign keys exceptions caught when loading imdb data to mysql using imdbpy

2017-04-09 Thread Davide Alberani
On Sun, Apr 9, 2017 at 4:38 AM, Zhongjun Jin  wrote:
>
> However, when I tried sqlalchemy using the following command:
> python imdbpy2sql.py -d [imdb_file_directory] -o sqlalchemy -u
> 'mysql://user:password@localhost/imdb?charset=utf8&local_infile=1'

Hi,
that's probably another bug, recently spotted by others. :(

See https://groups.google.com/d/msg/imdbpy-users/b47oYFVGqeQ/9SJqkhh-BwAJ
for a possible fix.

It will take some time, but I hope to be able to fix all of this stuff.

By the way, you don't have to use a complete set of files downloaded from
IMDb to do some test: you can just leave movies.list.gz (or any other file) in
a directory, and use only that.
Another option to quickly test everything, is to copy the docs/goodies/reduce.sh
file in the directory with the complete .list.gz files, and run it to create a
sub-directory named 'partial' with only 10% of each file.


HTH,
-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Adding foreign keys exceptions caught when loading imdb data to mysql using imdbpy

2017-04-08 Thread Davide Alberani
On Sat, Apr 8, 2017 at 8:10 PM, Zhongjun Jin  wrote:
>
> Could you please give me some hints about what I might have done wrong?

I don't think it's your fault, most probably it's a bug.

It may be related to https://github.com/alberanid/imdbpy/pull/40 (that
will be merged
after some tests... give me some days).

Another option, is to use SQLAlchemy instead of SQLObject.
Try installing it and using it adding "-o sqlalchemy" (no quotes) to
the command line
options of imdbpy2sql.py .

HTH,

-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] [imdbpy-help] Re: Problems using imdbpy2sql.py

2017-03-23 Thread Davide Alberani
On Mon, Mar 20, 2017 at 4:59 PM, Roberto Larcher  wrote:
>
> I don't know if this will influence other processes but after this
> modification the imdbpy2sql.py script is correctly running

Thanks for the help!
Maybe now the parameter should be added to the URL?

Like 
https://stackoverflow.com/questions/29903790/load-data-local-infile-sqlalchemy-and-python-to-mysql-db


-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Imdb id restore

2017-03-23 Thread Davide Alberani
On Tue, Mar 21, 2017 at 2:27 PM, Robert McGirr  wrote:
>
> However, on updating the script reports that imdb_id's have been
> successfully restored, but they are not present in the updated Db. Am I
> missing something or what could be wrong?

Hi Robert,
no, you're not missing something.

The IDs (as seen on the IMDb's site) are not present in the plain text
data files.
Some functions - like the ones to retrieve the cover URL or the movie/personID -
will try to retrieve them doing a query on the web site.
If found, it's also stored in the db so that it can be restored later,
once the db
is update (removing it completely and recreating it)

So, at the first run, it's ok if the imdb_id column is empty.


HTH,

-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] imdbpy installation problem

2017-02-28 Thread Davide Alberani
On Tue, Feb 28, 2017 at 1:17 AM, David HAN  wrote:
> I’m using MAC Air with MacOS Sierra, python 3.5

Hi David,
right now you really have to use Python 2.7

A 3.x version is being worked on, but will not be ready anytime soon.


HTH,



-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] API details: Starmeter

2017-02-20 Thread Davide Alberani
On Mon, Feb 20, 2017 at 1:21 AM, Dean Gebert  wrote:
>
> Does your API include details from the Pro version, like their StarMeter
> ranking?

Hi Dean,
no, the information in the Pro version is not covered and I don't have plans
to support it in the future.


HTH,

-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] obtining info in other languages

2017-02-10 Thread Davide Alberani
On Fri, Feb 10, 2017 at 3:16 PM, Gaspare Marco Covello
 wrote:
>
> hello, i'm going mad trying to get infos in some other language(in my case
> italian) about a movie such as title, plot and other...

Not sure that plot is available in any language other than English.

Using IMDbPY, you can only access title's AKAs (Also Known As).

Example:

>>> from imdb import IMDb
>>> ia = IMDb()
>>> m = ia.get_movie('0096438')
>>> print m.get('akas')
[u'\xbfQui\xe9n enga\xf1\xf3 a Roger Rabbit?::Argentina, Mexico (imdb
display title), Peru, Spain', u'\u041a\u0442\u043e
\u043f\u043e\u0434\u0441\u0442\u0430\u0432\u0438\u043b
\u043a\u0440\u043e\u043b\u0438\u043a\u0430
\u0420\u043e\u0434\u0436\u0435\u0440\u0430::Russia, Soviet Union
(Russian title)', u'Falsches Spiel mit Roger Rabbit::Germany (imdb
display title), West Germany', u'Qui veut la peau de Roger
Rabbit?::Canada (French title), France',
u'\u03a0\u03bf\u03b9\u03bf\u03c2
\u03c0\u03b1\u03b3\u03af\u03b4\u03b5\u03c8\u03b5 \u03c4\u03bf\u03bd
\u03a1\u03cc\u03c4\u03b6\u03b5\u03c1
\u03a1\u03ac\u03bc\u03c0\u03b9\u03c4::Greece', u'\u041a\u043e\u0439
\u043d\u0430\u0442\u043e\u043f\u0438 \u0437\u0430\u0435\u043a\u0430
\u0420\u043e\u0434\u0436\u044a\u0440?::Bulgaria (Bulgarian title)',
u'Chi ha incastrato Roger Rabbit::Italy (imdb display title)', u'Hvem
lurte Roger Rabbit?::Norway (imdb display title)', u'Hvem sn\xf8rede
Roger Rabbit?::Denmark (imdb display title)', u'Kdo je potunkal
Rogerja zajca::Slovenia (imdb display title)', u'Ko je smestio Zeki
Rod\u017eeru::Serbia', u'Kto wrobil kr\xf3lika Rogera?::Poland',
u'Kuka viritti ansan, Roger Rabbit?::Finland', u'Masum sanik Roger
Rabbit::Turkey (Turkish title)', u'Poios pagidepse ton Roger
Rabbit?::Greece (transliterated ISO-LATIN-1 title)', u'Quem Tramou
Roger Rabbit?::Portugal', u'Qui ha enredat en Roger Rabbit?::Spain
(Catalan title) (imdb display title)', u'Roger Rabbit::Japan (English
title) (imdb display title)', u'Roger ny\xfal a p\xe1cban::Hungary',
u'Uma Cilada Para Roger Rabbit::Brazil', u'Vem satte dit Roger
Rabbit::Sweden (imdb display title)', u'Vem satte dit Roger
Rabbit?::Finland (Swedish title)']

To identify your language, simply split each entry at '::' and see if
"Italian" or "Italy" is
contained in the second item.


Hope this helps,

-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] imdbpy2sql.py SyntaxError

2017-02-02 Thread Davide Alberani
Hi,

it seems that you're using Python 3.x; unfortunately, right now,
IMDbPY works only with Python 2.x.

Hope this helps,



On Thu, Feb 2, 2017 at 3:19 AM, Xinge Lu  wrote:

> Dear Ms/Mr:
> Hi. I'm a student trying to use the imdbpy to get the data from imdb files.
> When I using the following command
>
> python imdbpy2sql.py -d /path/to/the/plain/text/data/files/ -u 
> mysql://USER:PASSWD@localhost/imdb
>
>
> [image: 内嵌图片 1]
>
> The system said there is a SyntaxError in the line 185. (I'm using the
> Win10 System) I cound't find the answer on the internet, So I write this
> email to get help.
> Thanks for your time.
>
> Best,
> Xinge Lu
>
> 
> --
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, SlashDot.org! http://sdm.link/slashdot
> ___
> Imdbpy-help mailing list
> Imdbpy-help@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/imdbpy-help
>
>


-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/
--
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Setting up IMDBPY on Windows

2017-01-28 Thread Davide Alberani
On Fri, Jan 6, 2017 at 4:32 PM, Gonzalo Martinez  wrote:
>
> I ran "pip install pymssql" and it is working now but it makes me wonder why
> it did not install when running "pip install imdbpy" in the first place?

Hi, and pardon the long delay.

That's normal: the dependency is on the ORM (sqlobect or sqlalchemy),
not on the specific driver to access a database, that depends on which
system you are on and which db you want to access.

> Now, I have some issues because the following line "imdbpy2sql.py -d
> S:/imdbData/ -u
> mssql://GMDATASERVER\Administrator:Pa$$w0rd@GMDATASERVER/imdbGM
> --ms-sqlserver" stalled an is stuck at this point...

Unfortunately I have no experience on this db.
Maybe you can try without the --ms-sqlserver argument, which by the way
executes some commands at specific times.


HTH,

-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Issues Updating imdb database with movie objects on Mac

2017-01-06 Thread Davide Alberani
On Tue, Dec 27, 2016 at 8:07 PM, Michael Solsky
 wrote:
>
>   I’m attaching two output files.  One from a macbook pro running yosemite 
> 10.10.5, the other is from a raspberry pi 3 running debian.  The database 
> seem to be populate
> d on the mac, but I can’t seem to update the movie object still.  The 
> raspberry pi seemed to get stuck. Any help would be appreciated.  Thank you.

Hi Michael,
The problem seems to be that you hit too many times the query limit of your db:
* FLUSHING MoviesCache...
 * TOO MANY DATA (10 items in MoviesCache), recursion: 1
   * SPLITTING (run 1 of 2), recursion: 1
 * FLUSHING MoviesCache...
 * TOO MANY DATA (5 items in MoviesCache), recursion: 2
   * SPLITTING (run 1 of 2), recursion: 2
 * FLUSHING MoviesCache...
   * SPLITTING (run 2 of 2), recursion: 2
 * FLUSHING MoviesCache...
   * SPLITTING (run 2 of 2), recursion: 1

However it may also be a problem in our code.
Are your *certain* to be using the latest version of IMDbPY, right?
We fixed such bugs, some months ago.

If this persists, have you tried increasing max_allowed_packet of
MySQL server to at least 16M?
Another option, is to use a series of CSV files to import the data all
at once, which
should also be faster.
Basically, you've just to create an empty directory somewhere and add
-c /path/to/empty/directory
to the imdbpy2sql.py command line.


HTH,

-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Setting up IMDBPY on Windows

2017-01-06 Thread Davide Alberani
On Wed, Jan 4, 2017 at 6:31 PM, Gonzalo Martinez  wrote:
>
> ImportError: Cannot find an MSSQL driver, tried adodb,pymssql

Hi Gonzalo,
have you also installed the pymssql package?

HTH,

-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] WARNING: unable to restore imdbIDs using

2017-01-06 Thread Davide Alberani
On Thu, Dec 29, 2016 at 3:30 PM, Márton Szabó  wrote:
>
> I know these are just warnings, but I checked the tables in the database,
> they were all missing imdb id-s. How can I make them appear in the tables?

They are not populated automatically, since they are not included in
the downloaded files.
IMDbPY writes them when you're explicitly asking for them, using for example
the get_imdbID, get_imdbURL or title2imdbID/name2imdbID methods.
Then, once you upgrade your db, they are (hopefully) preserved.


-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Issues Updating imdb database with movie objects on Mac

2016-12-19 Thread Davide Alberani
etch information for movieID 3805020: The object Title by the ID 3805020 
> does not exist
> 2016-12-07 17:43:56,736 CRITICAL [imdbpy] 
> /Library/Python/2.7/site-packages/imdb/_exceptions.py:35: IMDbDataAccessError 
> exception raised; args: ('unable to get movieID "3805020"',); kwds: {}
> Traceback (most recent call last):
>   File "/Library/Python/2.7/site-packages/imdb/__init__.py", line 772, in 
> update
> ret = method(mopID)
>   File "/Library/Python/2.7/site-packages/imdb/parser/sql/__init__.py", line 
> 1037, in get_movie_main
> raise IMDbDataAccessError('unable to get movieID "%s"' % movieID)
> IMDbDataAccessError: unable to get movieID "3805020"
> 2016-12-07 17:43:56,802 CRITICAL [imdbpy] 
> /Library/Python/2.7/site-packages/imdb/__init__.py:777: caught an exception 
> retrieving or parsing "plot" info set for mopID "3805020" (accessSystem: sql)
> Traceback (most recent call last):
>   File "/Library/Python/2.7/site-packages/imdb/__init__.py", line 772, in 
> update
> ret = method(mopID)
>   File "/Library/Python/2.7/site-packages/imdb/parser/sql/__init__.py", line 
> 1037, in get_movie_main
> raise IMDbDataAccessError('unable to get movieID "%s"' % movieID)
> IMDbDataAccessError: unable to get movieID "3805020"
>
> Traceback (most recent call last):
>   File "/Users/AA/code/python/imdbpy/test_imdbpy_sql2.py", line 8, in 
> print ti['director'][0]
>   File "/Library/Python/2.7/site-packages/imdb/utils.py", line 1472, in 
> __getitem__
> rawData = self.data[key]
> KeyError: 'director'
> --
> Developer Access Program for Intel Xeon Phi Processors
> Access to Intel Xeon Phi processor-based developer platforms.
> With one year of Intel Parallel Studio XE.
> Training and support from Colfax.
> Order your platform today.http://sdm.link/xeonphi
> ___
> Imdbpy-help mailing list
> Imdbpy-help@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/imdbpy-help



-- 
Davide Alberani   [PGP KeyID: 0x3845A3D4AC9B61AD]
http://www.mimante.net/

--
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today.http://sdm.link/intel
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Prune SQL database

2016-11-28 Thread Davide Alberani
On Fri, Nov 25, 2016 at 7:53 PM, Mohamed Oun  wrote:
>
> I was wondering if there was a way to prune the database to remove all titles 
> that have <200 votes for example, to reduce clutter.

Hi Mohamed,
it's not so simple, I fear: IMDbPY was thought to fetch a single
item at a time.

Your best option is to select the data according to your needs.
For example, let's assume you want to extract movie_id (as internally
used by IMDbPY - beware that this is NOT the ID used on the site, a
thing that we don't have, locally) - plus its title and the number of votes of
every movie with more than 200 votes.

First, check out the content of the info_type (yeah, bad name, sorry) table,
to find the id of the "votes" entry.  In my database, it's 100.

The movie_info (and/or movie_info_idx) table contains all the information
about a movie, with info_type_id set accordingly.

So, we need to select stuff from tables 'title' and 'movie_info', based
on the relation between title.id and movie_info.movie_id (to know which
movie we're dealing with) and filtering based on movie_info.info_type_id
and also filtering out anything contained in movie_info.value that is less
than 200 (beware that this field is always a string).

Now, for PostgreSQL it would be something like (to show the first 10 results):
SELECT t.id, t.title, i.info FROM title t, movie_info_idx i WHERE t.id
= i.movie_id AND i.info_type_id = 100 AND CAST(i.info AS int) >= 200
LIMIT 10;

If you're using MySQL the syntax is something different, but the
concept is the same
(there's an implicit INNNER JOIN in the above statement).

A last note: beware that the data structure of IMDbPY may lack some index that
you may need to speed thing up.  In that case, just create them before
processing.

> Also, is there a way to iterate over all the titles in the database?

Well, you can always export a list of imdb_id and iterate over it.
Honestly, doing so using IMDbPY could be veeery slow, since it assumes
that you want to access most  or all the information about a title immediately.

If you only need some, you better use IMDbPY to import the data in a db (like
you have already done) and find the data you need using SQL queries.


Hope this helps,

-- 
Davide Alberani   [PGP KeyID: 0x465BFD47]
http://www.mimante.net/

--
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


[Imdbpy-help] IMDbPY 5.1 is out!

2016-11-18 Thread Davide Alberani
Hi all,
while there're not many news on the development front,
I've just release version 5.1 to have a more up-to-date
packaged version:
  https://sourceforge.net/projects/imdbpy/files/IMDbPY/5.1/

As always, any help in fixing the bugs that are left is welcome. :-)

Oh, by the way: I'm currently unable to build a Windows package
for this release.  If anyone has a working environment to generate
the installer... ;-)

-- 
Davide Alberani   [PGP KeyID: 0x465BFD47]
http://www.mimante.net/

--
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Errors running the module

2016-11-13 Thread Davide Alberani
On Sun, Nov 6, 2016 at 3:53 PM, Mohamed Oun  wrote:
>
> Okay Davide, so I managed to get it to work by switching to Ubuntu and 
> ditching windows entirely, kind of unorthodox haha.

:-)
Glad at least this is working.

> So now I want to split the votes distribution column into 10 different 
> columns, one for each number. How do you think that could be done?

Hmmm... do you really need to do it in the database?
After all, you can read it and split it in python or any other programming
language.

Anyway, you can surely create a series of 10 new columns in the title tables,
to store the single digits, but also in this case you have to parse each value,
identify the movie_id, split the votes distribution (with the substring function
present in most SQL servers) and store them.
Not so simple to do, but should work.


-- 
Davide Alberani   [PGP KeyID: 0x465BFD47]
http://www.mimante.net/

--
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today. http://sdm.link/xeonphi
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Errors running the module

2016-11-01 Thread Davide Alberani
Hi Mohamed,
I don't like the WARNING messages at all, to be honest.
I hope to be able to test it soon, but I fear it could take me some time.

Your code is mostly correct, but there's an important thing to check:
are you sure that the first result of a query for "breaking bad"
contains the key "runtime"?
Usually, only the single episodes contain such key, not the series itself.

If in doubt, always use bb.get('runtime')


Hope this helps,



On Mon, Oct 24, 2016 at 6:33 AM, Mohamed Oun  wrote:

> Hello, so the memory error was solved by restarting the machine. And I
> built the database, however, I'm not sure it's complete, as when trying it
> I get a lot of errors.
> Here's my code:
>
> from imdb import IMDb
>
> ia = IMDb('sql', uri='mysql://root:@localhost/imdb')
>> s_result = ia.search_movie('breaking bad')
>>
>> # Retrieves default information for the first result (a Movie object).
>> bb = s_result[0]
>> ia.update(bb)
>> # Print some information.
>> print bb['runtime']
>> print bb['rating']
>
> And here's what's thrown at me:
>
>> 2016-10-24 06:30:23,743 WARNING [imdbpy.parser.sql.aux]
>> C:\Python27\lib\site-packages\imdb\parser\sql\__init__.py:458: Unable to
>> fetch information for movieID 3768839: The object Title by the ID 3768839
>> does not exist
>> 2016-10-24 06:30:23,744 WARNING [imdbpy.parser.sql.aux]
>> C:\Python27\lib\site-packages\imdb\parser\sql\__init__.py:458: Unable to
>> fetch information for movieID 2823261: The object Title by the ID 2823261
>> does not exist
>> 2016-10-24 06:30:23,744 WARNING [imdbpy.parser.sql.aux]
>> C:\Python27\lib\site-packages\imdb\parser\sql\__init__.py:458: Unable to
>> fetch information for movieID 2739602: The object Title by the ID 2739602
>> does not exist
>> 2016-10-24 06:30:23,744 WARNING [imdbpy.parser.sql.aux]
>> C:\Python27\lib\site-packages\imdb\parser\sql\__init__.py:458: Unable to
>> fetch information for movieID 3558248: The object Title by the ID 3558248
>> does not exist
>> 2016-10-24 06:30:23,744 WARNING [imdbpy.parser.sql.aux]
>> C:\Python27\lib\site-packages\imdb\parser\sql\__init__.py:458: Unable to
>> fetch information for movieID 2819137: The object Title by the ID 2819137
>> does not exist
>> 2016-10-24 06:30:23,746 WARNING [imdbpy.parser.sql.aux]
>> C:\Python27\lib\site-packages\imdb\parser\sql\__init__.py:458: Unable to
>> fetch information for movieID 2810071: The object Title by the ID 2810071
>> does not exist
>> 2016-10-24 06:30:23,746 WARNING [imdbpy.parser.sql.aux]
>> C:\Python27\lib\site-packages\imdb\parser\sql\__init__.py:458: Unable to
>> fetch information for movieID 0: The object Title by the ID 0 does not exist
>> Traceback (most recent call last):
>>   File "E:/Dropbox/Learning/untitled/untitled.py", line 14, in 
>> print bb['runtime']
>>   File "C:\Python27\lib\site-packages\imdb\utils.py", line 1469, in
>> __getitem__
>> rawData = self.data[key]
>> KeyError: 'runtimes'
>
> Does this mean a problem in the module, or in the database, or my code?
> --
> *Best Regards, *
> *Mohamed Oun*
>
>
>
>
> 
> --
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, SlashDot.org! http://sdm.link/slashdot
> ___
> Imdbpy-help mailing list
> Imdbpy-help@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/imdbpy-help
>
>


-- 
Davide Alberani   [PGP KeyID: 0x465BFD47]
http://www.mimante.net/
--
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today. http://sdm.link/xeonphi___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Updating the database weekly

2016-10-15 Thread Davide Alberani
On Sun, Oct 9, 2016 at 2:43 PM, Mohamed Oun  wrote:

> Hello, I'd like to know if there's an efficient way to update the SQL
> database every week (when the new files are uploaded) to update it with new
> movies/ratings, without having to rebuild the entire database from scratch?
>
>
​Hi Mohamed,
I fear currently there's no way to update it without starting from scratch.
:-/​

​As always, any help improving IMDbPY is welcome.​


-- 
Davide Alberani   [PGP KeyID: 0x465BFD47]
http://www.mimante.net/
--
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] MemoryError

2016-10-15 Thread Davide Alberani
On Thu, Sep 29, 2016 at 1:00 AM, Abraham Whiskas
 wrote:
> Sorry, it doesn't work afterall.. so if anyone has any ideas ideas..

Hi Abraham,
are you using the version from the repository?

I'll try to reproduce it in the next days.


-- 
Davide Alberani   [PGP KeyID: 0x465BFD47]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Student project

2016-10-09 Thread Davide Alberani
Hi Ahmed,
in fact IMDb already provides you a list with all the titles: it's the
movies.list.gz file that you can download from http://www.imdb.com/interfaces

If you need to extract the data, you can use the IMDbPY's imdbpy2sql.py script
to populate a SQL database of your choice:
http://imdbpy.sourceforge.net/docs/README.sqldb.txt


Hope this helps,

On Fri, Oct 7, 2016 at 12:50 AM, Ahmed Elsafy
 wrote:
> Dear IMDB
>
> I am conducting a project for my studies of neural networks, I need a list
> of all the film titles ever made, I was checking your API and I see I can
> pull a lot of useful info with it.
>
> Is it possible to run a command to pull all the titles names in a list?
>
> Thanks best regards
>
>
> --
> Check out the vibrant tech community on one of the world's most
> engaging tech sites, SlashDot.org! http://sdm.link/slashdot
> ___
> Imdbpy-help mailing list
> Imdbpy-help@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/imdbpy-help
>



-- 
Davide Alberani   [PGP KeyID: 0x465BFD47]
http://www.mimante.net/

--
Check out the vibrant tech community on one of the world's most 
engaging tech sites, SlashDot.org! http://sdm.link/slashdot
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Ratings distribution

2016-09-25 Thread Davide Alberani
On Fri, Sep 23, 2016 at 6:19 PM, Mohamed Oun  wrote:
>
> Hello, I have a question about the module. I see that it can convert the 
> lists to SQL. But I don't think it saves the ratings distribution column in 
> the ratings.list file.

The values you're looking for are stored in the movie_info_idx table,
that works exactly like the movie_info table, but has some extra
index.



-- 
Davide Alberani   [PGP KeyID: 0x465BFD47]
http://www.mimante.net/

--
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] KeyErrors

2016-09-05 Thread Davide Alberani
On Sun, Sep 4, 2016 at 12:47 PM, Jonathan Carrera  wrote:
>
> I'm always getting KeyErrors for: main, trivia, parents guide, and goofs.

I Jonathan,
which version are you using?  It's recommended to use the one in the
bitbucket or github repository.

If the problem persists, can you provide a small snippet of code to
reproduce the bug?


Thanks,

-- 
Davide Alberani   [PGP KeyID: 0x465BFD47]
http://www.mimante.net/

--
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Interfaces specification for IMDb data needed

2016-08-29 Thread Davide Alberani
On Wed, Aug 24, 2016 at 5:21 PM, Stephanie Geiling
 wrote:
>
> Could you provide the interface specification for IMDb data import (like 
> synopsis, persons, movie title and everything else that could be imported to 
> thirdparty systems) please?

Hi Stephanie,
what do you mean with "interface specification"?
If you mean the layout of the database, the best description is
in the code, in the imdb.parser.sql.dbschema module, which
describes all the tables, columns and relations.

If you mean, which set of information are available,
IMDbPY can import all the files that can be downloaded
from ftp://ftp.fu-berlin.de/pub/misc/movies/database/

> And also licence / terms of use papers.

IMDbPY is released under the terms of the GPL 2.0 or later license;
please don't forget that the data are subject to the IMDb's terms.
See http://www.imdb.com/interfaces and http://www.imdb.com/conditions


Hope this helps,

-- 
Davide Alberani   [PGP KeyID: 0x465BFD47]
http://www.mimante.net/

--
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Help - MemoryError

2016-07-31 Thread Davide Alberani
On Sun, Jul 31, 2016 at 3:50 PM, Walisson Sousa 
wrote:

> I'm trying to import the imdb database using imdbpy. But there are
> ocurring an error.
> After a while, the system shows the messagem: MemoryError
>

​Hi Walisson,
as Bret said, unfortunately the imdbpy2sql.py requires a lot of RAM. :-/

Maybe you can lower its memory usage with the -c option; see the "CSV files"
section of http://imdbpy.sourceforge.net/docs/README.sqldb.txt

Basically, you have to create an empty directory (readable by your database
server)
that will be used to store some temporary files that will imported all at
once near
the end of the process.​


​Hope this helps!​


-- 
Davide Alberani   [PGP KeyID: 0x465BFD47]
http://www.mimante.net/
--
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Movie Ratings in the Database

2016-07-31 Thread Davide Alberani
On Tue, Jul 26, 2016 at 5:31 AM, Janmejai Pratap Singh
 wrote:
> I can see from the documentation that, there are ways to retrieve
> ratings for the movies. But I needed them in the database, is their
> any way to get them in the database?

Hi,
exactly: the usual way, consists in using IMDbPY to get a movie object
and with that read the rating.

If you need to directly work on the database, it's still possible.
I cut & paste from an old mail with a similar request:


To answer where most of the information are: most of the data is in
the movie_info and person_info tables.
There, a movie_id (or person_id) and an info_type_id (a reference to
entries in the info_type table) can be used to identify the meaning of
the 'info' column.

For example, to get the rating information for movies:
- to to the info_type table and search for the ID of the info 'rating' (in
  my case, 101)
- now you should usually see into the movie_info_table... but the rating
  information are a special case and requires different indexes (that's
  a thing I want to change...) and are stored separately, in the
movie_info_idx table
- there, you can see which movie have a given rate looking at the movie_id,
  info_type_id (entries with 101) and 'info' (which actually store the rating).

All this steps are made transparent by the IMDbPY library, as documented
in http://imdbpy.sourceforge.net/docs/README.sqldb.txt  (SQL USAGE section:
it's pretty simple and identical to the use accessing the web data)
If it's better to use IMDbPY or directly the database is up to you, depending
on the goal you need to reach.


Hope this helps,


-- 
Davide Alberani   [PGP KeyID: 0x465BFD47]
http://www.mimante.net/

--
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] imdbpy2sql table naming schema

2016-07-17 Thread Davide Alberani
On Wed, Jul 6, 2016 at 7:57 AM, Max Rosenbaum  wrote:
>
> I am having a play with the imdbpy2sql script. Having a look at the UML
> diagram of the DB, there are some tables that seem redundant as well as
> interesting naming schemes. In particular, the tables prefixed with "aka_".
> What is this shorthand for? A googling around hasn't revealed anything :(

Hi,
AKA is an abbreviation of "also known as", for alternative names of
persons or movie titles.

> Also, in the upper right hand corner of the diagram, the aka_title and
> link_type tables have no relations, should aka_title relate to the title
> table as movie_id:id ?

Yes, exactly.

> and if link_type table needs a relation what table should it relate to?

That's used to identify the kind of link between two movies ("remake of",
"spoofed in", ...)
The relation should be between movie_link.link_type_id : link_type.id

It's strange that these two relations are missing, since they are both
specified in their imdb.parser.sql.dbschema entries.


Thanks for your analysis!

-- 
Davide Alberani   [PGP KeyID: 0x465BFD47]
http://www.mimante.net/

--
What NetFlow Analyzer can do for you? Monitors network bandwidth and traffic
patterns at an interface-level. Reveals which users, apps, and protocols are 
consuming the most bandwidth. Provides multi-vendor support for NetFlow, 
J-Flow, sFlow and other flows. Make informed decisions using capacity planning
reports.http://sdm.link/zohodev2dev
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] IMDb is an undefined variable in IMDBPY

2016-05-18 Thread Davide Alberani
Hi,
The IMDb function is defined in the imdb module.

On Wed, May 18, 2016 at 6:34 PM, Ankit Krishnabhai Talele
 wrote:
> I get error that IMDb() Is not there
>
>
>
>
>
> Thanks
>
> Ankit Talele
>
> +91-7259617611
>
>
>
> This e-mail contains Privileged and Confidential Information intended solely
> for the use of the addressee(s). It shall not attach any liability on the
> sender or Brillio or its affiliates. Any views or opinions presented in this
> email are solely those of the sender and may not necessarily reflect the
> opinions of Brillio or its affiliates. If you are not the intended
> recipient, you should not disseminate, distribute or copy this e-mail.
> Please notify the sender immediately and destroy all copies of this message
> and any attachments. WARNING: Computer viruses can be transmitted via email.
> While Brillio has taken reasonable precautions to minimize this risk,
> Brillio accepts no liability for any damage that may be caused to you in the
> event that there is any virus in this e-mail or any attachments attached
> hereto. It is the addresses(s) duty to check and scan this email and any
> attachments attached hereto for the presence of viruses prior to opening the
> email. ** Thank You **
>
> --
> Mobile security can be enabling, not merely restricting. Employees who
> bring their own devices (BYOD) to work are irked by the imposition of MDM
> restrictions. Mobile Device Manager Plus allows you to control only the
> apps on BYO-devices by containerizing them, leaving personal data untouched!
> https://ad.doubleclick.net/ddm/clk/304595813;131938128;j
> ___
> Imdbpy-help mailing list
> Imdbpy-help@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/imdbpy-help
>



-- 
Davide Alberani   [PGP KeyID: 0x465BFD47]
http://www.mimante.net/

--
Mobile security can be enabling, not merely restricting. Employees who
bring their own devices (BYOD) to work are irked by the imposition of MDM
restrictions. Mobile Device Manager Plus allows you to control only the
apps on BYO-devices by containerizing them, leaving personal data untouched!
https://ad.doubleclick.net/ddm/clk/304595813;131938128;j
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Help with IMDb Soundtracks

2016-05-08 Thread Davide Alberani
On Tue, Apr 26, 2016 at 11:57 PM, Isaias Suarez
 wrote:
>
> I'm trying to use IMDbpy to pull soundtrack data from IMDb, but there
> doesn't seem to be a way of accessing the data for me. I've tried everything
> I've seen on StackOverflow about it and none of it seems to be helping. When
> I try to import the .list.gz files the script just ignores the soundtracks
> file. Can you help me with this?

Are you sure you're using the version from the repository?
This bug was already fixed:
https://bitbucket.org/alberanid/imdbpy/issues/45/soundtrack-not-read-from-plain-text-data


-- 
Davide Alberani   [PGP KeyID: 0x465BFD47]
http://www.mimante.net/

--
Find and fix application performance issues faster with Applications Manager
Applications Manager provides deep performance insights into multiple tiers of
your business applications. It resolves application problems quickly and
reduces your MTTR. Get your free trial!
https://ad.doubleclick.net/ddm/clk/302982198;130105516;z
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Regarding imdb interfaces

2016-05-08 Thread Davide Alberani
On Sat, Apr 30, 2016 at 10:05 AM, Tharun raj  wrote:
>  I am unable to download the mirrors of the "The Plain Text Data
> Files" from
> the http://www.imdb.com/interfaces/ page because this download page is
> available only in Germany and Finland.

Those are just the countries that host the mirror.
The data is exactly the same on each one, just download one.


HTH,


-- 
Davide Alberani   [PGP KeyID: 0x465BFD47]
http://www.mimante.net/

--
Find and fix application performance issues faster with Applications Manager
Applications Manager provides deep performance insights into multiple tiers of
your business applications. It resolves application problems quickly and
reduces your MTTR. Get your free trial!
https://ad.doubleclick.net/ddm/clk/302982198;130105516;z
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] install failed with error code 1

2016-03-28 Thread Davide Alberani
On Thu, Feb 18, 2016 at 12:13 AM, Philip Earvolino  wrote:
>
>  My OS is Mac (10.10.5).  Any help would be very much appreciated.  Thank
> you.

Hi,
pardon for the long delay: you're using Python 3.x; IMDbPY right now is only
compatible with Python 2.x, so I suggest you to install the latest version of
Python 2.7 (both versions can be installed at the same time).


Hope this helps,


-- 
Davide Alberani   [PGP KeyID: 0x465BFD47]
http://www.mimante.net/

--
Transform Data into Opportunity.
Accelerate data analysis in your applications with
Intel Data Analytics Acceleration Library.
Click to learn more.
http://pubads.g.doubleclick.net/gampad/clk?id=278785471&iu=/4140
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] retrieving all movies and csv file

2016-03-06 Thread Davide Alberani
On Sat, Feb 27, 2016 at 2:18 AM, Andrew Tran  wrote:
>
> I am currently taking information interfaces in college. I was thinking of
> doing a visualization based on a movies' release date, genre, rating,
> budget, and box office. Your API would be perfect for this. I was just
> wondering how I would be able to retrieve every movie in existence or at
> least all the movies in IMDB's database. I saw the link you posted about
> having to create a server. Is there an alternative where I can just download
> or form csv files?

Hi, and pardon for the delay in the answer.

Your best option is to start with
http://imdbpy.sourceforge.net/docs/README.sqldb.txt
and in general reading the files in http://imdbpy.sourceforge.net/support.html

If you need more specific help, feel free to ask.

(by the way: please always use the latest version from the git repository)


-- 
Davide Alberani   [PGP KeyID: 0x465BFD47]
http://www.mimante.net/

--
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] imdbpy2sql output errors

2016-01-24 Thread Davide Alberani
On Sat, Jan 23, 2016 at 11:44 PM, mosley  wrote:
>
> I worked out most of the errors and warnings, but the following error has me 
> st
> umped. Any ideas?

Are you using the latest version from the repositories?
I've fixed something that should be the cause of the first
problem, recently (to be honest, I've not tested it, yet)

> Then this:
> /Library/Python/2.7/site-packages/IMDbPY-5.0-py2.7-macosx-10.11-intel.egg/EGG-I
> NFO/scripts/imdbpy2sql.py:1458: Warning: Column 'movie_id' cannot be null
>   CURS.executemany(self.sqlString, self.converter(self.values()))

That's not nice.
I'll try to download an up-to-date set of plain text data files.

> Then this:
> 2016-01-22 13:26:29,947 CRITICAL [imdbpy] 
> /Library/Python/2.7/site-packages/IMD
> bPY-5.0-py2.7-macosx-10.11-intel.egg/imdb/_exceptions.py:35: IMDbParserError 
> ex
> ception raised; args: ('invalid title: ""',); kwds: {}
> Traceback (most recent call last):
>   File 
> "/Library/Python/2.7/site-packages/IMDbPY-5.0-py2.7-macosx-10.11-intel.e
>   gg/EGG-INFO/scripts/imdbpy2sql.py", line 3059, in 
> import psyco
> ImportError: No module named psyco

This one should be just a warning and not a problem at all.
Have you modified the file somehow?


-- 
Davide Alberani   [PGP KeyID: 0x465BFD47]
http://www.mimante.net/

--
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=267308311&iu=/4140
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] Problems with creating mySQL database

2016-01-17 Thread Davide Alberani
On Thu, Jan 14, 2016 at 10:19 PM, C. Kevin Chen  wrote:
> It appears that I cannot read the .gz files with Python, but I can still see
> their contents by unzipping them. I was able to pip install mysql-python and
> SQL object, do I need to install anything else?

How do you call the imdbpy2sql.py script?
It seems you're missing the -d /directory/with/PlainTextDataFiles/ argument
(not sure which path separator you have to use on OS X, but I guess / is fine).

Hope this helps,

-- 
Davide Alberani   [PGP KeyID: 0x465BFD47]
http://www.mimante.net/

--
Site24x7 APM Insight: Get Deep Visibility into Application Performance
APM + Mobile APM + RUM: Monitor 3 App instances at just $35/Month
Monitor end-to-end web transactions and take corrective actions now
Troubleshoot faster and improve end-user experience. Signup Now!
http://pubads.g.doubleclick.net/gampad/clk?id=267308311&iu=/4140
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] How about copyright infringement when using IMDBPY

2015-11-22 Thread Davide Alberani
Hi,
short answer: don't make any money out of it (not even
in terms of saved money).

The plain text data files are free to use for personal and
non-commercial usage.
For anything else, you need a license (that is quite expensive).

As long as your project respect their terms of service [0] and
instructions about how to link to their page, you will encounter
no problem. :-)

HTH,

+++
[0] 
http://www.imdb.com/help/search?domain=helpdesk_faq&index=1&file=usedatasoftware&ref_=hlp_sr_2
[1] http://www.imdb.com/help/show_leaf?howtolink

On Fri, Nov 20, 2015 at 2:46 PM, Joep Vuurwijk
 wrote:
> Dear mr, mrs,,
>
>
> I would like to start a moviesite/blog (in dutch language) and therefore
> would like to use the monthly database dump from your site. I hope that you
> would be so kind to help me out with a issue I am encountering.
>
>
> I would like to use the data from your IMDBPY (such as movie posters, movie
> ratings, in which movies does an actor play, etc) but am afraid though about
> copyright infringement! What if I make use of IMDBPY and in a few years I
> start making some money out of my site (google Ads etc)?? Is the data
> copyright free or can I get in trouble with IMDB?
>
>
> I hope you can help me on this subject, any sort of information is very
> welcome!
>
>
> Thank you in advance.
>
>
> Kind regards,
>
> Joep Vuurwijk,
>
> the Netherlands
>
>
> --
>
> ___
> Imdbpy-help mailing list
> Imdbpy-help@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/imdbpy-help
>



-- 
Davide Alberani   [PGP KeyID: 0x465BFD47]
http://www.mimante.net/

--
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] HELP IMDbPY

2015-08-23 Thread Davide Alberani
The 'vote details' data set adds these keyword: 'demographic', 'number of
votes', 'arithmetic mean', 'median'.

The one you're looking for is 'number of votes'.

HTH,


On Fri, Jul 3, 2015 at 11:00 AM, 杨远益  wrote:

> There is an example in the README as follows
>
> Example:
>> i = imdb.IMDb(accessSystem='http')
>> m = i.get_movie('0133093') # only default info set are retrieved.
>> m.has_key('demographic') # returns false, since no demographic breakdowns
>> # aren't available by default.
>> i.update(m, info=('vote details',)) # retrieve the vote details info set.
>> print m['demographic'] # print the demographic breakdowns.
>
> But by using this example I only get the information about male female aged 
> under 18 and so on.
>
> [image: 内嵌图片 1]
>
> I want to know can I get the data in the picture below
>
>
>
> [image: 内嵌图片 2]
>
>
>
> ------
>
> ___
> Imdbpy-help mailing list
> Imdbpy-help@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/imdbpy-help
>
>


-- 
Davide Alberani   [PGP KeyID: 0x465BFD47]
http://www.mimante.net/
--
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] How I can get all persons?

2015-08-22 Thread Davide Alberani
Probably your best option is to import the plain text data files
with the imdbpy2sql.py script and then dig the database.

On Fri, Aug 7, 2015 at 6:04 AM, Шилин Максим  wrote:
> Hi,
> And movie list too.
> Thanks.
>
> --
>
> ___
> Imdbpy-help mailing list
> Imdbpy-help@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/imdbpy-help
>



-- 
Davide Alberani   [PGP KeyID: 0x465BFD47]
http://www.mimante.net/

--
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] support for writing credits?

2015-02-15 Thread Davide Alberani
On Mon, Feb 9, 2015 at 9:27 PM, Larry Buchanan  wrote:
>
> I'm wondering about support for writing credits. I've been able to retrieve
> actor/actress information, but I can't seem to retrieve writing credits —
> getting all of the movies/tv shows a given person ID has written for.
>
> any ideas on if/how this would be possible? It's very possible I'm missing
> something incredibly simple and obvious.

Can you provide an example of code that is not working?

I can see the writing credits, here:

>>> import imdb
>>> ia = imdb.IMDb()
>>> tm = ia.get_movie('0133093')
>>> print sorted(tm.keys())
['akas', u'animation department', u'art department', 'art direction',
'aspect ratio', 'assistant director', 'camera and electrical
department', 'canonical title', 'cast', u'casting department',
'casting director', 'certificates', 'cinematographer', 'color info',
u'costume department', 'costume designer', 'countries', 'country
codes', 'cover url', 'director', u'distributors', 'editor',
u'editorial department', 'full-size cover url', 'genres', 'kind',
'language codes', 'languages', 'long imdb canonical title', 'long imdb
title', 'make up', 'miscellaneous companies', 'miscellaneous crew',
'mpaa', u'music department', 'original music', 'plot', 'plot outline',
'producer', u'production companies', 'production design', 'production
manager', 'rating', 'runtimes', 'set decoration', 'smart canonical
title', 'smart long imdb canonical title', 'sound crew', 'sound mix',
'special effects companies', u'special effects department', 'stunt
performer', 'title', 'top 250 rank', u'transportation department',
'visual effects', 'votes', 'writer', 'year']
>>> print tm.get('writer')
[, ]



-- 
Davide Alberani   [PGP KeyID: 0x465BFD47]
http://www.mimante.net/

--
Dive into the World of Parallel Programming. The Go Parallel Website,
sponsored by Intel and developed in partnership with Slashdot Media, is your
hub for all things parallel software development, from weekly thought
leadership blogs to news, videos, case studies, tutorials and more. Take a
look and join the conversation now. http://goparallel.sourceforge.net/
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] SQL vs HTTP access for make a search_movie()

2014-11-21 Thread Davide Alberani
On Thu, Nov 20, 2014 at 1:08 PM, Gustavo Duarte  wrote:
>
> My doubt is, when I make a movie search by title in a another different
> language than English, why the search is more precise if use HTTP access
> than SQL ?

They just have a different set of information.
The plain text data files (used by SQL) is somehow limited; on the
IMDb many more information came from third-party companies
and are licensed in a way that prevents them to be included in
the plain text data files.

In your case, if you open the aka-titles.list file, you will see that
"El gran robo"
is not associated to Flypaper at all (it's, instead, correctly
associated to 7 uomini e un cervello, but that's obviously
another movie).

So, it has no way to know that your El gran robo is in fact
Flypaper.

Plus, even having all the data, I do a limited kind of search on
titles and AKAs:
they are first matched (with/without articles like The, A, An, ...) to
the entries
in the database using a soundex algorithm (to match things that
"sounds similar"),
then the matching subset is compared and sorted using a distance algorithm.
It works quite well, in fact, but on the IMDb site they can use much more
sophysticated algorithms and also meta-information like how many people
are looking for a given title, how much popular a movie is and so on.

So, in your specific case: no way.  In general: it's not that bad, but
I'm obviously
open to receive patches that improve the search. :-)


-- 
Davide Alberani   [PGP KeyID: 0x465BFD47]
http://www.mimante.net/

--
Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server
from Actuate! Instantly Supercharge Your Business Reports and Dashboards
with Interactivity, Sharing, Native Excel Exports, App Integration & more
Get technology previously reserved for billion-dollar corporations, FREE
http://pubads.g.doubleclick.net/gampad/clk?id=157005751&iu=/4140/ostg.clktrk
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] help

2014-09-14 Thread Davide Alberani
On Mon, Aug 11, 2014 at 9:33 PM, imran munir  wrote:
>
> I am looking the way to grab the data from imdb to my website, i am
> developing the website in the asp.net , so how we can bridge to share the
> data between two platforms.

Hi,
probably your best option is to use IMDbPY in the backend, as a CGI
that will serve the data you need in json or something like that.

How to do, depends on the environment you're working in.


Best regards,

-- 
Davide Alberani   [PGP KeyID: 0x465BFD47]
http://www.mimante.net/

--
Want excitement?
Manually upgrade your production database.
When you want reliability, choose Perforce
Perforce version control. Predictably reliable.
http://pubads.g.doubleclick.net/gampad/clk?id=157508191&iu=/4140/ostg.clktrk
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


Re: [Imdbpy-help] New WebApplication based on IMDbPy

2014-09-14 Thread Davide Alberani
On Fri, Aug 29, 2014 at 5:02 AM, Danilo Oliveira
 wrote:

> First of all, I would to like to thank to the developers for this georgius
> tool! Thanks it We could develop the Mapadefilmes.com.br! We are using the
> IMDbPy to extract and mount our title list.

Thanks to you: I've added it to the list of IMDbPY-based projects.

> Hitch-hiking the topic, in order to get the portuguese titles I needed to
> use the HTTP mode instead of the SQL mode connection (what delay the go-live
> day some time =) ), anyone knows why the IMDB dont provides these kind of
> info in the templates files?

That's strage.
Can you provide me an example?

Titles in Portuguese (marked as (Portugal) in aka-titles.list) should be
present.


Thanks for your great work!

-- 
Davide Alberani   [PGP KeyID: 0x465BFD47]
http://www.mimante.net/

--
Want excitement?
Manually upgrade your production database.
When you want reliability, choose Perforce
Perforce version control. Predictably reliable.
http://pubads.g.doubleclick.net/gampad/clk?id=157508191&iu=/4140/ostg.clktrk
___
Imdbpy-help mailing list
Imdbpy-help@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/imdbpy-help


  1   2   3   4   5   >