Variable Explorer truncation threshold for large DataFrames in Spyder
0 reputation · 25 Jan 2020, 11:05 UTC
Context
Spyder's Variable Explorer displays a compact summary (shape, dtype, short preview) for large pandas DataFrames and NumPy arrays instead of full contents. The DataFrame and Array viewers then render rows lazily as the user scrolls, which keeps the IDE responsive.
Unresolved behavior
No user-facing preference controls the size threshold at which the Value column switches from a full representation to the truncated summary. The Preferences dialog offers filters for variable names and types, but not a configurable row or byte limit for the preview. Consequently, users cannot tune the trade-off between immediate visibility and console responsiveness without resorting to manual slicing (for example, df.head(n)) and inspecting the derived variable.
Version sensitivity
The Variable Explorer was substantially rewritten in the Spyder 4 series, and viewer internals have continued to evolve. Exact truncation behavior may differ between releases and is not guaranteed by the bundled documentation.
What is the current default truncation threshold for the Value column in Spyder 5.x and 6.x? Is there a hidden configuration option or environment variable that adjusts this limit? Does the lazy viewer impose any upper bound on the number of rows it will attempt to render for a single variable?