From 4f2c68e5a4b256eefefbf85ac1960bc2f95cc005 Mon Sep 17 00:00:00 2001 From: link2xt Date: Wed, 6 Jul 2022 22:45:44 +0000 Subject: [PATCH] Accept more error variants in `nicer_configuration_error` musl libc returns "failed to lookup address information: Name does not resolve" in some cases. --- CHANGELOG.md | 1 + python/tests/test_1_online.py | 2 +- src/configure.rs | 3 +++ 3 files changed, 5 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index d48d68bf4..601ac1850 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,7 @@ ### Changes ### Fixes +- replace musl libc name resolution errors with a better message #3485 ## 1.88.0 diff --git a/python/tests/test_1_online.py b/python/tests/test_1_online.py index e2d587931..d7e86e61a 100644 --- a/python/tests/test_1_online.py +++ b/python/tests/test_1_online.py @@ -1854,7 +1854,7 @@ def test_configure_error_msgs_invalid_server(acfactory): # Can't connect so it probably should say something about "internet" # again, should not repeat itself # If this fails then probably `e.msg.to_lowercase().contains("could not resolve")` - # in configure/mod.rs returned false because the error message was changed + # in configure.rs returned false because the error message was changed # (i.e. did not contain "could not resolve" anymore) assert (ev.data2.count("internet") + ev.data2.count("network")) == 1 # Should mention that it can't connect: diff --git a/src/configure.rs b/src/configure.rs index 620932c06..e896313f0 100644 --- a/src/configure.rs +++ b/src/configure.rs @@ -642,6 +642,9 @@ async fn nicer_configuration_error(context: &Context, errors: Vec