DanielSank / observed

Observer pattern in python
MIT License
33 stars 4 forks source link

Fix missing docstrings #2

Closed coldfix closed 10 years ago

coldfix commented 10 years ago

Modules/packages should have docstrings to give a short introduction to what they contain.

Furthermore, the constructor ObservedCallable.__init__ really has to have a docstring in order to explain the purpose of the obj parameter (at first look, I had no clue, even after reading the constructor code).

Even for the internal methods _addFunction and _addBoundMethods short docstrings would be nice, to explain what they do (for devs).

DanielSank commented 10 years ago

Marked as bug because I firmly believe undocumented and untested code is fundamentally broken :)

DanielSank commented 10 years ago

Furthermore, the constructor ObservedCallable.init really has to have a docstring in order to explain the purpose of the obj parameter (at first look, I had no clue, even after reading the constructor code).

In refactoring and simplifying the code, this complication has been removed.

DanielSank commented 10 years ago

The module is now fully documented in the dedicated-classes branch. The project is now poised for 0.5 release. I expect 0.5 to be the final release before 1.0, as the interface is now completely stable. Unless major bugs are discovered soon, 0.5 will likely be promoted to 1.0 without any changes.

Many many thanks to @coldfix for identifying bugs, educating me on good coding practice, and encouraging words.