Skip to content
Snippets Groups Projects
Commit 1747da4cac04 authored by Manuel Jacob's avatar Manuel Jacob
Browse files

pytype: pass --strict-none-binding to pytype

Without this option, pytype sometimes assigns type Any to a variable even though it clearly can be None.

The following is a typing error which is catched with this option but not without:

x = None
def f():
    return x.upper()
parent 9af1acc1ffab
No related tags found
No related merge requests found
......@@ -121,7 +121,8 @@
-x mercurial/win32.py \
-x mercurial/wireprotoframing.py \
-x mercurial/wireprotov1peer.py \
-x mercurial/wireprotov1server.py
-x mercurial/wireprotov1server.py \
--strict-none-binding
if find .pytype/pyi -name '*.pyi' | xargs grep -ql '# Caught error'; then
echo 'pytype crashed while generating the following type stubs:'
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment