Skip to content

Prediction Source "History" does not use all of the PSReadline history #5014

@nebula-it

Description

@nebula-it

Prerequisites

  • Write a descriptive title.
  • Make sure you are able to repro it on the latest released version
  • Search the existing issues, especially the pinned issues.

Exception report

N/A

Screenshot

N/A

Environment data

PS Version: 7.5.4
PS HostName: ConsoleHost (Windows Terminal)
PSReadLine Version: 2.4.5
PSReadLine EditMode: Windows
OS: 10.0.26100.1 (WinBuild.160101.0800)
BufferWidth: 133
BufferHeight: 38

Steps to reproduce

  1. Set Set-PSReadLineOption -MaximumHistoryCount 200000
  2. Not so sure how to arbitrarily fill the history but you need to ensure your history at (cat (get-psreadLineOption).HistorySavePath | Measure-Object).Count is over 5128
  3. Get the first item from history cat (get-psreadLineOption).HistorySavePath -First 1
  4. Start typing the string from Step 3 in powershell, the history predictor does not show up anything even thought the item is already in PSReadline history

Expected behavior

The step 4 above should show the item from PSReadline history

Actual behavior

The step 4 above does not show the item from PSReadline history. It seems like the last item it will be show is (Current History Count)-5127

Metadata

Metadata

Assignees

No one assigned

    Labels

    Needs-Triage 🔍It's a new issue that core contributor team needs to triage.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions