Repository: bitcoin/bitcoin (language: cpp)

Issue:
Transifex translators feedback
This is a tracker for Transifex translators feedback cross-posted from https://www.transifex.com/bitcoin/bitcoin/:

- [ ] https://www.transifex.com/bitcoin/bitcoin/translate/#fr/qt-translation-023x/410183589
https://github.com/bitcoin/bitcoin/blob/03c8c6937ee03787c36ce374c50201f85a0a6c61/src/qt/intro.cpp#L301
> This seems redundant as free space is available space.

- [ ] https://www.transifex.com/bitcoin/bitcoin/translate/#fr/qt-translation-023x/410184314
https://github.com/bitcoin/bitcoin/blob/03c8c6937ee03787c36ce374c50201f85a0a6c61/src/wallet/spend.cpp#L781
> Change as in amount returned from a transaction?

Maybe a better wording could help?

- [ ] https://www.transifex.com/bitcoin/bitcoin/translate/#fr/qt-translation-023x/410184290
https://github.com/bitcoin/bitcoin/blob/03c8c6937ee03787c36ce374c50201f85a0a6c61/src/txdb.cpp#L39
> Rather: "cannot be completed".


Discussion / hints:

Fix patch:
diff --git a/contrib/guix/guix-build b/contrib/guix/guix-build
index 2d44ad036579b..b38f91f3c7bed 100755
--- a/contrib/guix/guix-build
+++ b/contrib/guix/guix-build
@@ -192,7 +192,7 @@ fi
 
 if ! getent services http https ftp > /dev/null 2>&1; then
 cat << EOF
