I've just completed a feature that I've been working on for the last
two weeks. In short, it allows Pythoscope to analyze projects of
practically any size and number of modules. I achieved that by
decoupling modules' ASTs from the rest of Pythoscope data and storing
them separately, in their own pickle files. During test generation
only a handful (exactly one in most cases) of ASTs are modified, so
there's no need to keep all of them in memory at once.
I successfully tested the feature on the Leo editor source code, which
has 320k LOC and more than 10Mb of source code in total.
For those willing to give it a try:
bzr branch lp:~ruby/pythoscope/memory-profiling
Note that you'll have to reinitialize your dot pythoscope directory if
you used other version of pythoscope before.
There are still some corner cases to check, but I hope to merge this
branch into trunk this week.
Cheers,
mk
Good idea, and already registered as a blueprint:
https://blueprints.launchpad.net/pythoscope/+spec/keep-pythoscope-version-in-pickle-file
> While I am on the subject of project directories, I still cling to the idea
> that Pythoscope should automatically create it instead of the user having to
> issue a separate pythoscope --init command. It would make editor
> integration a little easier.
The problem remains - how to figure out which directory is the top
directory of a project (in other words, into which directory we should
put dot pythoscope). One possible hint is the presence of setup.py
file, but not all projects have them.
Cheers,
mk