Hello everybody,

Here some information about the Pylint Py3k port
as you might have noticed, logilab.common has been made py3k
compatible last month:
http://www.logilab.org/blogentry/46883

Not all the tests will pass (the '-c' option of Pytest will not work), but 
this is not a big problem for us. For the purpose of 
Pylint migration, there is nothing more to do. 

So, after running 2to3 over logilab.common, we can use "pytest" 
to run the tests on logilab.astng (and later on pylint).

We have to start with astng, so a new project has been opened:
http://www.logilab.org/project/logilab-astng/python3k

I started to have a look at it, and fixed some simple issues;

I filled one extra ticket for the relative imports in the tests which must 
be fixed.

Also, I added a TreeTester class in logilab.common.utils to print nice 
represesentation of the _ast and the astng trees:

$ cat expl.py 
from logilab.astng.utils import TreeTester
tester = TreeTester('print')
tester.indent = '| '
tester.lineno = 1
print tester.native_tree_repr()
print tester.astng_tree_repr(True)


$ python expl.py 

<Module>
| body = [
| <Print>
| | lineno = 1
| | col_offset = 0
| | nl = True
| ]
Module()  .     1a65450
    body = [
    Print()  .  1a65490
        dest = 
        values = [
        ]
    ]

This will be usefull when a crash occures and we want to investigate the 
trees. So, I hope this will help you to dive into astng and the Pylint 3k 
port.

I will update the wiki...

-- 

Emile Anclin <[email protected]>
http://www.logilab.fr/   http://www.logilab.org/ 
Informatique scientifique & et gestion de connaissances
_______________________________________________
Python-Projects mailing list
[email protected]
http://lists.logilab.org/mailman/listinfo/python-projects

Reply via email to