<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">
I just had the idea of developing a static analyzer for typical PyQt<br>
issues, as a checker for pylint (<a href="http://www.pylint.org/" target="_blank">http://www.pylint.org/</a>).<br>
<br>
I'd like some input on what issues could be checked. What came to my<br>
mind so far:<br>
...<br>
- Checking types of arguments (by extracting the desired ones from the<br>
  docstrings?) - this will probably the hardest one, but also the one<br>
  with the most benefits.<br></blockquote><div><br></div><div>There has been a lot of activity recently on the<br></div><div>general subject of Python "type hinting" and "type checking"<br>with multiple competing syntaxes proposed.<br><br>Python 3 already has an obscurely-documented feature [2] allowing<br>you to annotate function args & result with type expressions.<br></div><div>I think these are compatible with PyQt class names?<br></div><div><br><div>There are other existing syntax proposals like Obiwan [3],<br></div><div>typecheck-decorator [4] or Ensure [5].<br></div><br></div><div>Guido just put out a semi-formal proposal for a framework [1].<br><br>[1]  <a href="https://mail.python.org/pipermail/python-ideas/2014-December/030430.html">https://mail.python.org/pipermail/python-ideas/2014-December/030430.html</a><br><br></div><div>[2] <a href="https://docs.python.org/3.3/reference/compound_stmts.html#index-23">https://docs.python.org/3.3/reference/compound_stmts.html#index-23</a><br><br>[3] <a href="https://pypi.python.org/pypi/obiwan">https://pypi.python.org/pypi/obiwan</a><br><br>[4] <a href="https://github.com/prechelt/typecheck-decorator">https://github.com/prechelt/typecheck-decorator</a><br><br>[5] <a href="https://github.com/kislyuk/ensure">https://github.com/kislyuk/ensure</a><br></div></div></div></div>