<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Nov 6, 2017 at 11:34 AM, Stéfane Fermigier <span dir="ltr"><<a href="mailto:sf@fermigier.com" target="_blank">sf@fermigier.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">[...]<br></div></blockquote><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div>Now I believe something could be done along the lines:</div><div><br></div><div>a) record runtime type information from test or regular runs<br></div><div>b) massage these information and use them to annotate Python code with additional type information (up to the developer to then accept or not the proposed changes)</div><div>c) also run a test suite or an app under some magical machinery, and either raise a TypeError or log warnings when discrepancies are detected between type annotation and runtime behaviour.</div><div><br></div><div>[...] (a) and (b) would use similar machinery, </div></div></blockquote><div><br></div><div>I mean, (a) and (c)</div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr"><div>and (a), (b) and (c) would be probably a useful way to introduce type annotations to an existing code base without too much risk.</div><div><br></div><div>(a) and (b) could also provide data for an interesting SE research project.</div></div></blockquote><div><br></div><div>Similar to "Measuring Polymorphism in Python Programs", by Beatrice Akerblom and Tobias Wrigstad: </div><div><a href="https://people.dsv.su.se/~beatrice/python/dls15_large_images.pdf">https://people.dsv.su.se/~beatrice/python/dls15_large_images.pdf</a></div><div><br></div><div>  S.</div><div><br></div></div>-- <br><div class="gmail_signature"><div dir="ltr"><div><div dir="ltr"><div dir="ltr"><div dir="ltr"><div dir="ltr">Stefane Fermigier - <a href="http://fermigier.com/" target="_blank">http://fermigier.com/</a> - <a href="http://twitter.com/sfermigier" target="_blank">http://twitter.com/sfermigier</a> - <a href="http://linkedin.com/in/sfermigier" target="_blank">http://linkedin.com/in/sfermigier</a><br>Founder & CEO, Abilian - Enterprise Social Software - <a href="http://www.abilian.com/" target="_blank">http://www.abilian.com/</a><br>Chairman, Free&OSS Group / Systematic Cluster - <a href="http://www.gt-logiciel-libre.org/" target="_blank">http://www.gt-logiciel-libre.org/</a><br>Co-Chairman, National Council for Free & Open Source Software (CNLL) - <a href="http://cnll.fr/" target="_blank">http://cnll.fr/</a><div>Founder & Organiser, PyData Paris - <a href="http://pydata.fr/" target="_blank">http://pydata.fr/</a><br></div><div>---</div><div><div>“You never change things by fighting the existing reality. To change something, build a new model that makes the existing model obsolete.” <span style="font-size:12.8px">— R. Buckminster Fuller</span></div></div><div><br><br></div></div></div></div></div></div></div></div>
</div></div>