From 0f07dc95f130b9ace00ad98f1b2a3f5c34662e4a Mon Sep 17 00:00:00 2001 From: Matt Mastracci Date: Thu, 3 Aug 2023 14:04:37 -0600 Subject: chore: fix pty support on Macs (#20037) Many of the CI tests have been failing on my M2 Pro mac (Ventura 13.4) when running inside of a vscode terminal (a strange `ENOTTY` error). This modifies the pty-handling code to use libc directly rather than the older pty library that appears mostly unmaintained (outside of @littledivy's fork). As a bonus, this should allow us to run pty tests on the mac CI runner. After this PR, the tests now complete with 100% success on my local machine. Before this PR, I needed to pass `CI=true` to get my local test suite to pass. --- test_util/Cargo.toml | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'test_util/Cargo.toml') diff --git a/test_util/Cargo.toml b/test_util/Cargo.toml index 73df1fab9..2f35473e8 100644 --- a/test_util/Cargo.toml +++ b/test_util/Cargo.toml @@ -24,6 +24,7 @@ futures.workspace = true glob.workspace = true hyper = { workspace = true, features = ["server", "http1", "http2", "runtime"] } lazy-regex.workspace = true +libc.workspace = true lsp-types.workspace = true nix.workspace = true once_cell.workspace = true @@ -43,8 +44,5 @@ tokio.workspace = true tokio-rustls.workspace = true url.workspace = true -[target.'cfg(unix)'.dependencies] -pty2 = "0.1.0" - [target.'cfg(windows)'.dependencies] winapi = { workspace = true, features = ["consoleapi", "synchapi", "handleapi", "namedpipeapi", "winbase", "winerror"] } -- cgit v1.2.3