goxtool icon indicating copy to clipboard operation
goxtool copied to clipboard

Some refactoring suggestions

Open nfx8 opened this issue 12 years ago • 2 comments

The goxapi.py has 1696 LOC. I'm going to use parts of goxapi and refactor a module, so that it is independent of the UI and the exchange. I would split up the goxapi.py in orders.py (Order and Orderbook classes), exc_cllients.py (BaseClient and SocketIO / Websocket classes), config.py (Secret, Goxconfig classes), util.py (number conversions and pretty_format).

The Gox object is an active streaming object (start method), as well as a passive broker to the exchange. A request sometimes can not only be a streaming request, but a one time request.

I can do a pull request if there is interest. It makes sense to have one great MtGox API out there, where then everyone can add their own stuff ontop. goxtool this is certainly the best existing code for interfacing with MtGox and I would like to contribute to a common base.

nfx8 avatar Apr 16 '13 10:04 nfx8

maybe its best to create a fork and develop that as a separete project. I didn't intend to make the one and ultimate complete reference API that implements everything, its just a small subset of things needed for goxtool and inspiration for bigger projects that move into different directions.

prof7bit avatar Apr 17 '13 13:04 prof7bit

sure. will do. thanks again.

nfx8 avatar Apr 17 '13 13:04 nfx8