mirror of https://github.com/zulip/zulip.git
requirements: Upgrade mypy to 0.550.
We have to add a few type: ignores due to mypy 0.550 having some bugs in the new imaplib stubs in typeshed. Fixes #7387.
This commit is contained in:
parent
d639e31641
commit
84847b811b
|
@ -80,7 +80,7 @@ markdown==2.6.9
|
|||
markupsafe==1.0
|
||||
mock==2.0.0
|
||||
moto==1.1.24
|
||||
mypy==0.540
|
||||
mypy==0.550
|
||||
mypy_extensions==0.3.0
|
||||
ndg-httpsclient==0.4.3
|
||||
oauth2client==4.1.2
|
||||
|
@ -98,6 +98,7 @@ pip-tools==1.10.1
|
|||
polib==1.0.8
|
||||
premailer==3.1.1
|
||||
prompt-toolkit==1.0.15 # via ipython
|
||||
psutil==5.4.1 # via mypy
|
||||
psycopg2==2.7.3.2
|
||||
ptyprocess==0.5.2 # via pexpect
|
||||
py3dns==3.1.0
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
# /tools/update-locked-requirements to update requirements/dev.txt
|
||||
# and requirements/mypy.txt.
|
||||
# See requirements/README.md for more detail.
|
||||
mypy==0.540
|
||||
mypy==0.550
|
||||
|
||||
# Include typing explicitly, since it's needed on Python 3.4
|
||||
typing==3.6.2
|
||||
|
|
|
@ -7,6 +7,7 @@
|
|||
#
|
||||
# For details, see requirements/README.md .
|
||||
#
|
||||
mypy==0.540
|
||||
mypy==0.550
|
||||
psutil==5.4.1 # via mypy
|
||||
typed-ast==1.1.0 # via mypy
|
||||
typing==3.6.2
|
||||
|
|
|
@ -88,7 +88,7 @@ extra_args = ["--check-untyped-defs",
|
|||
"--follow-imports=silent",
|
||||
"--scripts-are-modules",
|
||||
"-i", "--cache-dir=var/mypy-cache",
|
||||
"--disallow-any=generics"]
|
||||
"--disallow-any-generics"]
|
||||
if args.linecoverage_report:
|
||||
extra_args.append("--linecoverage-report")
|
||||
extra_args.append("var/linecoverage-report")
|
||||
|
|
|
@ -1,3 +1,3 @@
|
|||
ZULIP_VERSION = "1.7.1+git"
|
||||
|
||||
PROVISION_VERSION = '12.2'
|
||||
PROVISION_VERSION = '13.0'
|
||||
|
|
|
@ -51,13 +51,13 @@ def get_imap_messages() -> Generator[Message, None, None]:
|
|||
try:
|
||||
mbox.select(settings.EMAIL_GATEWAY_IMAP_FOLDER)
|
||||
try:
|
||||
status, num_ids_data = mbox.search(None, 'ALL') # type: bytes, List[bytes]
|
||||
status, num_ids_data = mbox.search(None, 'ALL') # type: ignore # https://github.com/python/typeshed/pull/1762
|
||||
for msgid in num_ids_data[0].split():
|
||||
status, msg_data = mbox.fetch(msgid, '(RFC822)')
|
||||
msg_as_bytes = msg_data[0][1]
|
||||
message = email.message_from_bytes(msg_as_bytes)
|
||||
yield message
|
||||
mbox.store(msgid, '+FLAGS', '\\Deleted')
|
||||
mbox.store(msgid, '+FLAGS', '\\Deleted') # type: ignore # https://github.com/python/typeshed/pull/1762
|
||||
mbox.expunge()
|
||||
finally:
|
||||
mbox.close()
|
||||
|
|
Loading…
Reference in New Issue