code analysis - Python source analyzer that works with zope components -


there's code base (py 2.6 stuff) extensively uses zope components , there's need tool can analyze sources. tool supposed analyze source; usage of restricted classes/objects/interfaces, etc. basically, scan each statement in source while being aware of statement's context (which class/method/function in, module, etc) , analyze specific patterns.

the approach of reading source text buffers , matching patterns doesn't seem reliable approach @ all.

another approach came of using inspect, inspect seems broken , doesn't seem able handle our code base (multiple tries, of them crashed inspect). might have give on there seems way out inspect.

now, other options think of using pylint or using ast (and doing lot of postprocessing on it). not sure extent pylint extensible; , when comes analyzing source statments if pylint aware of context (i.e, class defn/function/method has statement etc) using ast seems of overkill such trivial purpose.

what suggest suitable approach here? else had deal such issue before?

please suggest.


Comments

Popular posts from this blog

php - Calling a template part from a post -

Firefox SVG shape not printing when it has stroke -

How to mention the localhost in android -