loghetti SyntaxError: invalid syntax

2 views
Skip to first unread message

vikrant

unread,
Apr 9, 2008, 9:26:44 AM4/9/08
to loghetti-dev
I just downloaded and installed loghetti on my rhel 4 x86_64 machine,
when i try to run it it gives the below error:

loghetti.py --ip=125.24.59.75
File "/usr/local/bin/loghetti.py", line 12
class Rule():
^
SyntaxError: invalid syntax


Could someone please guide me.

Regards,
Vikrant

Kent Johnson

unread,
Apr 9, 2008, 9:35:47 AM4/9/08
to loghet...@googlegroups.com
vikrant wrote:
> I just downloaded and installed loghetti on my rhel 4 x86_64 machine,
> when i try to run it it gives the below error:
>
> loghetti.py --ip=125.24.59.75
> File "/usr/local/bin/loghetti.py", line 12
> class Rule():
> ^
> SyntaxError: invalid syntax

It should be
class Rule(object):

It is fixed in SVN.

Kent

vikrant

unread,
Apr 9, 2008, 9:50:52 AM4/9/08
to loghetti-dev
I now get the following error :(

loghetti.py --code=Mozilla /var/log/httpd/access_log
File "/usr/local/bin/loghetti.py", line 29
class Filter():
^
SyntaxError: invalid syntax
Message has been deleted

Kent Johnson

unread,
Apr 9, 2008, 9:59:42 AM4/9/08
to loghet...@googlegroups.com
Perhaps you could figure this one out? What does this error have in
common with the previous one?

Kent

vikrant

unread,
Apr 9, 2008, 10:04:48 AM4/9/08
to loghetti-dev
I don't have an idea abt python scripts but looks like its looking for
a definition for Filter() , im pretty clueless :(

Kent Johnson

unread,
Apr 9, 2008, 10:13:59 AM4/9/08
to loghet...@googlegroups.com
vikrant wrote:
> I don't have an idea abt python scripts but looks like its looking for
> a definition for Filter() , im pretty clueless :(

Oh come on, you have two virtually identical error messages and a fix
for one of them.

Brian Jones

unread,
Apr 9, 2008, 10:14:14 AM4/9/08
to loghet...@googlegroups.com
for each line that starts with "class", make sure that, in the
parentheses on that line, the word "object" appears.

...or just check out the svn version. It's really not that hard to do,
and it's worth it.

--
Brian K. Jones
Python Magazine http://www.pythonmagazine.com
My Blog http://www.protocolostomy.com

vikrant

unread,
Apr 9, 2008, 10:27:56 AM4/9/08
to loghetti-dev
OK fixed that now i get another error:

[ro...@s5-web-74.54.82.25 CommandLineApp-2.6]# loghetti.py --
code=Mozilla /var/log/httpd/access_log
Traceback (most recent call last):
File "/usr/local/bin/loghetti.py", line 5, in ?
import CommandLineApp
ImportError: No module named CommandLineApp

Brian Jones

unread,
Apr 9, 2008, 10:31:37 AM4/9/08
to loghet...@googlegroups.com
Ok, well this is just about reading the documentation. Loghetti
requires commandlineapp. Go download it and put the file in the same
directory as loghetti.

If you have further issues, please peruse the docs before posting.

--
Brian K. Jones

vikrant

unread,
Apr 9, 2008, 11:28:11 AM4/9/08
to loghetti-dev
done. the command runs without any errors now but does not display any
output, is there any kind of logging that happens which i can refer
to, to troubleshoot.


On Apr 9, 7:31 pm, "Brian Jones" <bkjo...@gmail.com> wrote:
> Ok, well this is just about reading the documentation. Loghetti
> requires commandlineapp. Go download it and put the file in the same
> directory as loghetti.
>
> If you have further issues, please peruse the docs before posting.
>
>
>
> On Wed, Apr 9, 2008 at 10:27 AM, vikrant <vix....@gmail.com> wrote:
>
> > OK fixed that now i get another error:
>
> > [r...@s5-web-74.54.82.25 CommandLineApp-2.6]# loghetti.py --

Brian Jones

unread,
Apr 9, 2008, 11:36:39 AM4/9/08
to loghet...@googlegroups.com
No, there is no logging.

--
Brian K. Jones

Reply all
Reply to author
Forward
0 new messages