Issue 62 in hntool: hntool traceback, program exection fails

3 views
Skip to first unread message

hnt...@googlecode.com

unread,
Nov 2, 2010, 5:01:50 AM11/2/10
to hnt...@googlegroups.com
Status: New
Owner: ----
Labels: Type-Defect Priority-Medium

New issue 62 by mikecockrem: hntool traceback, program exection fails
http://code.google.com/p/hntool/issues/detail?id=62

What steps will reproduce the problem?
1. Install HNTool with 'python2' (with python, fails)
2. Attempt to run tool
3. See below:

What is the expected output? What do you see instead?

Expected output: program runs
Actual output:
[root]# hntool
[ Starting HnTool checks... ]
Traceback (most recent call last):
File "/usr/bin/hntool", line 29, in <module>
hn.run_tests()
File "/usr/lib/python2.7/site-packages/HnTool/core.py", line 221, in
run_tests
'results': self.rule_modules[m].analyze(self.options)})
File "/usr/lib/python2.7/site-packages/HnTool/modules/filesystems.py",
line 57, in analyze
datafile = locate_database[os_type]
UnboundLocalError: local variable 'os_type' referenced before assignment

What version of the product are you using? On what operating system?

hntool-0.1.2
Python 3.1.2
Linux 2.6.35-ARCH #1 SMP PREEMPT x86_64 AMD Opteron(tm) Processor 248

Please provide any additional information below.

Happy to provide any additional information

hnt...@googlecode.com

unread,
Nov 2, 2010, 8:34:50 AM11/2/10
to hnt...@googlegroups.com
Updates:
Status: Accepted
Owner: hugodoria

Comment #1 on issue 62 by hugodoria: hntool traceback, program exection
fails
http://code.google.com/p/hntool/issues/detail?id=62

Hi Mike,

Thanks for your report. :)

Could you tell me how did you installed HnTool?

hnt...@googlecode.com

unread,
Nov 2, 2010, 9:16:11 AM11/2/10
to hnt...@googlegroups.com

Comment #2 on issue 62 by mikecockrem: hntool traceback, program exection
fails
http://code.google.com/p/hntool/issues/detail?id=62

Hi,

Distribution: Arch Linux x64
Installed as such:

1). wget -c http://hntool.googlecode.com/files/hntool-0.1.2.tar.gz
2). tar hntool-0.1.2.tar.gz
3). cd hntool-0.1.2.tar.gz
4). python setup.py install --prefix /usr/ --root /

Produces this error:


Traceback (most recent call last):

File "setup.py", line 3, in <module>
from setuptools import setup
ImportError: No module named setuptools

Attempted to install as such:
1-3). (steps as above)
4). python2 setup.py install --prefix /usr/ --root /

This results in success however when the program is invoked the above error
occurs.
NB: I have installed setuptools via pacman which
installs: "python2-distribute provides setuptools"

Regards,

Mike.


hnt...@googlecode.com

unread,
Nov 4, 2010, 11:20:48 AM11/4/10
to hnt...@googlegroups.com

Comment #3 on issue 62 by mikecockrem: hntool traceback, program exection
fails
http://code.google.com/p/hntool/issues/detail?id=62

Quick update, Did a full update including python and also tested this on
another machine: same problem. Reproducible from my end. Cheers.

hnt...@googlecode.com

unread,
Nov 28, 2010, 11:27:43 PM11/28/10
to hnt...@googlegroups.com

Comment #4 on issue 62 by linux.rafa: hntool traceback, program exection
fails
http://code.google.com/p/hntool/issues/detail?id=62

Can you please tell me if you have that files:

/var/lib/mlocate/mlocate.db

and

/usr/bin/updatedb

???

hnt...@googlecode.com

unread,
Nov 29, 2010, 1:35:04 AM11/29/10
to hnt...@googlegroups.com

Comment #5 on issue 62 by mikecockrem: hntool traceback, program exection
fails
http://code.google.com/p/hntool/issues/detail?id=62

Hi,

We don't use mlocate due to data isolation/security requirements at this
site.
Wasn't aware it was a dep.

Regards,

Mike.

hnt...@googlecode.com

unread,
Nov 29, 2010, 7:03:53 AM11/29/10
to hnt...@googlegroups.com

Comment #6 on issue 62 by linux.rafa: hntool traceback, program exection
fails
http://code.google.com/p/hntool/issues/detail?id=62

It should not be a dep.

Hugo,

Can you please take a look that?

hnt...@googlecode.com

unread,
Dec 1, 2010, 6:14:19 PM12/1/10
to hnt...@googlegroups.com

Comment #7 on issue 62 by linux.rafa: hntool traceback, program exection
fails
http://code.google.com/p/hntool/issues/detail?id=62

An collaborator who does not want to sign up with google send me that
patch. Please apply that patch and let me know if solve your problem.

Attachments:
fix-issue-62.patch 1.4 KB

hnt...@googlecode.com

unread,
Dec 2, 2010, 3:44:06 AM12/2/10
to hnt...@googlegroups.com

Comment #8 on issue 62 by mikecockrem: hntool traceback, program exection
fails
http://code.google.com/p/hntool/issues/detail?id=62

1). Installed: "python2 setup.py install --prefix /usr/ --root /"
2). Edited line 37 in patch to read "find" not "found" (No big deal :)
3). Applied patch:
"patch /usr/lib/python2.7/site-packages/HnTool/modules/filesystems.py \
< /hgchangeset.patch"
4). Successfully executed hntool at the cli

This resolves my issue, thanks.
Suggest you merge this.

Kind regards,

Mike.

hnt...@googlecode.com

unread,
Dec 2, 2010, 3:53:09 AM12/2/10
to hnt...@googlegroups.com

Comment #9 on issue 62 by mikecockrem: hntool traceback, program exection
fails
http://code.google.com/p/hntool/issues/detail?id=62

1). Installed: "python2 setup.py install --prefix /usr/ --root /"

2). Edited line 37 for grammer (No big deal at all, cosmetic :)


3). Applied patch:
"patch /usr/lib/python2.7/site-packages/HnTool/modules/filesystems.py \

< /home/mike/fix-issue-62-b.patch.patch"


4). Successfully executed hntool at the cli

This resolves my issue, thanks.
Suggest you merge this.

Great project guys, please feel free to
rely on me for any testing you need in future.

Kind regards,

Mike.


Attachments:
fix-issue-62-b.patch 1.5 KB

hnt...@googlecode.com

unread,
Dec 7, 2010, 6:58:36 PM12/7/10
to hnt...@googlegroups.com
Updates:
Owner: linux.rafa

Comment #10 on issue 62 by linux.rafa: hntool traceback, program exection
fails
http://code.google.com/p/hntool/issues/detail?id=62

The patch did push. Issue 62 closed.

hnt...@googlecode.com

unread,
Dec 7, 2010, 7:40:56 PM12/7/10
to hnt...@googlegroups.com
Updates:
Status: Fixed

Comment #11 on issue 62 by linux.rafa: hntool traceback, program exection
fails
http://code.google.com/p/hntool/issues/detail?id=62

(No comment was entered for this change.)

Reply all
Reply to author
Forward
0 new messages