Skip to content

Commit bebbdd0

Browse files
committed
compute: count fuel-test output through the container
A per-record `inspect` needs `&Container: IntoIterator`, and on macOS resolving that recurses through `objc2`'s blanket impls until the trait solver overflows, so `lint-macos` fails to compile the test. Counting through the container avoids the resolution entirely. The same test reads the container directly from the commit that makes FlatMap's output columnar onward, so this only closes the window where it did not.
1 parent 2ca573d commit bebbdd0

1 file changed

Lines changed: 10 additions & 1 deletion

File tree

‎src/compute/src/render/flat_map.rs‎

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -330,6 +330,7 @@ mod tests {
330330
use mz_expr::MapFilterProject;
331331
use mz_repr::{Datum, ReprScalarType};
332332
use timely::dataflow::operators::Inspect;
333+
use timely::dataflow::operators::InspectCore;
333334
use timely::dataflow::operators::capture::{Capture, Extract};
334335

335336
use super::*;
@@ -370,7 +371,15 @@ mod tests {
370371
let scope = stream.scope();
371372
let (oks, _errs) =
372373
flat_map_stage(stream, scope, exprs, func, mfp, Antichain::new(), budget);
373-
oks.inspect(move |_| *sink.borrow_mut() += 1);
374+
// Count through the container rather than per record. A
375+
// per-record `inspect` needs `&Container: IntoIterator`, and
376+
// resolving that on macOS recurses through `objc2`'s blanket
377+
// impls until the trait solver overflows.
378+
oks.inspect_container(move |event| {
379+
if let Ok((_time, data)) = event {
380+
*sink.borrow_mut() += data.len();
381+
}
382+
});
374383
input
375384
});
376385

0 commit comments

Comments
 (0)