You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
FC_ASSERT(first_log_first_block_num == second_log_first_block_num, "Difference found when between comparing starting block number in given block logs.\n"
351
+
FC_ASSERT(first_log_first_block_num == second_log_first_block_num, "Difference found when comparing starting block number in given block logs.\n"
352
352
"First block_log: ${first_filename}, first block number in block_log: ${first_tail_block_num}, first block number to compare: ${first_log_first_block_num},\n"
353
353
"Second block_log: ${second_filename}, first block number in block_log: ${second_tail_block_num}, first block number to compare: ${second_log_first_block_num}.",
FC_ASSERT(first_log_last_block_num == second_log_last_block_num, "Difference found between comparing ending block number in given block logs.\n"
356
+
FC_ASSERT(first_log_last_block_num == second_log_last_block_num, "Difference found comparing ending block number in given block logs.\n"
357
357
"First block_log: ${first_filename}, head block number in block_log: ${first_head_block_num}, last block number to compare: ${first_log_last_block_num},\n"
358
358
"Second block_log: ${second_filename}, head block number in block_log: ${second_head_block_num}, last block number to compare: ${second_log_last_block_num}.",
FC_ASSERT(max_files_limit >= part_count, "Requested to create more files: ${part_count} than it's possible: ${max_files_limit} from given block_log with specific parameters", (part_count)(max_files_limit));
merge_block_logs_options.add_options()("input,i", boost::program_options::value<boost::filesystem::path>()->value_name("directory"), "Directory which contains split throughout the file block_log. Can be the same as --output");
939
-
merge_block_logs_options.add_options()("output,o", boost::program_options::value<boost::filesystem::path>()->value_name("directory"), "Directory where new block_log file, created from input splitted block_logs, should be created. Can be the same as --input");
940
-
merge_block_logs_options.add_options()("block-number,n", boost::program_options::value<int32_t>()->value_name("n"), "Merge block_log files up to given block number (inclusive). Negative numbers mean distance from end (-1 is head block of last splitted block_log). Defaults to -1.");
954
+
merge_block_logs_options.add_options()("input,i", boost::program_options::value<boost::filesystem::path>()->value_name("directory"), "Directory containing split block log part files to be merged. Can be the same as --output");
955
+
merge_block_logs_options.add_options()("output,o", boost::program_options::value<boost::filesystem::path>()->value_name("directory"), "Directory where merged block log fileshould be created.. Can be the same as --input");
956
+
merge_block_logs_options.add_options()("block-number,n", boost::program_options::value<int32_t>()->value_name("n"), "Merge block_log files up to given block number (inclusive). Negative numbers mean distance from end (-1 is head block of last split block_log). Defaults to -1.");
@@ -985,10 +1001,10 @@ int main(int argc, char **argv)
985
1001
{
986
1002
std::string info = "Split block_log file from given block number (exclusive). Block number must be multiplicity of " + std::to_string(BLOCKS_IN_SPLIT_BLOCK_LOG_FILE) + ". Defaults to 0.";
info = "Split block_log file to given block number (inclusive). Block number must be multiplicity of " + std::to_string(BLOCKS_IN_SPLIT_BLOCK_LOG_FILE) + ". Defaults to head_block_number.";
1004
+
info = "Split block_log file to given block number (inclusive). Negative numbers mean distance from end (-1 is head block). Defaults to -1.";
info = "Number of files which will be created. Every block_log file will contain " + std::to_string(BLOCKS_IN_SPLIT_BLOCK_LOG_FILE) + " blocks. Cannot be used together with both from and to."
991
-
"If --from or nothing specified, tool will create c files from block m, if --to specified, it will create c files to block m. Negative numbers mean distance from end (-1 is file contains head block).";
1007
+
"If --from or nothing specified, tool will create c files from block m, if --to specified, it will create c files to block m. Negative numbers mean distance from end (-1 is file contains head block, but cannot be used with --from or --to).";
@@ -1103,7 +1119,7 @@ int main(int argc, char **argv)
1103
1119
update_options_map(merge_block_logs_options);
1104
1120
options_map.erase("merge-block-logs");
1105
1121
1106
-
FC_ASSERT(options_map.count("input") && options_map.count("output"), "input directory with splitted block_log and output directory for new block_log must be specified");
1122
+
FC_ASSERT(options_map.count("input") && options_map.count("output"), "input directory with split block_log and output directory for new block_log must be specified");
FC_ASSERT(!from_given && !to_given, "if --files-count is negative, cannot use --from or --to");
1268
1278
}
1269
1279
1270
-
FC_ASSERT(first_block == 1 || first_block % BLOCKS_IN_SPLIT_BLOCK_LOG_FILE == 0, "first block should be 1 or multiplicity of BLOCKS_IN_SPLIT_BLOCK_LOG_FILE");
1271
-
FC_ASSERT(last_block == -1 || last_block % BLOCKS_IN_SPLIT_BLOCK_LOG_FILE == 0, "last block should be -1 (head_block) or multiplicity of BLOCKS_IN_SPLIT_BLOCK_LOG_FILE");
FC_ASSERT(first_block > 0 && (first_block == 1 || first_block % BLOCKS_IN_SPLIT_BLOCK_LOG_FILE == 0), "first block should be 1 or multiplicity of BLOCKS_IN_SPLIT_BLOCK_LOG_FILE");
1272
1282
FC_ASSERT(options_map.count("output-dir"), "output_dir is necessary when splitting block_log in order to know where new block_log files should be stored.");
0 commit comments