openai / generating-reviews-discovering-sentiment

Code for "Learning to Generate Reviews and Discovering Sentiment"
https://arxiv.org/abs/1704.01444
MIT License
1.51k stars 379 forks source link

Remove dependency on html? (It won't install on python3) #10

Closed zachmayer closed 7 years ago

zachmayer commented 7 years ago

See similar issue here: https://github.com/j-towns/iprofiler/issues/2

Long story short, the version of the html library on pip is from 2011, and no longer install correctly:

pip3 install html
Collecting html
  Using cached html-1.16.tar.gz
    Complete output from command python setup.py egg_info:
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "/tmp/pip-build-szl57hlm/html/setup.py", line 12, in <module>
        long_description = __doc__.decode('utf8'),
    AttributeError: 'str' object has no attribute 'decode'
Artoria2e5 commented 7 years ago

It seems that Python3.4+ actually comes with a module called html which can do html.unescape(s). Does that one work?

zachmayer commented 7 years ago

It seems to, yes. The pip install failed, but I can import the library and run the example now. Thanks!