ejwa / gitinspector

:bar_chart: The statistical analysis tool for git repositories
GNU General Public License v3.0
2.36k stars 327 forks source link

ImportError after install on Ubuntu 16.04 #121

Closed davidjcastner closed 8 years ago

davidjcastner commented 8 years ago
$ sudo apt install gitinspector -y -f
Reading package lists... Done
Building dependency tree       
Reading state information... Done
The following additional packages will be installed:
  libjs-excanvas libjs-jquery-flot libjs-jquery-metadata
  libjs-jquery-tablesorter
Suggested packages:
  libjs-jquery-flot-docs
The following NEW packages will be installed:
  gitinspector libjs-excanvas libjs-jquery-flot libjs-jquery-metadata
  libjs-jquery-tablesorter
0 upgraded, 5 newly installed, 0 to remove and 0 not upgraded.
Need to get 273 kB of archives.
After this operation, 1,443 kB of additional disk space will be used.
Get:1 http://us.archive.ubuntu.com/ubuntu xenial/universe amd64 libjs-jquery-flot all 0.8.3+dfsg-1 [115 kB]
Get:2 http://us.archive.ubuntu.com/ubuntu xenial/universe amd64 libjs-jquery-metadata all 10-2ubuntu2 [6,856 B]
Get:3 http://us.archive.ubuntu.com/ubuntu xenial/universe amd64 libjs-jquery-tablesorter all 10-2ubuntu2 [42.0 kB]
Get:4 http://us.archive.ubuntu.com/ubuntu xenial/universe amd64 gitinspector all 0.4.3+dfsg-1 [63.9 kB]
Get:5 http://us.archive.ubuntu.com/ubuntu xenial/universe amd64 libjs-excanvas all 0.r3-4 [45.2 kB]
Fetched 273 kB in 0s (1,319 kB/s)         
Selecting previously unselected package libjs-jquery-flot.
(Reading database ... 218136 files and directories currently installed.)
Preparing to unpack .../libjs-jquery-flot_0.8.3+dfsg-1_all.deb ...
Unpacking libjs-jquery-flot (0.8.3+dfsg-1) ...
Selecting previously unselected package libjs-jquery-metadata.
Preparing to unpack .../libjs-jquery-metadata_10-2ubuntu2_all.deb ...
Unpacking libjs-jquery-metadata (10-2ubuntu2) ...
Selecting previously unselected package libjs-jquery-tablesorter.
Preparing to unpack .../libjs-jquery-tablesorter_10-2ubuntu2_all.deb ...
Unpacking libjs-jquery-tablesorter (10-2ubuntu2) ...
Selecting previously unselected package gitinspector.
Preparing to unpack .../gitinspector_0.4.3+dfsg-1_all.deb ...
Unpacking gitinspector (0.4.3+dfsg-1) ...
Selecting previously unselected package libjs-excanvas.
Preparing to unpack .../libjs-excanvas_0.r3-4_all.deb ...
Unpacking libjs-excanvas (0.r3-4) ...
Processing triggers for doc-base (0.10.7) ...
Processing 1 added doc-base file...
Processing triggers for man-db (2.7.5-1) ...
Setting up libjs-jquery-flot (0.8.3+dfsg-1) ...
Setting up libjs-jquery-metadata (10-2ubuntu2) ...
Setting up libjs-jquery-tablesorter (10-2ubuntu2) ...
Setting up gitinspector (0.4.3+dfsg-1) ...
Setting up libjs-excanvas (0.r3-4) ...
$ gitinspector 
Traceback (most recent call last):
  File "/usr/bin/gitinspector", line 5, in <module>
    from pkg_resources import load_entry_point
ImportError: No module named pkg_resources
adam-waldenberg commented 8 years ago

Hi. Seems to be a dependency issue in the debian package? A missing dependency on setuptools/distribute, perhaps? Or maybe there is an issue with setuptools/distribute in your environment.

See if running "sudo apt-get install python-setuptools" solves your problem.

@ChristianKastner is the official Debian package maintainer, so I'll let him handle the rest of this one.

davidjcastner commented 8 years ago

It was a missing dependency and installing python-setuptools solved the issue

solution:

sudo apt install python-setuptools -y

thanks!

adam-waldenberg commented 8 years ago

Right. However, this should probably be added as a dependency to the package.

davidjcastner commented 8 years ago

whoops sorry about that, thanks for the quick response!

ckastner commented 8 years ago

Hi David, Adam,

I can confirm that the Debian and Ubuntu packages are missing a dependency on python-pkg-resources (which python-setuptools pulled in).

I have just uploaded a fixed version to Debian unstable. Luckily I'm still behind on asking for an Ubuntu sync for #120, so I can cover both with one request.

Thanks for the report! Christian

adam-waldenberg commented 8 years ago

Great! Good work Christian. Closing the issue.

mindplay-dk commented 7 years ago

I ran into this problem after installing today. Manually installing python-setuptools as directed above fixed it. If this dependency can't be installed automatically, perhaps it should be documented?

adam-waldenberg commented 7 years ago

@mindplay-dk This has been fixed already. If you are runing old debian stable or something based of it it's just the dependencies that are wrong in those distributions.