Re: PyChecker under python's virtualenv

2010-02-04 Thread Diez B. Roggisch
Am 04.02.10 01:52, schrieb Steve Holden: Diez B. Roggisch wrote: Am 03.02.10 22:46, schrieb soltys: Hi Everybody, I've been doing some test on pythons' virtualenv and recently I've decided to run PyChecker. But I'm having some difficulties with importing modules available only on virtualenv by

Re: PyChecker under python's virtualenv

2010-02-03 Thread Steve Holden
Diez B. Roggisch wrote: > Am 03.02.10 22:46, schrieb soltys: >> Hi Everybody, >> I've been doing some test on pythons' virtualenv and recently I've >> decided to run PyChecker. But I'm having some difficulties with importing >> modules available only on virtualenv by pychecker. As if it was >> tryi

Re: PyChecker under python's virtualenv

2010-02-03 Thread Diez B. Roggisch
Am 03.02.10 22:46, schrieb soltys: Hi Everybody, I've been doing some test on pythons' virtualenv and recently I've decided to run PyChecker. But I'm having some difficulties with importing modules available only on virtualenv by pychecker. As if it was trying to use systemwide python. I've googl

Re: Pychecker

2006-06-09 Thread Anthony Greene
On Fri, 09 Jun 2006 11:46:59 -0700, Matt Good wrote: > Anthony Greene wrote: >> Howdy, I had the impression that pychecker caught and reported such >> dynamic syntactical errors. >> >> #!/usr/bin/env python >> >> >> def add(i): >> i += 10 >> >> status = 3 >> >> if 1 == 1: >> statuss = 15 >

Re: Pychecker

2006-06-09 Thread skip
Rick> I think you're asking a lot from pychecker. Rick> kop = 1 Rick> koi = 2 Rick> if True: Rick> koo = 3 Rick> What would you like pychecker to report? I thing the OP was hoping for a "not used" error, but it can only reasonably do that within a function, which

Re: Pychecker

2006-06-09 Thread Matt Good
Anthony Greene wrote: > Howdy, I had the impression that pychecker caught and reported such > dynamic syntactical errors. > > #!/usr/bin/env python > > > def add(i): > i += 10 > > status = 3 > > if 1 == 1: > statuss = 15 > > add(status) > > === > > exalted sysfault$ pych

Re: Pychecker

2006-06-09 Thread Rick Zantow
Anthony Greene <[EMAIL PROTECTED]> wrote in news:[EMAIL PROTECTED]: > Howdy, I had the impression that pychecker caught and reported such > dynamic syntactical errors. > > #!/usr/bin/env python > > > def add(i): > i += 10 > > status = 3 > > if 1 == 1: > statuss = 15 > > add(stat

Re: Pychecker Re: Nested List Question

2005-11-02 Thread Mike Meyer
Roman Suzi <[EMAIL PROTECTED]> writes: > On Thu, 3 Nov 2005, Chris McCoy wrote: >>> gridSystemId = [[None]*columns]*rows >> You've made gridSystemID a list of `rows` references to the SAME "inner" >> list, so the behavior you observe is the only possible one. >> If you want copies instead, ASK for

Re: Pychecker Re: Nested List Question

2005-11-02 Thread Chris McCoy
It may, but I haven't been using Pychecker yet. I'm still fairly new to Python. Thanks, Chris M. "Roman Suzi" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > On Thu, 3 Nov 2005, Chris McCoy wrote: > >> Thank you! I've been banging my head against the wall! >> >> Chris M. > >>> g

Re: PyChecker lives, version 0.8.15 released

2005-09-03 Thread Al Christians
Neal Norwitz wrote: > Special thanks to Ken Pronovici. He did a lot of work for this > release and helped ensure it occurred. > > Version 0.8.15 of PyChecker is available. It's been over a year since > the last release. Wow, time really does fly. Since it's been so long > I'm sure I screwed so

Re: PyChecker messages

2005-01-17 Thread Cameron Laird
In article <[EMAIL PROTECTED]>, Ben Sizer <[EMAIL PROTECTED]> wrote: >But you could use a dict of return values, or even just assigning a >different return value in each if clause. The end result is that you >have a single well-defined exit point from the function, which is >generally considered to

