I don't have permission to post in web2py-developers but I added a comment to the bug report.
I think the problem is the cached object is the class definition, not an instance of the class. The class definition likely has references to the environment or global namespace in order it to function properly (inheritance, attribute enhancement etc.). In the bug posting I changed the sample code to create an instance of class Blah using blah1 = Blah(), cached that and the before and after reference counts for the gluon objects did not double according to guppy. Ron