Browse Source

Documentation cleanup

pull/245/head
Eirik0 5 years ago
parent
commit
699288b4b4
  1. 2
      qa/rpc-tests/sprout_sapling_migration.py
  2. 2
      src/wallet/asyncrpcoperation_saplingmigration.cpp
  3. 18
      src/wallet/rpcwallet.cpp

2
qa/rpc-tests/sprout_sapling_migration.py

@ -41,7 +41,7 @@ class SproutSaplingMigration(BitcoinTestFramework):
assert_equal(self.nodes[0].z_getbalance(saplingAddr), Decimal('0'))
# Migrate
assert_equal(True, self.nodes[0].z_setmigration(True))
self.nodes[0].z_setmigration(True)
print "Mining to block 494..."
self.nodes[0].generate(392) # 102 -> 494
self.sync_all()

2
src/wallet/asyncrpcoperation_saplingmigration.cpp

@ -169,7 +169,7 @@ libzcash::SaplingPaymentAddress AsyncRPCOperation_saplingmigration::getMigration
// Derive m/32'/coin_type'
auto m_32h_cth = m_32h.Derive(bip44CoinType | ZIP32_HARDENED_KEY_LIMIT);
// Derive account key at next index, skip keys already known to the wallet
// Derive m/32'/coin_type'/0'
libzcash::SaplingExtendedSpendingKey xsk = m_32h_cth.Derive(0 | ZIP32_HARDENED_KEY_LIMIT);
libzcash::SaplingPaymentAddress toAddress = xsk.DefaultAddress();

18
src/wallet/rpcwallet.cpp

@ -3913,20 +3913,20 @@ UniValue z_setmigration(const UniValue& params, bool fHelp) {
throw runtime_error(
"z_setmigration enabled\n"
"When enabled the Sprout to Sapling migration will attempt to migrate all funds from this wallet’s\n"
"Sprout addresses to either the address for Sapling account 0 or one specified by the parameter\n"
"'-migrationdestaddress'. This migration is designed to minimize information leakage. As a result,\n"
"for wallets with a significant Sprout balance, this process may take several weeks. The migration\n"
"works by sending, up to 5, as many transactions as possible whenever the blockchain reaches a height\n"
"equal to 499 modulo 500. The transaction amounts are picked according to the random distribution\n"
"specified in ZIP 308. The migration will end once the wallet’s Sprout balance is below 0.01 " + CURRENCY_UNIT + ".\n"
"Sprout addresses to either the address for Sapling account 0 or the address specified by the parameter\n"
"'-migrationdestaddress'.\n"
"\n"
"This migration is designed to minimize information leakage. As a result for wallets with a significant\n"
"Sprout balance, this process may take several weeks. The migration works by sending, up to 5, as many\n"
"transactions as possible whenever the blockchain reaches a height equal to 499 modulo 500. The transaction\n"
"amounts are picked according to the random distribution specified in ZIP 308. The migration will end once\n"
"the wallet’s Sprout balance is below" + strprintf("%s %s", FormatMoney(CENT), CURRENCY_UNIT) + ".\n"
"\nArguments:\n"
"1. enabled (boolean, required) 'true' or 'false' to enable or disable respectively.\n"
"\nResult:\n"
"enabled (boolean) Whether or not migration is enabled (echos the argument).\n"
);
LOCK(pwalletMain->cs_wallet);
pwalletMain->fSaplingMigrationEnabled = params[0].get_bool();
return pwalletMain->fSaplingMigrationEnabled;
return NullUniValue;
}
/**

Loading…
Cancel
Save