Skip to content

Commit ed27d30

Browse files
committed
Merge branch 'bitcoin' into auxpow
2 parents 1e07205 + 6a13a61 commit ed27d30

File tree

120 files changed

+2653
-1239
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

120 files changed

+2653
-1239
lines changed

.github/ci-test-each-commit-exec.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ def main():
2727
"cmake",
2828
"-B",
2929
"build",
30+
"-Werror=dev",
3031
"-DCMAKE_C_COMPILER=clang",
3132
"-DCMAKE_CXX_COMPILER=clang++",
3233
"-DWERROR=ON",

.github/workflows/ci.yml

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -223,7 +223,7 @@ jobs:
223223

224224
- name: Generate build system
225225
run: |
226-
cmake -B build --preset vs2022 -DCMAKE_TOOLCHAIN_FILE="${VCPKG_INSTALLATION_ROOT}/scripts/buildsystems/vcpkg.cmake" ${{ matrix.generate-options }}
226+
cmake -B build -Werror=dev --preset vs2022 -DCMAKE_TOOLCHAIN_FILE="${VCPKG_INSTALLATION_ROOT}/scripts/buildsystems/vcpkg.cmake" ${{ matrix.generate-options }}
227227
228228
- name: Save vcpkg binary cache
229229
uses: actions/cache/save@v4
@@ -390,9 +390,6 @@ jobs:
390390
(Get-Content "test/config.ini") -replace '(?<=^SRCDIR=).*', '${{ github.workspace }}' -replace '(?<=^BUILDDIR=).*', '${{ github.workspace }}' -replace '(?<=^RPCAUTH=).*', '${{ github.workspace }}/share/rpcauth/rpcauth.py' | Set-Content "test/config.ini"
391391
Get-Content "test/config.ini"
392392
393-
- name: Run rpcauth test
394-
run: py -3 test/util/rpcauth-test.py
395-
396393
- name: Set previous release directory
397394
run: |
398395
echo "PREVIOUS_RELEASES_DIR=${{ runner.temp }}/previous_releases" >> "$GITHUB_ENV"

CMakeLists.txt

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -592,7 +592,7 @@ mark_as_advanced(Python3_FIND_FRAMEWORK Python3_FIND_UNVERSIONED_NAMES)
592592
find_package(Python3 3.10 COMPONENTS Interpreter)
593593
if(NOT TARGET Python3::Interpreter)
594594
list(APPEND configure_warnings
595-
"Minimum required Python not found. Rpcauth tests are disabled."
595+
"Minimum required Python not found."
596596
)
597597
endif()
598598

@@ -636,8 +636,6 @@ add_subdirectory(doc)
636636

637637
add_subdirectory(src)
638638

639-
include(cmake/tests.cmake)
640-
641639
include(Maintenance)
642640
setup_split_debug_script()
643641
add_maintenance_targets()

