From e542419ad2180246fc587becb60d680b9fb273c1 Mon Sep 17 00:00:00 2001 From: Carter Canedy Date: Mon, 16 Feb 2026 10:53:08 -0800 Subject: [PATCH 1/5] bump msrv and crate version --- Cargo.toml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 45f18d9..984ccb4 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,13 +1,13 @@ [package] name = "ads" -version = "0.4.4" +version = "0.5.0" edition = "2018" authors = ["Georg Brandl "] license = "MIT/Apache-2.0" description = "Client for the Beckhoff Automation Device Specification protocol for PLCs" repository = "https://github.com/birkenfeld/ads-rs" keywords = ["Beckhoff", "ADS", "automation", "device", "PLC"] -rust-version = "1.63" +rust-version = "1.71" [dependencies] byteorder = "1.5.0" From eb0ea7b54b9b143087a40f53acdacfdb0a3e9878 Mon Sep 17 00:00:00 2001 From: Carter Canedy Date: Mon, 16 Feb 2026 11:07:00 -0800 Subject: [PATCH 2/5] update CI testing matrix --- .github/workflows/main.yml | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 90ca174..907803f 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -8,13 +8,20 @@ on: jobs: test: name: Test - runs-on: ubuntu-latest strategy: matrix: toolchain: - - 1.63.0 + - 1.71.0 - stable - nightly + + os: + - "ubuntu-latest" + - "macos-latest" + - "windows-latest" + + runs-on: ${{ matrix.os }} + steps: - uses: actions/checkout@v4 - uses: actions-rust-lang/setup-rust-toolchain@v1 From 7b48948ae3777a5fbe337d353a1f1eb8183f7efe Mon Sep 17 00:00:00 2001 From: Carter Canedy Date: Mon, 16 Feb 2026 11:09:32 -0800 Subject: [PATCH 3/5] update readme with new MSRV and crate version --- README.md | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/README.md b/README.md index bda3cd6..29bf6e1 100644 --- a/README.md +++ b/README.md @@ -13,12 +13,12 @@ Use with Cargo as usual, no system dependencies are required. ```toml [dependencies] -ads = "0.4" +ads = "0.5" ``` ### Rust version -Minimum supported Rust version is 1.63.0. +Minimum supported Rust version is 1.71.0. ## Usage @@ -68,3 +68,4 @@ routes automatically. A utility called `adstool` is found under `examples/`, very similar to the one provided by [the C++ library](https://github.com/Beckhoff/ADS). + From 8e89d1242593ec973be5b8930ad963e97909d9b6 Mon Sep 17 00:00:00 2001 From: Carter Canedy Date: Mon, 16 Feb 2026 11:34:38 -0800 Subject: [PATCH 4/5] handle macos-specific socket timeout behavior --- src/test/test_client.rs | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/src/test/test_client.rs b/src/test/test_client.rs index 3784c63..3db19ba 100644 --- a/src/test/test_client.rs +++ b/src/test/test_client.rs @@ -26,9 +26,22 @@ fn test_timeout() { run_test( ServerOpts { timeout: Some(Duration::from_millis(1)), ..Default::default() }, |device| { + use std::io::ErrorKind; let err = device.get_info().unwrap_err(); + + // darwin (maybe other BSDs too?) kernel seems to return `WouldBlock` on timeout + // linux/windows align on returning `TimedOut`, which makes more sense semantically + let expected_err = { + #[cfg(target_os = "macos")] { + ErrorKind::WouldBlock + } + #[cfg(not(target_os = "macos"))] { + ErrorKind::TimedOut + } + }; + match err { - Error::Io(_, err) if matches!(err.kind(), std::io::ErrorKind::TimedOut) => (), + Error::Io(_, err) if err.kind() == expected_err => (), _ => panic!("unexpected error from timeout: {}", err), } }, From f9bc7b4cf470d1732d238e287ab1b2c7c81338fb Mon Sep 17 00:00:00 2001 From: Carter Canedy Date: Mon, 16 Feb 2026 11:36:13 -0800 Subject: [PATCH 5/5] fmt --- src/test/test_client.rs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/test/test_client.rs b/src/test/test_client.rs index 3db19ba..82b7433 100644 --- a/src/test/test_client.rs +++ b/src/test/test_client.rs @@ -32,10 +32,12 @@ fn test_timeout() { // darwin (maybe other BSDs too?) kernel seems to return `WouldBlock` on timeout // linux/windows align on returning `TimedOut`, which makes more sense semantically let expected_err = { - #[cfg(target_os = "macos")] { + #[cfg(target_os = "macos")] + { ErrorKind::WouldBlock } - #[cfg(not(target_os = "macos"))] { + #[cfg(not(target_os = "macos"))] + { ErrorKind::TimedOut } };