-ERR: Your system's C library can not find service database entries for at least
+ERR: Your system's C library cannot find service database entries for at least
      one of the following services: http, https, ftp.
 
 Hint: Most likely, /etc/services does not exist yet (common for docker images
diff --git a/doc/developer-notes.md b/doc/developer-notes.md
index 188889785686f..bfb64093e19de 100644
--- a/doc/developer-notes.md
+++ b/doc/developer-notes.md
@@ -331,7 +331,7 @@ other input.
   failure, it will throw an exception, which can be caught to recover from the
   error.
    - For example, a nullptr dereference or any other logic bug in RPC code
-     means that the RPC code is faulty and can not be executed. However, the
+     means that the RPC code is faulty and cannot be executed. However, the
      logic bug can be shown to the user and the program can continue to run.
 * `Assume` should be used to document assumptions when program execution can
   safely continue even if the assumption is violated. In debug builds it
@@ -1199,7 +1199,7 @@ A few guidelines for introducing and reviewing new RPC interfaces:
 
 - Don't forget to fill in the argument names correctly in the RPC command table.
 
-  - *Rationale*: If not, the call can not be used with name-based arguments.
+  - *Rationale*: If not, the call cannot be used with name-based arguments.
 
 - Add every non-string RPC argument `(method, idx, name)` to the table `vRPCConvertParams` in `rpc/client.cpp`.
 
diff --git a/src/net.cpp b/src/net.cpp
index bee8710062b36..d5763ee68b662 100644
--- a/src/net.cpp
+++ b/src/net.cpp
@@ -3097,7 +3097,7 @@ void CaptureMessage(const CAddress& addr, const std::string& msg_type, const Spa
     // layer (processing) perspective.
     auto now = GetTime<std::chrono::microseconds>();
 
-    // Windows folder names can not include a colon
+    // Windows folder names cannot include a colon
     std::string clean_addr = addr.ToString();
     std::replace(clean_addr.begin(), clean_addr.end(), ':', '_');
 
diff --git a/src/qt/bitcoin.cpp b/src/qt/bitcoin.cpp
index eb31287c56f94..0e5fd8b72b81b 100644
--- a/src/qt/bitcoin.cpp
+++ b/src/qt/bitcoin.cpp
@@ -509,7 +509,7 @@ int GuiMain(int argc, char* argv[])
         InitError(strprintf(Untranslated("Error parsing command line arguments: %s\n"), error));
         // Create a message box, because the gui has neither been created nor has subscribed to core signals
         QMessageBox::critical(nullptr, PACKAGE_NAME,
-            // message can not be translated because translations have not been initialized
+            // message cannot be translated because translations have not been initialized
             QString::fromStdString("Error parsing command line arguments: %1.").arg(QString::fromStdString(error)));
         return EXIT_FAILURE;
     }
diff --git a/src/qt/intro.cpp b/src/qt/intro.cpp
index e9a4034e62742..dcde7adec4771 100644
--- a/src/qt/intro.cpp
+++ b/src/qt/intro.cpp
@@ -298,7 +298,7 @@ void Intro::setStatus(int status, const QString &message, quint64 bytesAvailable
 
 void Intro::UpdateFreeSpaceLabel()
 {
-    QString freeString = tr("%1 GB of free space available").arg(m_bytes_available / GB_BYTES);
+    QString freeString = tr("%1 GB of space available").arg(m_bytes_available / GB_BYTES);
     if (m_bytes_available < m_required_space_gb * GB_BYTES) {
         freeString += " " + tr("(of %1 GB needed)").arg(m_required_space_gb);
         ui->freeSpace->setStyleSheet("QLabel { color: #800000 }");
diff --git a/src/rpc/misc.cpp b/src/rpc/misc.cpp
index 8d574e0359b94..8d7b48d697df7 100644
--- a/src/rpc/misc.cpp
+++ b/src/rpc/misc.cpp
@@ -426,7 +426,7 @@ static RPCHelpMan setmocktime()
     RPCTypeCheck(request.params, {UniValue::VNUM});
     const int64_t time{request.params[0].get_int64()};
     if (time < 0) {
-        throw JSONRPCError(RPC_INVALID_PARAMETER, strprintf("Mocktime can not be negative: %s.", time));
+        throw JSONRPCError(RPC_INVALID_PARAMETER, strprintf("Mocktime cannot be negative: %s.", time));
     }
     SetMockTime(time);
     auto node_context = util::AnyPtr<NodeContext>(request.context);
diff --git a/src/rpc/rawtransaction.cpp b/src/rpc/rawtransaction.cpp
index ff0d8a4e0feb9..4e14d02998a05 100644
--- a/src/rpc/rawtransaction.cpp
+++ b/src/rpc/rawtransaction.cpp
@@ -380,7 +380,7 @@ static RPCHelpMan verifytxoutproof()
                 RPCResult{
                     RPCResult::Type::ARR, "", "",
                     {
-                        {RPCResult::Type::STR_HEX, "txid", "The txid(s) which the proof commits to, or empty array if the proof can not be validated."},
+                        {RPCResult::Type::STR_HEX, "txid", "The txid(s) which the proof commits to, or empty array if the proof cannot be validated."},
                     }
                 },
                 RPCExamples{""},
diff --git a/src/txdb.cpp b/src/txdb.cpp
index 5e4379a60a478..9a39e90ccd16a 100644
--- a/src/txdb.cpp
+++ b/src/txdb.cpp
@@ -36,7 +36,7 @@ std::optional<bilingual_str> CheckLegacyTxindex(CBlockTreeDB& block_tree_db)
 {
     CBlockLocator ignored{};
     if (block_tree_db.Read(DB_TXINDEX_BLOCK, ignored)) {
-        return _("The -txindex upgrade started by a previous version can not be completed. Restart with the previous version or run a full -reindex.");
+        return _("The -txindex upgrade started by a previous version cannot be completed. Restart with the previous version or run a full -reindex.");
     }
     bool txindex_legacy_flag{false};
     block_tree_db.ReadFlag("txindex", txindex_legacy_flag);
diff --git a/src/validation.cpp b/src/validation.cpp
index b7a4002e48120..12d29c8d5e1f1 100644
--- a/src/validation.cpp
+++ b/src/validation.cpp
@@ -2071,7 +2071,7 @@ bool CChainState::ConnectBlock(const CBlock& block, BlockValidationState& state,
     fEnforceBIP30 = fEnforceBIP30 && (!pindexBIP34height || !(pindexBIP34height->GetBlockHash() == m_params.GetConsensus().BIP34Hash));
 
     // TODO: Remove BIP30 checking from block height 1,983,702 on, once we have a
-    // consensus change that ensures coinbases at those heights can not
+    // consensus change that ensures coinbases at those heights cannot
     // duplicate earlier coinbases.
     if (fEnforceBIP30 || pindex->nHeight >= BIP34_IMPLIES_BIP30_LIMIT) {
         for (const auto& tx : block.vtx) {
diff --git a/src/wallet/rpc/encrypt.cpp b/src/wallet/rpc/encrypt.cpp
index 2b6a2a198dc1f..802cc63d6dba2 100644
--- a/src/wallet/rpc/encrypt.cpp
+++ b/src/wallet/rpc/encrypt.cpp
@@ -66,7 +66,7 @@ RPCHelpMan walletpassphrase()
         }
 
         if (strWalletPass.empty()) {
-            throw JSONRPCError(RPC_INVALID_PARAMETER, "passphrase can not be empty");
+            throw JSONRPCError(RPC_INVALID_PARAMETER, "passphrase cannot be empty");
         }
 
         if (!pwallet->Unlock(strWalletPass)) {
@@ -139,7 +139,7 @@ RPCHelpMan walletpassphrasechange()
     strNewWalletPass = request.params[1].get_str().c_str();
 
     if (strOldWalletPass.empty() || strNewWalletPass.empty()) {
-        throw JSONRPCError(RPC_INVALID_PARAMETER, "passphrase can not be empty");
+        throw JSONRPCError(RPC_INVALID_PARAMETER, "passphrase cannot be empty");
     }
 
     if (!pwallet->ChangeWalletPassphrase(strOldWalletPass, strNewWalletPass)) {
@@ -236,7 +236,7 @@ RPCHelpMan encryptwallet()
     strWalletPass = request.params[0].get_str().c_str();
 
     if (strWalletPass.empty()) {
-        throw JSONRPCError(RPC_INVALID_PARAMETER, "passphrase can not be empty");
+        throw JSONRPCError(RPC_INVALID_PARAMETER, "passphrase cannot be empty");
     }
 
     if (!pwallet->EncryptWallet(strWalletPass)) {
diff --git a/src/wallet/spend.cpp b/src/wallet/spend.cpp
index 3d8ae2da69d58..83eaececc1399 100644
--- a/src/wallet/spend.cpp
+++ b/src/wallet/spend.cpp
@@ -778,7 +778,7 @@ static bool CreateTransactionInternal(
     }
     else if ((unsigned int)nChangePosInOut > txNew.vout.size())
     {
-        error = _("Change index out of range");
+        error = _("Transaction change output index out of range");
         return false;
     }
 


Test patch:
diff --git a/src/test/util_tests.cpp b/src/test/util_tests.cpp
index 52b24327eca29..d2638e221a12b 100644
--- a/src/test/util_tests.cpp
+++ b/src/test/util_tests.cpp
@@ -1286,7 +1286,7 @@ BOOST_AUTO_TEST_CASE(util_ParseMoney)
     BOOST_CHECK_EQUAL(ParseMoney("0.00000001 ").value(), COIN/100000000);
     BOOST_CHECK_EQUAL(ParseMoney(" 0.00000001").value(), COIN/100000000);
 
-    // Parsing amount that can not be represented should fail
+    // Parsing amount that cannot be represented should fail
     BOOST_CHECK(!ParseMoney("100000000.00"));
     BOOST_CHECK(!ParseMoney("0.000000001"));
 
diff --git a/test/functional/feature_txindex_compatibility.py b/test/functional/feature_txindex_compatibility.py
index bbe1d1b537115..20b023d82c0b4 100755
--- a/test/functional/feature_txindex_compatibility.py
+++ b/test/functional/feature_txindex_compatibility.py
@@ -78,7 +78,7 @@ def run_test(self):
 
         self.stop_nodes()
 
-        self.log.info("Check migrated txindex can not be read by legacy node")
+        self.log.info("Check migrated txindex cannot be read by legacy node")
         err_msg = f": You need to rebuild the database using -reindex to change -txindex.{os.linesep}Please restart with -reindex or -reindex-chainstate to recover."
         shutil.rmtree(legacy_chain_dir)
         shutil.copytree(migrate_chain_dir, legacy_chain_dir)
diff --git a/test/functional/rpc_decodescript.py b/test/functional/rpc_decodescript.py
index 56f596d4199d4..343cb739896d6 100755
--- a/test/functional/rpc_decodescript.py
+++ b/test/functional/rpc_decodescript.py
@@ -52,7 +52,7 @@ def decodescript_script_sig(self):
         rpc_result = self.nodes[0].decodescript('5100')
         assert_equal('1 0', rpc_result['asm'])
 
-        # null data scriptSig - no such thing because null data scripts can not be spent.
+        # null data scriptSig - no such thing because null data scripts cannot be spent.
         # thus, no test case for that standard transaction type is here.
 
     def decodescript_script_pub_key(self):
diff --git a/test/functional/rpc_uptime.py b/test/functional/rpc_uptime.py
index 1a82d1fa41c59..024e8aec1a39d 100755
--- a/test/functional/rpc_uptime.py
+++ b/test/functional/rpc_uptime.py
@@ -23,7 +23,7 @@ def run_test(self):
         self._test_uptime()
 
     def _test_negative_time(self):
-        assert_raises_rpc_error(-8, "Mocktime can not be negative: -1.", self.nodes[0].setmocktime, -1)
+        assert_raises_rpc_error(-8, "Mocktime cannot be negative: -1.", self.nodes[0].setmocktime, -1)
 
     def _test_uptime(self):
         wait_time = 10
diff --git a/test/functional/wallet_encryption.py b/test/functional/wallet_encryption.py
index 0d702e44f6e4b..0c9106f8009a9 100755
--- a/test/functional/wallet_encryption.py
+++ b/test/functional/wallet_encryption.py
@@ -35,14 +35,14 @@ def run_test(self):
         assert_raises_rpc_error(-15, "Error: running with an unencrypted wallet, but walletpassphrasechange was called.", self.nodes[0].walletpassphrasechange, 'ff', 'ff')
 
         # Encrypt the wallet
-        assert_raises_rpc_error(-8, "passphrase can not be empty", self.nodes[0].encryptwallet, '')
+        assert_raises_rpc_error(-8, "passphrase cannot be empty", self.nodes[0].encryptwallet, '')
         self.nodes[0].encryptwallet(passphrase)
 
         # Test that the wallet is encrypted
         assert_raises_rpc_error(-13, "Please enter the wallet passphrase with walletpassphrase first", self.nodes[0].signmessage, address, msg)
         assert_raises_rpc_error(-15, "Error: running with an encrypted wallet, but encryptwallet was called.", self.nodes[0].encryptwallet, 'ff')
-        assert_raises_rpc_error(-8, "passphrase can not be empty", self.nodes[0].walletpassphrase, '', 1)
-        assert_raises_rpc_error(-8, "passphrase can not be empty", self.nodes[0].walletpassphrasechange, '', 'ff')
+        assert_raises_rpc_error(-8, "passphrase cannot be empty", self.nodes[0].walletpassphrase, '', 1)
+        assert_raises_rpc_error(-8, "passphrase cannot be empty", self.nodes[0].walletpassphrasechange, '', 'ff')
 
         # Check that walletpassphrase works
         self.nodes[0].walletpassphrase(passphrase, 2)
diff --git a/test/functional/wallet_timelock.py b/test/functional/wallet_timelock.py
index cf233a00effd0..a71cec6607dee 100755
--- a/test/functional/wallet_timelock.py
+++ b/test/functional/wallet_timelock.py
@@ -30,7 +30,7 @@ def run_test(self):
         )
         self.generate(node, 1)
 
-        self.log.info("Check that clock can not change finality of confirmed txs")
+        self.log.info("Check that clock cannot change finality of confirmed txs")
         amount_before_ad = node.getreceivedbyaddress(address)
         amount_before_lb = node.getreceivedbylabel(label)
         list_before_ad = node.listreceivedbyaddress(address_filter=address)
diff --git a/test/util/test_runner.py b/test/util/test_runner.py
index aa8fd6eee5982..a7fc3b1dc1ee5 100755
--- a/test/util/test_runner.py
+++ b/test/util/test_runner.py
@@ -93,7 +93,7 @@ def bctest(testDir, testObj, buildenv):
         try:
             outputData = open(os.path.join(testDir, outputFn), encoding="utf8").read()
         except:
-            logging.error("Output file " + outputFn + " can not be opened")
+            logging.error("Output file " + outputFn + " cannot be opened")
             raise
         if not outputData:
             logging.error("Output data missing for " + outputFn)