Thinking: Refactoring consul/base.py
Any thoughts about refactoring the classes in base.py it into separate modules? Is this something you'd like to see @cablehead?
Yeah, it's not too unruly for my subjective tastes, but it's definitely on the edge. We're at 1740 lines now. You're thinking split it by top level endpoint? kv, event, etc?
Pros would be it'd easier to focus on a given endpoint. Con would be it'd be harder to do an entire API sweep to check things are consistent.
I think the time has come to make this split.
I'm thinking:
- make the spilt by top level endpoint name
- think through if there's something we could do with broadly common parameters to have them applied consistently, and succinctly, so you can see at a glance they've been applied to an endpoint. challenge for this one is to do it in a way that isn't verbose, but doesn't involve magic.
BTW @cruatta you've been one of the best contributors for this project. Would you be interested in having admin access to be able to help maintain it going forward? @abn is also a maintainer now and it's been great to have the project keep moving forward when I'm unavailable.
An example of where it's currently easy for endpoints do not get consistent treatment: https://github.com/cablehead/python-consul/issues/116
Hey thanks Andy! I can't promise that I have a lot of free time but I'd be glad to help in any way I can, including putting some time towards the split.
This is just awful. I hate magic. But just brain storming ways to make it easy to consistently and explicitly apply parameters - while preserving method signature and docstrings for help and autodoc: https://gist.github.com/cablehead/7fc6d015a3a0c58d7ffdf50df9aaed0d