Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Not able to install #861

Open
DavidGOrtega opened this issue Jun 3, 2018 · 10 comments
Open

Not able to install #861

DavidGOrtega opened this issue Jun 3, 2018 · 10 comments

Comments

@DavidGOrtega
Copy link

DavidGOrtega commented Jun 3, 2018

Hi!

I have installed python 3.6 with pip 10.0.1 as required however I can't complete the installation through

python3 setup.py install

I have this output

  File "/usr/lib/python3.6/distutils/core.py", line 148, in setup
    dist.run_commands()
  File "/usr/lib/python3.6/distutils/dist.py", line 955, in run_commands
    self.run_command(cmd)
  File "/usr/lib/python3.6/distutils/dist.py", line 974, in run_command
    cmd_obj.run()
  File "/usr/lib/python3/dist-packages/setuptools/command/install.py", line 67, in run
    self.do_egg_install()
  File "/usr/lib/python3/dist-packages/setuptools/command/install.py", line 109, in do_egg_install
    self.run_command('bdist_egg')
  File "/usr/lib/python3.6/distutils/cmd.py", line 313, in run_command
    self.distribution.run_command(command)
  File "/usr/lib/python3.6/distutils/dist.py", line 974, in run_command
    cmd_obj.run()
  File "/usr/lib/python3/dist-packages/setuptools/command/bdist_egg.py", line 152, in run
    self.run_command("egg_info")
  File "/usr/lib/python3.6/distutils/cmd.py", line 313, in run_command
    self.distribution.run_command(command)
  File "/usr/lib/python3.6/distutils/dist.py", line 974, in run_command
    cmd_obj.run()
  File "/usr/lib/python3/dist-packages/setuptools/command/egg_info.py", line 186, in run
    self.find_sources()
  File "/usr/lib/python3/dist-packages/setuptools/command/egg_info.py", line 209, in find_sources
    mm.run()
  File "/usr/lib/python3/dist-packages/setuptools/command/egg_info.py", line 293, in run
    self.add_defaults()
  File "/usr/lib/python3/dist-packages/setuptools/command/egg_info.py", line 322, in add_defaults
    sdist.add_defaults(self)
  File "/usr/lib/python3/dist-packages/setuptools/command/sdist.py", line 127, in add_defaults
    for _, src_dir, _, filenames in build_py.data_files:
  File "/usr/lib/python3/dist-packages/setuptools/command/build_py.py", line 65, in __getattr__
    self.data_files = self._get_data_files()
  File "/usr/lib/python3/dist-packages/setuptools/command/build_py.py", line 79, in _get_data_files
    return list(map(self._get_pkg_data_files, self.packages or ()))
  File "/usr/lib/python3/dist-packages/setuptools/command/build_py.py", line 91, in _get_pkg_data_files
    for file in self.find_data_files(package, src_dir)
  File "/usr/lib/python3/dist-packages/setuptools/command/build_py.py", line 98, in find_data_files
    + self.package_data.get(package, []))
TypeError: must be str, not list

My OS is Ubuntu 16.04.4 LTS

@milhidaka
Copy link
Member

Sorry, I cannot reproduce it.

Python 3.6.3 (using pyenv), Ubuntu 14.04, setuptools 28.8.0, pip 10.0.1.

Python part of WebDNN can also be installed from pypi. Please try pip install webdnn.

@DavidGOrtega
Copy link
Author

Hi, thanks for the reply, I tried with pip

    writing pip-egg-info/webdnn.egg-info/PKG-INFO
    writing dependency_links to pip-egg-info/webdnn.egg-info/dependency_links.txt
    writing requirements to pip-egg-info/webdnn.egg-info/requires.txt
    writing top-level names to pip-egg-info/webdnn.egg-info/top_level.txt
    writing manifest file 'pip-egg-info/webdnn.egg-info/SOURCES.txt'
    /usr/lib/python3.6/distutils/dist.py:261: UserWarning: Unknown distribution option: 'python_requires'
      warnings.warn(msg)
    warning: manifest_maker: standard file '-c' not found

    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "/tmp/pip-install-wve8iquv/webdnn/setup.py", line 30, in <module>
        "Programming Language :: Python :: 3.6"
      File "/usr/lib/python3.6/distutils/core.py", line 148, in setup
        dist.run_commands()
      File "/usr/lib/python3.6/distutils/dist.py", line 955, in run_commands
        self.run_command(cmd)
      File "/usr/lib/python3.6/distutils/dist.py", line 974, in run_command
        cmd_obj.run()
      File "/usr/lib/python3/dist-packages/setuptools/command/egg_info.py", line 186, in run
        self.find_sources()
      File "/usr/lib/python3/dist-packages/setuptools/command/egg_info.py", line 209, in find_sources
        mm.run()
      File "/usr/lib/python3/dist-packages/setuptools/command/egg_info.py", line 293, in run
        self.add_defaults()
      File "/usr/lib/python3/dist-packages/setuptools/command/egg_info.py", line 322, in add_defaults
        sdist.add_defaults(self)
      File "/usr/lib/python3/dist-packages/setuptools/command/sdist.py", line 127, in add_defaults
        for _, src_dir, _, filenames in build_py.data_files:
      File "/usr/lib/python3/dist-packages/setuptools/command/build_py.py", line 65, in __getattr__
        self.data_files = self._get_data_files()
      File "/usr/lib/python3/dist-packages/setuptools/command/build_py.py", line 79, in _get_data_files
        return list(map(self._get_pkg_data_files, self.packages or ()))
      File "/usr/lib/python3/dist-packages/setuptools/command/build_py.py", line 91, in _get_pkg_data_files
        for file in self.find_data_files(package, src_dir)
      File "/usr/lib/python3/dist-packages/setuptools/command/build_py.py", line 98, in find_data_files
        + self.package_data.get(package, []))
    TypeError: must be str, not list

