I have a single code file for my Google App Engine project. This simple file has one class, and inside it a few methods. Why does this python method gives an error saying global
It's an instance method, you need to use self.gen_groups(...) and self.gen_albums(...).
self.gen_groups(...)
self.gen_albums(...)
Edit: I'm guessing the TypeError you are getting now is because you removed the 'self' argument from gen_groups(). You'll need to put it back in:
TypeError
gen_groups()
def get_groups(self, lines): ...