Skip to content

Commit

Permalink
Minor lints
Browse files Browse the repository at this point in the history
  • Loading branch information
nyurik committed Jul 11, 2024
1 parent d446542 commit b3a0656
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 2 deletions.
1 change: 0 additions & 1 deletion docs/src/config-file.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,6 @@ keep_alive: 75
# The socket address to bind [default: 0.0.0.0:3000]
listen_addresses: '0.0.0.0:3000'


# Set TileJSON URL path prefix, ignoring X-Rewrite-URL header. Must begin with a `/`
base_path: /tiles

Expand Down
4 changes: 3 additions & 1 deletion mbtiles/src/bindiff.rs
Original file line number Diff line number Diff line change
Expand Up @@ -133,7 +133,9 @@ fn start_processor_threads<S: Send + 'static, T: Send + 'static, P: BinDiffer<S,
tx_ins: Sender<T>,
has_errors: Arc<AtomicBool>,
) {
(0..num_cpus::get()).for_each(|_| {
let cpus = num_cpus::get();
info!("Processing bindiff patches using {cpus} threads...");
(0..cpus).for_each(|_| {
let rx_wrk = rx_wrk.clone();
let tx_ins = tx_ins.clone();
let has_errors = has_errors.clone();
Expand Down
4 changes: 4 additions & 0 deletions tests/test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -470,11 +470,15 @@ if [[ "$MBTILES_BIN" != "-" ]]; then
"$TEST_TEMP_DIR/world_cities_bindiff.mbtiles" \
--patch-type bin-diff-gz \
2>&1 | tee "$TEST_OUT_DIR/copy_bindiff.txt"
test_log_has_str "$TEST_OUT_DIR/copy_bindiff.txt" '.*Processing bindiff patches using .* threads...'

$MBTILES_BIN copy \
./tests/fixtures/mbtiles/world_cities.mbtiles \
--apply-patch "$TEST_TEMP_DIR/world_cities_bindiff.mbtiles" \
"$TEST_TEMP_DIR/world_cities_modified2.mbtiles" \
2>&1 | tee "$TEST_OUT_DIR/copy_bindiff2.txt"
test_log_has_str "$TEST_OUT_DIR/copy_bindiff2.txt" '.*Processing bindiff patches using .* threads...'

# Ensure that world_cities_modified and world_cities_modified2 are identical (regular diff is empty)
$MBTILES_BIN copy \
./tests/fixtures/mbtiles/world_cities_modified.mbtiles \
Expand Down

0 comments on commit b3a0656

Please sign in to comment.