[IronPython] Pyflakes on IronPython
fabio.pliger
fabio.pliger at siavr.it
Tue Jan 2 10:15:15 CET 2007
Great!
Just want to post an apreciation note to Seo for the work he is doing! It's
is amazing!
Big cheers!
Fabio
-----Original Message-----
From: "Sanghyeon Seo" <sanxiyn at gmail.com>
To: "Discussion of IronPython" <users at lists.ironpython.com>
Date: Sun, 31 Dec 2006 13:41:20 +0900
Subject: [***SPAM*** Punteggio: 17.5/11.0] [IronPython] Pyflakes on
IronPython
On June 22, Michael Foord wrote:
"At Resolver we are looking into tools that we can use to provide
simple code hygiene checks. Check we're not shadowing built-in names,
check for unneeded import statements and unused variables; that sort
of thing.
I know of three Python modules that do this. They all fail
unredeemably on IronPython: (snip)
Pyflakes: Uses compiler.parse."
This is also CodePlex issue #563, titled "Support for Code Quality Tools".
http://www.codeplex.com/IronPython/WorkItem/View.aspx?WorkItemId=563
[http://www.codeplex.com/IronPython/WorkItem/View.aspx?WorkItemId=563]
In the release note of IPCE r5, I wrote:
"Experimental AST support."
For those who don't know, compiler.parse() returns AST, so they are
the same thing.
I am happy to announce that FePy's AST support got out of experimental
status, and is now mature enough to run Pyflakes without much trouble.
Actually, I ran it over FePy libraries and fixed a couple of unused
.NET imports!
This is done by "AST transform", which transforms AST made of
subclasses of IronPython.Compiler.Ast.Node to AST made of subclasses
of Python's compiler.ast.Node. Technical details will be discussed in
the separate mail.
Here's a demo:
tinuviel at debian:~/svn/fepy$ ipy /usr/bin/pyflakes trunk/lib
trunk/lib/_pth_support.py:116: 'sitecustomize' imported but unused
trunk/lib/socket.py:222: 'ssl' imported but unused
trunk/lib/socket.py:227: '_fileobject' imported but unused
(These warnings are all true, but sitecustomize import is for the side
effect, and ssl/_fileobject is part of external API.)
Enjoy!
--
Seo Sanghyeon
_______________________________________________
users mailing list
users at lists.ironpython.com
http://lists.ironpython.com/listinfo.cgi/users-ironpython.com
[http://lists.ironpython.com/listinfo.cgi/users-ironpython.com]
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/ironpython-users/attachments/20070102/5825895a/attachment.html>
More information about the Ironpython-users
mailing list