catalog: Refactor things a bit
catalog: Refactor things a bit

That _get_packages method was just terrible. Those raise_if_* boolean
flags were one of the worst thing I ever wrote.

This code evolved organically from a quick proof-of-concept, so it's not
very surprising that it ended up ugly.

This commit tries to make it just a littile bit prettier.

ideascube/ideascube,ideascube/ideascube,ideascube/ideascube,ideascube/ideascube