zachwill / rottentomatoes

Rotten Tomatoes API for Python
The Unlicense
88 stars 22 forks source link

`pip install rottentomatoes` not working in python 3.4 #8

Open djds23 opened 9 years ago

djds23 commented 9 years ago

I tried this using 2.7 and everything appeared to be working fine, however in python 3.4 I get this error.

Downloading/unpacking rottentomatoes
  Downloading rottentomatoes-2.1.tar.gz
  Running setup.py (path:/Users/me/.virutalenvs/myapp/build/rottentomatoes/setup.py) egg_info for package rottentomatoes
    Traceback (most recent call last):
      File "<string>", line 17, in <module>
      File "/Users/me/.virutalenvs/myapp/build/rottentomatoes/setup.py", line 8, in <module>
        import rottentomatoes
      File "/Users/me/.virutalenvs/myapp/build/rottentomatoes/rottentomatoes/__init__.py", line 3, in <module>
        from rottentomatoes import RT
    ImportError: cannot import name 'RT'
    Complete output from command python setup.py egg_info:
    Traceback (most recent call last):

  File "<string>", line 17, in <module>

  File "/Users/me/.virutalenvs/myapp/build/rottentomatoes/setup.py", line 8, in <module>

    import rottentomatoes

  File "/Users/me/.virutalenvs/myapp/build/rottentomatoes/rottentomatoes/__init__.py", line 3, in <module>

    from rottentomatoes import RT

ImportError: cannot import name 'RT'

----------------------------------------
Cleaning up...
Command python setup.py egg_info failed with error code 1 in /Users/me/.virutalenvs/myapp/build/rottentomatoes
Storing debug log for failure in /Users/me/.pip/pip.log

any ideas? Thanks for your work on this project.

anton44eg commented 9 years ago

I make pull request for this #9

krestenlaust commented 6 years ago

Just use 2.7 😁

birdmw commented 5 years ago

I just copied the total contents of rottentomatoes.py into init.py and then changed

this:

from urllibimport urlencode

to this:

from urllib.parse import urlencode

in both files. Then the install worked fine.