mirror of https://github.com/zulip/zulip.git
enqueue_file.py: Add type hint for mypy.
This commit is contained in:
parent
896c18a57b
commit
c679c180f5
|
@ -41,7 +41,6 @@ exclude_py2 = []
|
|||
|
||||
exclude_py3 = """
|
||||
zerver/lib/ccache.py
|
||||
zerver/management/commands/enqueue_file.py
|
||||
zerver/management/commands/rename_stream.py
|
||||
zerver/management/commands/runtornado.py
|
||||
zerver/tests/test_i18n.py
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
from __future__ import absolute_import
|
||||
from __future__ import print_function
|
||||
|
||||
from typing import Any
|
||||
from typing import Any, IO
|
||||
|
||||
from argparse import ArgumentParser
|
||||
from django.core.management.base import BaseCommand
|
||||
|
@ -39,7 +39,7 @@ You can use "-" to represent stdin.
|
|||
file_name = options['file_name']
|
||||
|
||||
if file_name == '-':
|
||||
f = sys.stdin
|
||||
f = sys.stdin # type: IO[str]
|
||||
else:
|
||||
f = open(file_name)
|
||||
|
||||
|
|
Loading…
Reference in New Issue