Skip to content

Commit

Permalink
update typings
Browse files Browse the repository at this point in the history
  • Loading branch information
blink1073 committed Oct 15, 2023
1 parent 1a19aa4 commit a6f56a8
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 4 deletions.
3 changes: 1 addition & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,7 @@ Homepage = "https://github.com/jupyter/terminado"
[project.optional-dependencies]
test = [ "pytest>=7.0", "pre-commit", "pytest-timeout",]
docs = [ "sphinx", "pydata-sphinx-theme", "myst_parser"]

typing = ["mypy>=1.5.1"]
typing = ["mypy~=1.6", "traitlets>=5.11.1"]

[tool.hatch.version]
path = "terminado/_version.py"
Expand Down
4 changes: 2 additions & 2 deletions terminado/management.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,15 +21,15 @@
from terminado.websocket import TermSocket

try:
from ptyprocess import PtyProcessUnicode # type:ignore[import]
from ptyprocess import PtyProcessUnicode # type:ignore[import-untyped]

def preexec_fn() -> None:
"""A prexec function to set up a signal handler."""
signal.signal(signal.SIGPIPE, signal.SIG_DFL)

except ImportError:
try:
from winpty import PtyProcess as PtyProcessUnicode # type:ignore[import]
from winpty import PtyProcess as PtyProcessUnicode # type:ignore[import-not-found]
except ImportError:
PtyProcessUnicode = object
preexec_fn = None # type:ignore[assignment]
Expand Down

0 comments on commit a6f56a8

Please sign in to comment.