spyoungtech / grequests

Requests + Gevent = <3
https://pypi.python.org/pypi/grequests
BSD 2-Clause "Simplified" License
4.46k stars 331 forks source link

issue on installation with python 3.4.3 - TypeError: #68

Closed bcohen44 closed 8 years ago

bcohen44 commented 9 years ago

Try to do a pip3 install grequests with python 3.4.3, and am getting the following Traceback

Installing collected packages: gevent, grequests
  Running setup.py install for gevent
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "/private/var/folders/c_/nnqg051j4cb7f1_0jn06s1m00000gn/T/pip-build-r1efkdvz/gevent/setup.py", line 316, in <module>
        run_setup(ext_modules)
      File "/private/var/folders/c_/nnqg051j4cb7f1_0jn06s1m00000gn/T/pip-build-r1efkdvz/gevent/setup.py", line 311, in run_setup
        "Development Status :: 4 - Beta"])
      File "/usr/local/Cellar/python3/3.4.3/Frameworks/Python.framework/Versions/3.4/lib/python3.4/distutils/core.py", line 148, in setup
        dist.run_commands()
      File "/usr/local/Cellar/python3/3.4.3/Frameworks/Python.framework/Versions/3.4/lib/python3.4/distutils/dist.py", line 955, in run_commands
        self.run_command(cmd)
      File "/usr/local/Cellar/python3/3.4.3/Frameworks/Python.framework/Versions/3.4/lib/python3.4/distutils/dist.py", line 974, in run_command
        cmd_obj.run()
      File "/usr/local/lib/python3.4/site-packages/setuptools-12.2-py3.4.egg/setuptools/command/install.py", line 61, in run
      File "/usr/local/Cellar/python3/3.4.3/Frameworks/Python.framework/Versions/3.4/lib/python3.4/distutils/command/install.py", line 539, in run
        self.run_command('build')
      File "/usr/local/Cellar/python3/3.4.3/Frameworks/Python.framework/Versions/3.4/lib/python3.4/distutils/cmd.py", line 313, in run_command
        self.distribution.run_command(command)
      File "/usr/local/Cellar/python3/3.4.3/Frameworks/Python.framework/Versions/3.4/lib/python3.4/distutils/dist.py", line 974, in run_command
        cmd_obj.run()
      File "/usr/local/Cellar/python3/3.4.3/Frameworks/Python.framework/Versions/3.4/lib/python3.4/distutils/command/build.py", line 126, in run
        self.run_command(cmd_name)
      File "/usr/local/Cellar/python3/3.4.3/Frameworks/Python.framework/Versions/3.4/lib/python3.4/distutils/cmd.py", line 313, in run_command
        self.distribution.run_command(command)
      File "/usr/local/Cellar/python3/3.4.3/Frameworks/Python.framework/Versions/3.4/lib/python3.4/distutils/dist.py", line 974, in run_command
        cmd_obj.run()
      File "/usr/local/Cellar/python3/3.4.3/Frameworks/Python.framework/Versions/3.4/lib/python3.4/distutils/command/build_ext.py", line 339, in run
        self.build_extensions()
      File "/usr/local/Cellar/python3/3.4.3/Frameworks/Python.framework/Versions/3.4/lib/python3.4/distutils/command/build_ext.py", line 448, in build_extensions
        self.build_extension(ext)
      File "/private/var/folders/c_/nnqg051j4cb7f1_0jn06s1m00000gn/T/pip-build-r1efkdvz/gevent/setup.py", line 234, in build_extension
        self.gevent_prepare(ext)
      File "/private/var/folders/c_/nnqg051j4cb7f1_0jn06s1m00000gn/T/pip-build-r1efkdvz/gevent/setup.py", line 231, in gevent_prepare
        configure(self, ext)
      File "/private/var/folders/c_/nnqg051j4cb7f1_0jn06s1m00000gn/T/pip-build-r1efkdvz/gevent/setup.py", line 139, in configure_libev
        make_universal_header('config.h', 'SIZEOF_LONG', 'SIZEOF_SIZE_T', 'SIZEOF_TIME_T')
      File "/private/var/folders/c_/nnqg051j4cb7f1_0jn06s1m00000gn/T/pip-build-r1efkdvz/gevent/setup.py", line 111, in make_universal_header
        print >>f, line
    TypeError: unsupported operand type(s) for >>: 'builtin_function_or_method' and '_io.TextIOWrapper'
    Running '/bin/sh /private/var/folders/c_/nnqg051j4cb7f1_0jn06s1m00000gn/T/pip-build-r1efkdvz/gevent/libev/configure > configure-output.txt' in /private/var/folders/c_/nnqg051j4cb7f1_0jn06s1m00000gn/T/pip-build-r1efkdvz/gevent/build/temp.macosx-10.10-x86_64-3.4/libev
    Complete output from command /usr/local/opt/python3/bin/python3.4 -c "import setuptools, tokenize;__file__='/private/var/folders/c_/nnqg051j4cb7f1_0jn06s1m00000gn/T/pip-build-r1efkdvz/gevent/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /var/folders/c_/nnqg051j4cb7f1_0jn06s1m00000gn/T/pip-2a9m9jp5-record/install-record.txt --single-version-externally-managed --compile:
    running install

    running build

    running build_py

    creating build

    creating build/lib.macosx-10.10-x86_64-3.4

    creating build/lib.macosx-10.10-x86_64-3.4/gevent

    copying gevent/__init__.py -> build/lib.macosx-10.10-x86_64-3.4/gevent

    copying gevent/_threading.py -> build/lib.macosx-10.10-x86_64-3.4/gevent

    copying gevent/backdoor.py -> build/lib.macosx-10.10-x86_64-3.4/gevent

    copying gevent/baseserver.py -> build/lib.macosx-10.10-x86_64-3.4/gevent

    copying gevent/coros.py -> build/lib.macosx-10.10-x86_64-3.4/gevent

    copying gevent/event.py -> build/lib.macosx-10.10-x86_64-3.4/gevent

    copying gevent/fileobject.py -> build/lib.macosx-10.10-x86_64-3.4/gevent

    copying gevent/greenlet.py -> build/lib.macosx-10.10-x86_64-3.4/gevent

    copying gevent/hub.py -> build/lib.macosx-10.10-x86_64-3.4/gevent

    copying gevent/local.py -> build/lib.macosx-10.10-x86_64-3.4/gevent

    copying gevent/lock.py -> build/lib.macosx-10.10-x86_64-3.4/gevent

    copying gevent/monkey.py -> build/lib.macosx-10.10-x86_64-3.4/gevent

    copying gevent/os.py -> build/lib.macosx-10.10-x86_64-3.4/gevent

    copying gevent/pool.py -> build/lib.macosx-10.10-x86_64-3.4/gevent

    copying gevent/pywsgi.py -> build/lib.macosx-10.10-x86_64-3.4/gevent

    copying gevent/queue.py -> build/lib.macosx-10.10-x86_64-3.4/gevent

    copying gevent/resolver_ares.py -> build/lib.macosx-10.10-x86_64-3.4/gevent

    copying gevent/resolver_thread.py -> build/lib.macosx-10.10-x86_64-3.4/gevent

    copying gevent/select.py -> build/lib.macosx-10.10-x86_64-3.4/gevent

    copying gevent/server.py -> build/lib.macosx-10.10-x86_64-3.4/gevent

    copying gevent/socket.py -> build/lib.macosx-10.10-x86_64-3.4/gevent

    copying gevent/ssl.py -> build/lib.macosx-10.10-x86_64-3.4/gevent

    copying gevent/subprocess.py -> build/lib.macosx-10.10-x86_64-3.4/gevent

    copying gevent/thread.py -> build/lib.macosx-10.10-x86_64-3.4/gevent

    copying gevent/threading.py -> build/lib.macosx-10.10-x86_64-3.4/gevent

    copying gevent/threadpool.py -> build/lib.macosx-10.10-x86_64-3.4/gevent

    copying gevent/timeout.py -> build/lib.macosx-10.10-x86_64-3.4/gevent

    copying gevent/util.py -> build/lib.macosx-10.10-x86_64-3.4/gevent

    copying gevent/win32util.py -> build/lib.macosx-10.10-x86_64-3.4/gevent

    copying gevent/wsgi.py -> build/lib.macosx-10.10-x86_64-3.4/gevent

    running build_ext

    Traceback (most recent call last):

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

      File "/private/var/folders/c_/nnqg051j4cb7f1_0jn06s1m00000gn/T/pip-build-r1efkdvz/gevent/setup.py", line 316, in <module>

        run_setup(ext_modules)

      File "/private/var/folders/c_/nnqg051j4cb7f1_0jn06s1m00000gn/T/pip-build-r1efkdvz/gevent/setup.py", line 311, in run_setup

        "Development Status :: 4 - Beta"])

      File "/usr/local/Cellar/python3/3.4.3/Frameworks/Python.framework/Versions/3.4/lib/python3.4/distutils/core.py", line 148, in setup

        dist.run_commands()

      File "/usr/local/Cellar/python3/3.4.3/Frameworks/Python.framework/Versions/3.4/lib/python3.4/distutils/dist.py", line 955, in run_commands

        self.run_command(cmd)

      File "/usr/local/Cellar/python3/3.4.3/Frameworks/Python.framework/Versions/3.4/lib/python3.4/distutils/dist.py", line 974, in run_command

        cmd_obj.run()

      File "/usr/local/lib/python3.4/site-packages/setuptools-12.2-py3.4.egg/setuptools/command/install.py", line 61, in run

      File "/usr/local/Cellar/python3/3.4.3/Frameworks/Python.framework/Versions/3.4/lib/python3.4/distutils/command/install.py", line 539, in run

        self.run_command('build')

      File "/usr/local/Cellar/python3/3.4.3/Frameworks/Python.framework/Versions/3.4/lib/python3.4/distutils/cmd.py", line 313, in run_command

        self.distribution.run_command(command)

      File "/usr/local/Cellar/python3/3.4.3/Frameworks/Python.framework/Versions/3.4/lib/python3.4/distutils/dist.py", line 974, in run_command

        cmd_obj.run()

      File "/usr/local/Cellar/python3/3.4.3/Frameworks/Python.framework/Versions/3.4/lib/python3.4/distutils/command/build.py", line 126, in run

        self.run_command(cmd_name)

      File "/usr/local/Cellar/python3/3.4.3/Frameworks/Python.framework/Versions/3.4/lib/python3.4/distutils/cmd.py", line 313, in run_command

        self.distribution.run_command(command)

      File "/usr/local/Cellar/python3/3.4.3/Frameworks/Python.framework/Versions/3.4/lib/python3.4/distutils/dist.py", line 974, in run_command

        cmd_obj.run()

      File "/usr/local/Cellar/python3/3.4.3/Frameworks/Python.framework/Versions/3.4/lib/python3.4/distutils/command/build_ext.py", line 339, in run

        self.build_extensions()

      File "/usr/local/Cellar/python3/3.4.3/Frameworks/Python.framework/Versions/3.4/lib/python3.4/distutils/command/build_ext.py", line 448, in build_extensions

        self.build_extension(ext)

      File "/private/var/folders/c_/nnqg051j4cb7f1_0jn06s1m00000gn/T/pip-build-r1efkdvz/gevent/setup.py", line 234, in build_extension

        self.gevent_prepare(ext)

      File "/private/var/folders/c_/nnqg051j4cb7f1_0jn06s1m00000gn/T/pip-build-r1efkdvz/gevent/setup.py", line 231, in gevent_prepare

        configure(self, ext)

      File "/private/var/folders/c_/nnqg051j4cb7f1_0jn06s1m00000gn/T/pip-build-r1efkdvz/gevent/setup.py", line 139, in configure_libev

        make_universal_header('config.h', 'SIZEOF_LONG', 'SIZEOF_SIZE_T', 'SIZEOF_TIME_T')

      File "/private/var/folders/c_/nnqg051j4cb7f1_0jn06s1m00000gn/T/pip-build-r1efkdvz/gevent/setup.py", line 111, in make_universal_header

        print >>f, line

    TypeError: unsupported operand type(s) for >>: 'builtin_function_or_method' and '_io.TextIOWrapper'

    Running '/bin/sh /private/var/folders/c_/nnqg051j4cb7f1_0jn06s1m00000gn/T/pip-build-r1efkdvz/gevent/libev/configure > configure-output.txt' in /private/var/folders/c_/nnqg051j4cb7f1_0jn06s1m00000gn/T/pip-build-r1efkdvz/gevent/build/temp.macosx-10.10-x86_64-3.4/libev

    ----------------------------------------
    Command "/usr/local/opt/python3/bin/python3.4 -c "import setuptools, tokenize;__file__='/private/var/folders/c_/nnqg051j4cb7f1_0jn06s1m00000gn/T/pip-build-r1efkdvz/gevent/setup.py';exec(compile(getattr(tokenize, 'open', open)(__file__).read().replace('\r\n', '\n'), __file__, 'exec'))" install --record /var/folders/c_/nnqg051j4cb7f1_0jn06s1m00000gn/T/pip-2a9m9jp5-record/install-record.txt --single-version-externally-managed --compile" failed with error code 1 in /private/var/folders/c_/nnqg051j4cb7f1_0jn06s1m00000gn/T/pip-build-r1efkdvz/gevent
ghinch commented 9 years ago

It's because of https://github.com/gevent/gevent/issues/38