<div dir="ltr"><div class="gmail_extra"><br><div class="gmail_quote">On Sat, Jan 30, 2016 at 10:59 PM, Phil Thompson <span dir="ltr"><<a href="mailto:phil@riverbankcomputing.com" target="_blank">phil@riverbankcomputing.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">
<br>
However, I'm having trouble testing all this. Can anybody recommend a tool that has reasonable support for PEP 484 stub files? PyCharm? pytype? mypy?<br>
<br></blockquote><div><br></div><div>Hi Phil,<br><br></div><div>That's wonderful news! Personally I find the type annotations to be very useful indeed. <br><br>For your testing, PyCharm might be just the ticket: <a href="http://blog.jetbrains.com/pycharm/2015/11/python-3-5-type-hinting-in-pycharm-5/#stub-files">http://blog.jetbrains.com/pycharm/2015/11/python-3-5-type-hinting-in-pycharm-5/#stub-files</a><br><br></div><div>I've not tested PyCharm with stub files myself, but with respect to in-script type annotating, PyCharm is off to a pretty good start. For instance it handles this:<br><br>self.devices = {}  # type: Dict[int, Device]<br><br></div><div>but not this, where multiple types are specified:<br><br>device, storage_space = index.data(Roles.storage)  # type: Device, StorageSpace<br><br></div><div></div><div>Best,<br></div><div>Damon <br></div></div>-- <br><div class="gmail_signature"><a href="http://www.damonlynch.net" target="_blank">http://www.damonlynch.net</a><div></div><div></div><div></div></div>
</div></div>