Re: pychecker - sets.Set need to be overridden

2005-01-17 Thread Istvan Albert
Peter Otten wrote: The Set class has implementations for __cmp__() and __hash__() that unconditionally raise an exception. pychecker assumes that these methods are "abstract", i. e. meant to be overriden by a subclass, and warns that you are instantiating an abstract base class, while the intention

Re: PyChecker messages

2005-01-17 Thread John Roth
"Ben Sizer" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] But you could use a dict of return values, or even just assigning a different return value in each if clause. The end result is that you have a single well-defined exit point from the function, which is generally considered to

Re: PyChecker messages

2005-01-17 Thread Ben Sizer
But you could use a dict of return values, or even just assigning a different return value in each if clause. The end result is that you have a single well-defined exit point from the function, which is generally considered to be preferable. -- http://mail.python.org/mailman/listinfo/python-list

Re: pychecker - sets.Set need to be overridden

2005-01-17 Thread [EMAIL PROTECTED]
I don't know pychecker, maybe there's something wrong with it as your code seems valid to me. -- http://mail.python.org/mailman/listinfo/python-list

Re: pychecker - sets.Set need to be overridden

2005-01-17 Thread Peter Otten
Istvan Albert wrote: > if I have this code: > > import sets > > class Foo: > x = sets.Set() > > then pychecker says: > > test.py:4: Methods (__cmp__, __hash__) in sets.Set need to be overridden > in a subclass > > I don't get this message. What is it trying to say, and why? The minimal

Re: pychecker - sets.Set need to be overridden

2005-01-17 Thread Istvan Albert
[EMAIL PROTECTED] wrote: <__main__.Foo instance at 0x00C578A0> Set([]) on 2.4. on WinXP. What environment do you run in? I'm running it on cygwin, but still don't get it, why the warning? Istvan. -- http://mail.python.org/mailman/listinfo/python-list

Re: pychecker - sets.Set need to be overridden

2005-01-17 Thread [EMAIL PROTECTED]
mport sets class Foo: def __init__(self): self.x = sets.Set() x = Foo() print x, getattr(x, 'x') gives for me: <__main__.Foo instance at 0x00C578A0> Set([]) on 2.4. on WinXP. What environment do you run in? -- http://mail.python.org/mailman/listinfo/python-list

Re: PyChecker messages

2005-01-16 Thread Cameron Laird
In article <[EMAIL PROTECTED]>, Roger Binns <[EMAIL PROTECTED]> wrote: . . . >> runner.py:200: Function (detectMimeType) has too many returns (11) >> >> The function is simply a long "else-if" clause, branching out to different

Re: PyChecker messages

2005-01-11 Thread Sylvain Thenault
On Tue, 11 Jan 2005 06:54:54 +, Frans Englich wrote: > Hello, Hi > I take PyChecker partly as an recommender of good coding practice You may alos be interested by Pylint [1]. Pylint is less advanced in bug detection than pychecker, but imho its good coding practice detection is more advan

Re: PyChecker messages

2005-01-11 Thread Eric Brunel
Frans Englich wrote: Hello, I take PyChecker partly as an recommender of good coding practice, but I cannot make sense of some of the messages. For example: runner.py:878: Function (main) has too many lines (201) What does this mean? Cannot functions be large? Or is it simply an advice that func

Re: PyChecker messages

2005-01-11 Thread Roger Binns
> runner.py:878: Function (main) has too many lines (201) > > What does this mean? Cannot functions be large? Or is it simply an advice that > functions should be small and simple? It is advice. > runner.py:200: Function (detectMimeType) has too many returns (11) > > The function is simply a long

stretching a string over several lines (Re: PyChecker messages)

2005-01-10 Thread Steven Bethard
Frans Englich wrote: Also, another newbie question: How does one make a string stretch over several lines in the source code? Is this the proper way? (1) print "asda asda asda asda asda asda " \ "asda asda asda asda asda asda " \ "asda asda asda asda asda asda" A couple of other op