-
Notifications
You must be signed in to change notification settings - Fork 38.7k
test: Fix failing univalue float test #29892
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
test: Fix failing univalue float test #29892
Conversation
|
The following sections might be updated with supplementary metadata relevant to reviewers and maintainers. Code CoverageFor detailed information about the code coverage, see the test coverage report. ReviewsSee the guideline for information on the review process.
If your review is incorrectly listed, please react with 👎 to this comment and the bot will ignore it on the next update. |
stickies-v
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
ACK fa4c696 , thanks for fixing!
|
For testing, one can use gcc-13 (or later) on i386. For example, running the centos CI task on diff --git a/ci/test/00_setup_env_i686_centos.sh b/ci/test/00_setup_env_i686_centos.sh
index 5f8391c..dc80e98 100755
--- a/ci/test/00_setup_env_i686_centos.sh
+++ b/ci/test/00_setup_env_i686_centos.sh
@@ -12,6 +12,7 @@ export CI_IMAGE_NAME_TAG="quay.io/centos/amd64:stream9"
export CI_BASE_PACKAGES="gcc-c++ glibc-devel.x86_64 libstdc++-devel.x86_64 glibc-devel.i686 libstdc++-devel.i686 ccache libtool make git python3 python3-pip which patch lbzip2 xz procps-ng dash rsync coreutils bison util-linux e2fsprogs cmake"
export PIP_PACKAGES="pyzmq"
export GOAL="install"
+export DEP_OPTS="NO_QT=1"
export NO_WERROR=1 # Suppress error: #warning _FORTIFY_SOURCE > 2 is treated like 2 on this platform [-Werror=cpp]
-export BITCOIN_CONFIG="--enable-zmq --with-gui=qt5 --enable-reduce-exports"
+export BITCOIN_CONFIG="--enable-zmq --enable-reduce-exports"
export CONFIG_SHELL="/bin/dash"
diff --git a/ci/test/01_base_install.sh b/ci/test/01_base_install.sh
index 25962a5..6f61394 100755
--- a/ci/test/01_base_install.sh
+++ b/ci/test/01_base_install.sh
@@ -20,7 +20,6 @@ if [ -n "$DPKG_ADD_ARCH" ]; then
fi
if [[ $CI_IMAGE_NAME_TAG == *centos* ]]; then
- bash -c "dnf -y install epel-release"
bash -c "dnf -y --allowerasing install $CI_BASE_PACKAGES $PACKAGES"
elif [ "$CI_OS_NAME" != "macos" ]; then
if [[ -n "${APPEND_APT_SOURCES_LIST}" ]]; thenOr, alternatively, using gcc in the multiprocess task: diff --git a/ci/test/00_setup_env_i686_multiprocess.sh b/ci/test/00_setup_env_i686_multiprocess.sh
index 00a4d78..517ca0c 100755
--- a/ci/test/00_setup_env_i686_multiprocess.sh
+++ b/ci/test/00_setup_env_i686_multiprocess.sh
@@ -9,10 +9,10 @@ export LC_ALL=C.UTF-8
export HOST=i686-pc-linux-gnu
export CONTAINER_NAME=ci_i686_multiprocess
export CI_IMAGE_NAME_TAG="docker.io/amd64/ubuntu:24.04"
-export PACKAGES="llvm clang g++-multilib"
-export DEP_OPTS="DEBUG=1 MULTIPROCESS=1"
+export PACKAGES="g++-multilib"
+export DEP_OPTS="DEBUG=1 MULTIPROCESS=1 NO_QT=1"
export GOAL="install"
export TEST_RUNNER_EXTRA="--v2transport"
-export BITCOIN_CONFIG="--enable-debug CC='clang -m32' CXX='clang++ -m32' \
+export BITCOIN_CONFIG="--enable-debug \
CPPFLAGS='-DBOOST_MULTI_INDEX_ENABLE_SAFE_MODE'"
export BITCOIND=bitcoin-node # Used in functional tests |
|
Right. Direct floating point equality checks are a big nono. It should either use an epsilon comparison, or discretize. Which is what the new test does. ACK fa4c696 |
|
Backported to 27.x in #29888. |
Github-Pull: bitcoin#29892 Rebased-From: fa4c696
Github-Pull: bitcoin#29892 Rebased-From: fa4c696
bd5860b [WIP] doc: release notes for 27.x (fanquake) 475aac4 doc: add LLVM instruction for macOS < 13 (Sjors Provoost) a995902 depends: Fix build of Qt for 32-bit platforms (laanwj) 0fcceef Fix #29767, set m_synced = true after Commit() (nanlour) ae9a2ed sign: don't assume we are parsing a sane Miniscript (Antoine Poinsot) a6a59cf rpc: Reword SighashFromStr error message (MarcoFalke) 364bf01 build: Fix false positive `CHECK_ATOMIC` test for clang-15 (Hennadii Stepanov) 9277793 test: Fix failing univalue float test (MarcoFalke) 5c09791 doc: archive 27.0 release notes (fanquake) 897e5af [rpc, bugfix] Enforce maximum value for setmocktime (dergoegge) 602cfd5 ci: Bump s390x to ubuntu:24.04 (MarcoFalke) 20e6e8d Change Luke Dashjr seed to dashjr-list-of-p2p-nodes.us (Luke Dashjr) a6862c5 depends: fix mingw-w64 Qt DEBUG=1 build (fanquake) Pull request description: Backports: * #29691 * #29747 * #29776 * #29853 * #29856 * #29859 * #29869 * #29870 * #29886 * #29892 * #29934 * #29985 ACKs for top commit: willcl-ark: reACK bd5860b stickies-v: re-ACK bd5860b TheCharlatan: ACK bd5860b Tree-SHA512: a1a40de70cf52b5fc01d9dcc772421751a18c6a48a726c4c05c0371c585a53a27902e17daed9e0d721ab7763c94bb32de05c146bd6bc73fd558edd08b31e8547
Summary: ``` Currently the test may fail for some compilers, because 1e-8 may not be possible to represent exactly/consistently. ``` Backport of [[bitcoin/bitcoin#29892 | core#29892]]. Depends on D16296. Test Plan: ninja check check-univalue Reviewers: #bitcoin_abc, PiRK Reviewed By: #bitcoin_abc, PiRK Differential Revision: https://reviews.bitcoinabc.org/D16297
Currently the test may fail for some compilers, because
1e-8may not be possible to represent exactly/consistently.Fixes #27256 (comment)