CMakePresets.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,7 @@
6262
"name": "dev-mode",
6363
"displayName": "Developer mode, with all features/dependencies enabled",
6464
"binaryDir": "${sourceDir}/build_dev_mode",
65+
"errors": {"dev": true},
6566
"cacheVariables": {
6667
"BUILD_BENCH": "ON",
6768
"BUILD_CLI": "ON",

ci/test/03_test_script.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -118,7 +118,7 @@ BASE_BUILD_DIR=${BASE_BUILD_DIR:-$BASE_SCRATCH_DIR/build-$HOST}
118118
mkdir -p "${BASE_BUILD_DIR}"
119119
cd "${BASE_BUILD_DIR}"
120120

121-
BITCOIN_CONFIG_ALL="$BITCOIN_CONFIG_ALL -DCMAKE_INSTALL_PREFIX=$BASE_OUTDIR"
121+
BITCOIN_CONFIG_ALL="$BITCOIN_CONFIG_ALL -DCMAKE_INSTALL_PREFIX=$BASE_OUTDIR -Werror=dev"
122122

123123
if [[ "${RUN_TIDY}" == "true" ]]; then
124124
BITCOIN_CONFIG_ALL="$BITCOIN_CONFIG_ALL -DCMAKE_EXPORT_COMPILE_COMMANDS=ON"

cmake/tests.cmake

Lines changed: 0 additions & 10 deletions
This file was deleted.

contrib/guix/libexec/build.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -242,6 +242,7 @@ mkdir -p "$DISTSRC"
242242
cmake -S . -B build \
243243
--toolchain "${BASEPREFIX}/${HOST}/toolchain.cmake" \
244244
-DWITH_CCACHE=OFF \
245+
-Werror=dev \
245246
${CONFIGFLAGS}
246247

247248
# Build Bitcoin Core

doc/release-notes-32604.md

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
Logging
2+
-------
3+
Unconditional logging to disk is now rate limited by giving each source location
4+
a quota of 1MiB per hour. Unconditional logging is any logging with a log level
5+
higher than debug, that is `info`, `warning`, and `error`. All logs will be
6+
prefixed with `[*]` if there is at least one source location that is currently
7+
being suppressed. (#32604)
8+
9+
When `-logsourcelocations` is enabled, the log output now contains the entire
10+
function signature instead of just the function name. (#32604)

doc/release-notes-32618.md

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
Wallet
2+
------
3+
4+
* Since descriptor wallets do not allow mixing watchonly and non-watchonly descriptors,
5+
the `include_watchonly` option (and its variants in naming) are removed from all RPCs
6+
that had it.
7+
* The `iswatchonly` field is removed from any RPCs that returned it.

src/addrdb.cpp

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
// Copyright (c) 2009-2010 Satoshi Nakamoto
2-
// Copyright (c) 2009-2022 The Bitcoin Core developers
2+
// Copyright (c) 2009-present The Bitcoin Core developers
33
// Distributed under the MIT software license, see the accompanying
44
// file COPYING or http://www.opensource.org/licenses/mit-license.php.
55

@@ -155,7 +155,7 @@ bool CBanDB::Write(const banmap_t& banSet)
155155
bool CBanDB::Read(banmap_t& banSet)
156156
{
157157
if (fs::exists(m_banlist_dat)) {
158-
LogPrintf("banlist.dat ignored because it can only be read by " CLIENT_NAME " version 22.x. Remove %s to silence this warning.\n", fs::quoted(fs::PathToString(m_banlist_dat)));
158+
LogWarning("banlist.dat ignored because it can only be read by " CLIENT_NAME " version 22.x. Remove %s to silence this warning.", fs::quoted(fs::PathToString(m_banlist_dat)));
159159
}
160160
// If the JSON banlist does not exist, then recreate it
161161
if (!fs::exists(m_banlist_json)) {
@@ -167,15 +167,15 @@ bool CBanDB::Read(banmap_t& banSet)
167167

168168
if (!common::ReadSettings(m_banlist_json, settings, errors)) {
169169
for (const auto& err : errors) {
170-
LogPrintf("Cannot load banlist %s: %s\n", fs::PathToString(m_banlist_json), err);
170+
LogWarning("Cannot load banlist %s: %s", fs::PathToString(m_banlist_json), err);
171171
}
172172
return false;
173173
}
174174

175175
try {
176176
BanMapFromJson(settings[JSON_KEY], banSet);
177177
} catch (const std::runtime_error& e) {
178-
LogPrintf("Cannot parse banlist %s: %s\n", fs::PathToString(m_banlist_json), e.what());
178+
LogWarning("Cannot parse banlist %s: %s", fs::PathToString(m_banlist_json), e.what());
179179
return false;
180180
}
181181

@@ -204,19 +204,19 @@ util::Result<std::unique_ptr<AddrMan>> LoadAddrman(const NetGroupManager& netgro
204204
const auto path_addr{args.GetDataDirNet() / "peers.dat"};
205205
try {
206206
DeserializeFileDB(path_addr, *addrman);
207-
LogPrintf("Loaded %i addresses from peers.dat %dms\n", addrman->Size(), Ticks<std::chrono::milliseconds>(SteadyClock::now() - start));
207+
LogInfo("Loaded %i addresses from peers.dat %dms", addrman->Size(), Ticks<std::chrono::milliseconds>(SteadyClock::now() - start));
208208
} catch (const DbNotFoundError&) {
209209
// Addrman can be in an inconsistent state after failure, reset it
210210
addrman = std::make_unique<AddrMan>(netgroupman, deterministic, /*consistency_check_ratio=*/check_addrman);
211-
LogPrintf("Creating peers.dat because the file was not found (%s)\n", fs::quoted(fs::PathToString(path_addr)));
211+
LogInfo("Creating peers.dat because the file was not found (%s)", fs::quoted(fs::PathToString(path_addr)));
212212
DumpPeerAddresses(args, *addrman);
213213
} catch (const InvalidAddrManVersionError&) {
214214
if (!RenameOver(path_addr, (fs::path)path_addr + ".bak")) {
215215
return util::Error{strprintf(_("Failed to rename invalid peers.dat file. Please move or delete it and try again."))};
216216
}
217217
// Addrman can be in an inconsistent state after failure, reset it
218218
addrman = std::make_unique<AddrMan>(netgroupman, deterministic, /*consistency_check_ratio=*/check_addrman);
219-
LogPrintf("Creating new peers.dat because the file version was not compatible (%s). Original backed up to peers.dat.bak\n", fs::quoted(fs::PathToString(path_addr)));
219+
LogWarning("Creating new peers.dat because the file version was not compatible (%s). Original backed up to peers.dat.bak", fs::quoted(fs::PathToString(path_addr)));
220220
DumpPeerAddresses(args, *addrman);
221221
} catch (const std::exception& e) {
222222
return util::Error{strprintf(_("Invalid or corrupt peers.dat (%s). If you believe this is a bug, please report it to %s. As a workaround, you can move the file (%s) out of the way (rename, move, or delete) to have a new one created on the next start."),
@@ -236,7 +236,7 @@ std::vector<CAddress> ReadAnchors(const fs::path& anchors_db_path)
236236
std::vector<CAddress> anchors;
237237
try {
238238
DeserializeFileDB(anchors_db_path, CAddress::V2_DISK(anchors));
239-
LogPrintf("Loaded %i addresses from %s\n", anchors.size(), fs::quoted(fs::PathToString(anchors_db_path.filename())));
239+
LogInfo("Loaded %i addresses from %s", anchors.size(), fs::quoted(fs::PathToString(anchors_db_path.filename())));
240240
} catch (const std::exception&) {
241241
anchors.clear();
242242
}

0 commit comments

Comments
 (0)