Skip to content
This repository was archived by the owner on Oct 10, 2025. It is now read-only.

Conversation

@anvanster
Copy link

The toString() method in MaterializedQueryResult was incorrectly using the shared class member 'iterator' instead of the local 'iterator_' variable. This caused the shared iterator to be exhausted whenever toString() was called (e.g., when using Display trait in Rust).

This made the QueryResult unusable for iteration after any display/print operation, causing the iterator to hang or return no results.

Changed:

  • iterator->hasNext() to iterator_.hasNext()
  • iterator->getNext() to iterator_.getNext()

This ensures toString() uses its own local iterator without affecting the shared iterator used by the Rust bindings.

Fixes the issue where Rust QueryResult iterator would hang after Display.

The toString() method in MaterializedQueryResult was incorrectly using
the shared class member 'iterator' instead of the local 'iterator_'
variable. This caused the shared iterator to be exhausted whenever
toString() was called (e.g., when using Display trait in Rust).

This made the QueryResult unusable for iteration after any display/print
operation, causing the iterator to hang or return no results.

Changed:
- iterator->hasNext() to iterator_.hasNext()
- iterator->getNext() to iterator_.getNext()

This ensures toString() uses its own local iterator without affecting
the shared iterator used by the Rust bindings.

Fixes the issue where Rust QueryResult iterator would hang after Display.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant