Agreed that it sounded great on podcast.__init__ and I specifically thought it would be helpful for sklearn as someone who is not a developer but has been digging into the codebase. If anyone on the list wants an overview of MyPy I highly recommend listening to that episode: http://podcastinit.podbean.com/e/episode-65-mypy-with-david-fisher-and-greg-price/
On Thu, Jul 28, 2016 at 2:49 PM, Sebastian Raschka < [email protected]> wrote: > I am not a core dev but just wanted to say that I like the idea of adding > static type checking a lot, Daniel. Coincidentally, I just listened to the > Podcast.__init__ episode on mypy a few weeks ago and was planning to use it > in my personal + research projects as well. > > I think the “normal” scikit-learn user would not really benefit from it > (since the docstrings are already pretty good and thorough), but I think > that it can be immensly useful for devs and contributors (and augmenting > the unittest) > > > We can put mypy in the CI, right? Shouldn't that prevent it from rotting? > > Yeah, it can be added to Travis CI checks, for example. > > One question though, are you planning to apply the “whole" type checking > syntax? E.g., > > def hello(r: int, c=5) -> str: > s = 'hello' # type: str > return '(%d + %d) times %s' % (r, c, s) > > Does this work with Python 2.7, 3.4 etc? > > Or are you only thinking about the “comment” syntax? E.g., > > def hello(r, c=5): > s = 'hello' # type: str > return '(%d + %d) times %s' % (r, c, s) > > Which should work on all Py versions. > > Best, > Sebastian > > > > On Jul 28, 2016, at 12:49 PM, Andreas Mueller <[email protected]> wrote: > > > > > > > > On 07/28/2016 12:43 PM, Gael Varoquaux wrote: > >> On Thu, Jul 28, 2016 at 12:04:48PM -0400, Andreas Mueller wrote: > >>> If you find some bugs with the annotations and mypy, that would > probably > >>> prove its value to some degree [and if you don't, I might be inclined > to > >>> argue it's not working well ;] > >>> Joel, Olivier, Gael, anyone else?: opinions? > >> The only reserve that I might have is with regards to the > maintainability > >> of these annotation. I am afraid that they coderot. > >> > >> Daniel, any comments on that concern? > > We can put mypy in the CI, right? Shouldn't that prevent it from rotting? > > [I don't actually know. Daniel?] > > _______________________________________________ > > scikit-learn mailing list > > [email protected] > > https://mail.python.org/mailman/listinfo/scikit-learn > > _______________________________________________ > scikit-learn mailing list > [email protected] > https://mail.python.org/mailman/listinfo/scikit-learn > -- David Nicholson, Ph.D. Candidate Sober Lab <http://www.biology.emory.edu/research/Sober/Home.html>, Emory Neuroscience Program. <http://www.emory.edu/NEUROSCIENCE/> www.nicholdav.info; <http://www.nicholdav.info>https://github.com/NickleDave
_______________________________________________ scikit-learn mailing list [email protected] https://mail.python.org/mailman/listinfo/scikit-learn
