iterfzf is a Pythonic interface to fzf, a command-line fuzzy finder. It allows consuming iterables of strings and displaying them using fzf for interactive selection, returning the user's choice(s). Notably, it consumes iterables lazily, which is efficient for large or streamed inputs. The current version is 1.9.0.67.0, released on January 24, 2026, and bundles a prebuilt fzf binary for convenience. The library supports Python 3.8 and higher.
pip install iterfzfVerified import paths — ran on the pinned version, not inferred.
This example demonstrates how to use `iterfzf` to present a list of items for interactive fuzzy selection. It shows how to enable multi-selection and how to catch the `KeywordInterrupt` exception if the user cancels the selection (e.g., by pressing Escape).
Upgrade to Python 3.8 or newer, or pin iterfzf to a version less than 1.0 (e.g., `iterfzf<1.0`).
Ensure all options like `multi`, `header`, `prompt`, etc., are passed as keyword arguments.
Ensure all elements in the iterable are consistently of `str` or `bytes` type. If working with dictionary items, convert them to strings (e.g., `[f'{k}: {v}' for k, v in d.items()]`).Wrap calls to `iterfzf` in a `try...except KeywordInterrupt:` block to gracefully handle user cancellations.
When checking for updates or compatibility, understand that changes to the bundled `fzf` version are reflected in the patch segment of `iterfzf`'s full version string.
Ensure all elements in the input iterable are consistently of `str` (Unicode) or `bytes` type. If working with dictionary items, convert them to strings (e.g., `[f'{k}: {v}' for k, v in d.items()]`).Pass all `iterfzf()` options as keyword arguments (e.g., `iterfzf(items, multi=True)` instead of `iterfzf(items, True)`).
Wrap calls to `iterfzf` in a `try...except iterfzf.KeywordInterrupt:` block to gracefully handle user cancellations. You may also need to `from iterfzf import KeywordInterrupt`.
No dependency data recorded yet.