Skip to content

Commit

Permalink
fix: clean up some non-datafusion builds
Browse files Browse the repository at this point in the history
Not sure when this regressed but the lack of datafusion broke the core
build

error[E0432]: unresolved import `crate::delta_datafusion`
 --> crates/core/src/operations/transaction/conflict_checker.rs:5:12
  |
5 | use crate::delta_datafusion::DataFusionMixins;
  |            ^^^^^^^^^^^^^^^^ could not find `delta_datafusion` in the crate root

error[E0700]: hidden type for `impl Iterator<Item = actions::Add>` captures lifetime that does not appear in bounds
   --> crates/core/src/operations/transaction/conflict_checker.rs:196:9
    |
109 | impl<'a> TransactionInfo<'a> {
    |      -- hidden type `impl Iterator<Item = actions::Add> + 'a` captures the lifetime `'a` as defined here
...
195 |     pub fn read_files(&self) -> Result<impl Iterator<Item = Add>, CommitConflictError> {
    |                                        ------------------------- opaque type defined here
196 |         Ok(self.read_snapshot.file_actions().unwrap().into_iter())
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

Some errors have detailed explanations: E0432, E0700.
  • Loading branch information
rtyler committed Mar 19, 2024
1 parent f32779d commit b001186
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion crates/core/src/operations/transaction/conflict_checker.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
use std::collections::HashSet;

use super::CommitInfo;
#[cfg(feature = "datafusion")]
use crate::delta_datafusion::DataFusionMixins;
use crate::errors::DeltaResult;
use crate::kernel::EagerSnapshot;
Expand Down Expand Up @@ -192,7 +193,7 @@ impl<'a> TransactionInfo<'a> {

#[cfg(not(feature = "datafusion"))]
/// Files read by the transaction
pub fn read_files(&self) -> Result<impl Iterator<Item = Add>, CommitConflictError> {
pub fn read_files(&self) -> Result<impl Iterator<Item = Add> + '_, CommitConflictError> {
Ok(self.read_snapshot.file_actions().unwrap().into_iter())
}

Expand Down

0 comments on commit b001186

Please sign in to comment.