API change proposal: getting rid of the "create" method for observers
See original GitHub issueThis change is backward compatible (given that a user didn’t use the undocumented __init__ method of observers)
I would propose that the recommended way of calling an observer would be by calling the constructor __init__(), not the create() method. We can be backward compatible by forwarding the arguments of the create method to the __init__().
I understand from the codebase that __init__ was used internally, to recreate observers from existing metrics and other existing data (in the middle of the experiment). I propose that we move this functionality to a new method called create_from().
Calling the class constructor will feel natural and avoid documentation lookups. It would be better that the most convenient method (the constructor) is used externally than internally.
We can drop a warning in the create function and keep it around indefinitely.
If all lights are greens from the maintainers I can do the change and update the docs.
Issue Analytics
- State:
- Created 4 years ago
- Reactions:1
- Comments:14 (2 by maintainers)

Top Related StackOverflow Question
#601 Was created. I find it very clean. Do we all agree on this new API?
This issue can be closed as all the observers have been done.