Open plaeremans opened 8 months ago
Hello,
This looks like #317.
You probably need to disable default features in cargo.toml and then enable rustls. By default native-tls is enabled and what you see is probably conflict between two enabled tls implememtations.
In case it helps anyone with the same issue, you can disable default features and enable rustls with:
[dependencies]
tiberius = { version = "0.12.2", default-features = false, features = ["rustls"] }
Going slightly further, you can selectively use rustls for macOS, and native-tls on all other platforms. This works around issues with macOS Security Framework having issues with Azure SQL Server, and does not impact other platforms:
[target.'cfg(target_os = "macos")'.dependencies]
tiberius = { version = "0.12.2", default-features = false, features = ["chrono", "time", "tds73", "rust_decimal", "bigdecimal", "rustls"] }
# Different syntax to keep things narrow
[target.'cfg(not(target_os = "macos"))'.dependencies.tiberius]
version = "0.12.2"
default-features = false
features = ["chrono", "time", "tds73", "rust_decimal", "bigdecimal", "native-tls"]
edit: TOML syntax
I' have problems trying to connect to SQL Server with Tiberius. I was trying to use rustls instead of the default, but I don't get Tiberius to compile
The Tiberius crate does not compile. Any ideas ?