@milhidaka
Copy link
Member

The code which caused exception seems to be different in latest version.
https://github.com/pypa/setuptools/blob/master/setuptools/command/build_py.py#L111
Please try update setuptools to the latest one.

@DavidGOrtega
Copy link
Author

DavidGOrtega commented Jun 3, 2018

Well, the only thing I know that all the problems comes with python 3.6.
Can you please explain me your python 3.6 installation procedure?

this does not work

sudo add-apt-repository ppa:deadsnakes/ppa
sudo apt-get update
sudo apt-get install python3.6

sudo apt-get install python3-pip

I have this error later on

Traceback (most recent call last):
  File "/usr/lib/python3.6/runpy.py", line 183, in _run_module_as_main
    mod_name, mod_spec, code = _get_module_details(mod_name, _Error)
  File "/usr/lib/python3.6/runpy.py", line 142, in _get_module_details
    return _get_module_details(pkg_main_name, error)
  File "/usr/lib/python3.6/runpy.py", line 109, in _get_module_details
    __import__(pkg_name)
  File "/usr/lib/python3/dist-packages/pip/__init__.py", line 59, in <module>
    from pip.log import logger
  File "/usr/lib/python3/dist-packages/pip/log.py", line 9, in <module>
    import colorama, pkg_resources
  File "<frozen importlib._bootstrap>", line 971, in _find_and_load
  File "<frozen importlib._bootstrap>", line 955, in _find_and_load_unlocked
  File "<frozen importlib._bootstrap>", line 656, in _load_unlocked
  File "<frozen importlib._bootstrap>", line 626, in _load_backward_compatible
  File "/usr/share/python-wheels/setuptools-3.3-py2.py3-none-any.whl/pkg_resources.py", line 1479, in <module>
    register_loader_type(importlib_bootstrap.SourceFileLoader, DefaultProvider)
AttributeError: module 'importlib._bootstrap' has no attribute 'SourceFileLoader'

With every single pip3 command, later on when I see this post
pypa/virtualenv#1059

trying to solve the issue I read that I have to use this kind of dark voodoo

export LC_ALL="en_US.UTF-8"
export LC_CTYPE="en_US.UTF-8"
sudo dpkg-reconfigure locales

is where I surrender. I NEVER follow voodoo like that...

So again, could you give me how to install 3.6 in Ubuntu?

Thanks

@milhidaka
Copy link
Member

I'm using pyenv, with which user can install multiple version of python without root permission.
https://github.com/pyenv/pyenv

I cannot test just now, but will keep in mind that webdnn may be incompatible with python installed by Ubuntu packaging system.

@DavidGOrtega
Copy link
Author

I have installed it... has been very hard. Right now I just only want to go the the bed and cry... 😭

Later on I will try to sort out the amount of desired work to make it and I will post it here. I will try also pyenv to see the magic...

@ghost
Copy link

ghost commented Aug 16, 2018

Hi, I have also met the same problem. Can you pls post your solution here?

@nehz
Copy link

nehz commented Oct 23, 2018

pip3.6 install webdnn on Ubuntu 16.04 also has same issue

@milhidaka
Copy link
Member

I clean installed ubuntu 16.04, then installed python following official document.

$ sudo add-apt-repository ppa:jonathonf/python-3.6
$ sudo apt-get update
$ sudo apt-get install python3.6 python3.6-dev
$ wget https://bootstrap.pypa.io/get-pip.py
$ sudo python3.6 get-pip.py

(from https://www.python.jp/install/ubuntu/index.html (Japanese page))

In this environment, sudo pip install webdnn ran without error.

@DavidGOrtega
Copy link
Author

Hi, sorry to respond so late, I can't say what I did since I forgot it. However many moths has passed and python 3.6 is now adopted.

sudo apt-get update
sudo apt-get install python3.6

Pip is not necessary since python comes with pip since 3.4

python3.6 -m pip 

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants