Conversation
When a delayed (lazy) series is printed, show the key range [lo .. hi] instead of the opaque '(Suppressed)' message. This implements the suggestion in #65. The key range is available from DelayedIndex.KeyRange = (source.RangeMin, source.RangeMax) without triggering data loading. Before: series [ (Suppressed)] After: series [ (Delayed series [2000-01-01 .. 2023-12-31])] A try/with guard keeps backward compatibility for any edge case where the key range is not accessible. Closes #65 Co-authored-by: Copilot <[email protected]>
9 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🤖 Repo Assist — addressing a long-standing usability issue with delayed/lazy series display.
Summary
When a delayed (lazy) series was printed (in FSI,
ToString(), orFormat()), it showed the opaque string(Suppressed), which gave users no useful information about the series they had just created.Before:
Root Cause
DelayedVector.SuppressPrintingreturnstrueto prevent data loading during printing. The printing code inSeries.fsbranched on this flag but simply showed"(Suppressed)". However, the key range is already available inDelayedIndex.KeyRangewhich returns(source.RangeMin, source.RangeMax)— both set at construction time, with no data loading required.Fix
In
Series.ToString()andSeries.FormatStrings(), whenvector.SuppressPrintingis true, accessseries.KeyRangeto get the[lo .. hi]bounds and format a descriptive message. Atry/withguard preserves backward compatibility for any edge case.Changes
src/Deedle/Series.fs: two one-line-to-four-line improvements inToString()andFormatStrings()Test Status
✅ Build succeeded
✅ All 670 tests pass (
dotnet test tests/Deedle.Tests/Deedle.Tests.fsproj -c Release)