Skip to content

fix: address the four alpha1 field reports - #32

Merged
HelloThisWorld merged 1 commit into
mainfrom
fix/alpha1-feedback
Aug 4, 2026
Merged

fix: address the four alpha1 field reports#32
HelloThisWorld merged 1 commit into
mainfrom
fix/alpha1-feedback

Conversation

@HelloThisWorld

Copy link
Copy Markdown
Owner

Summary

Fixes the four issues reported from local v1.3.0-alpha1 testing, ahead of
the 1.3.0 beta. Version metadata is unchanged; this is a source-only fix PR.

# Report Fix
1 The Timeline handle covered terminal content The floating 28×48 button is now a 6 px strip flush against the terminal's left edge, auto-hiding-scrollbar style; it widens to 20 px and shows its chevron on hover, keyboard focus, or while the overlay is open
2 Clicking the terminal did not close an open Timeline A pointer press on the terminal grid now light-dismisses the overlay and still continues into the terminal; presses on the overlay itself are unaffected
3 dir left the progress bar animating forever Three recognition defects fixed (below)
4 Typed commands never appeared in the Timeline Bare PowerShell profile commandlines now auto-import the packaged winTerm.Shell module, so OSC 133 marks work out of the box

Detailed changes

3 — Visual Progress stuck bar (src/winterm/VisualProgress/ProgressRecognition.h)

  • _matchGradle claimed ownership from a bare product-name mention — a dir
    listing entry such as .gradle — and, once claimed, rematched every later
    record
    through an unconditional stage fallback, so prompts and echoes kept
    refreshing an indeterminate bar forever. Each record now needs build-tool
    evidence of its own: a status meter with a real value (75% EXECUTING), a
    wrapper download, or a > Task line. The existing fixtures for all three
    still classify as Gradle.
  • A still-running built-in provider bar was never structurally cleared when
    its stream moved on (only Generic was). The engine now tolerates one
    ordinary record — so an informational line inside a live meter stream does
    not blank the bar — and publishes a structural clear on the second
    consecutive
    ordinary record. Success/Error results still persist, and
    progress-shaped records that deliberately keep a live claim do not advance
    the count.
  • _findIntegerFraction read slashed dates (2025/10/1310/13 → 76 %) as
    completed/total meters, so every short-date dir line flashed a determinate
    bar. A digit/digit/digit chain is now rejected; real N/M meters are
    unaffected.

One existing test expectation changed accordingly: in
RecognitionPreservesHighConfidenceOwnershipAndClearsGeneric, the stale wget
shape after ownership expiry now yields the structural clear publication
(provider None, hidden, not visible) instead of leaving the dangling wget bar
running — which was this same bug class.

4 — Shell integration out of the box

docs/powershell-integration.md documented a launcher contract, but nothing in
the product ever performed it, so a fresh install had no OSC 133 marks and the
Timeline stayed empty. Now:

  • src/winterm/Shell/AutoIntegration.h (new, header-only, unit-tested):
    recognizes only powershell.exe / pwsh.exe by basename; tolerates only
    -NoLogo and -NoExit; refuses -Command, -File, -EncodedCommand,
    -NoProfile, -ExecutionPolicy, and every other customization; refuses
    quote characters in the manifest path or session id; refuses an
    already-rewritten commandline (restarted connections reuse theirs).
  • TerminalPage::_CreateConnectionFromSettings appends
    -NoExit -Command "&{ $env:WINTERM_SESSION_ID='…'; $env:WINTERM_INTEGRATION_VERSION='1'; Import-Module -Name '…' -ErrorAction SilentlyContinue }"
    when the packaged manifest exists next to the executable. Execution policy is
    never altered; an import failure leaves a working shell without integration.
  • New per-profile setting "shellIntegration.autoInject" (default true),
    plumbed through MTSMSettings.h / Profile.idl and documented in
    profiles.schema.json.

With the module imported, the module emits 133;A, 9;9, 133;B, 133;D,
and the inherited autoMarkPrompts behavior supplies the command-executed
transition — the exact supported path the Timeline was built against.

1 + 2 — TermControl

  • TermControl.xaml: handle is Width="6", Margin="0", flush left, rounded
    on the right only, icon collapsed at rest.
  • _updateCommandTimelineHandleVisual() centralizes the expand/collapse rule;
    pointer enter/exit and focus handlers drive it, and open/close pass through
    it. Automation name, tooltip, and glyph behavior are unchanged.
  • _PointerPressedHandler closes an open overlay when the press is not over
    it, then continues normal terminal input handling.
  • test-command-timeline.ps1 guards updated: the auto-hiding handle markup and
    the light-dismiss condition are now asserted; the stale Margin="8,0,0,0"
    assertion is gone.

Validation performed

Environment: Windows 11 Pro 26100, MSVC 14.44.35207, Windows SDK 10.0.26100.0.

Compiled tests — ran, passed

Suite Result
SettingsModel winTerm classes (WinTermVisualProgress + WinTermShell + WinTermCommandTimeline) Total=44, Passed=44, Failed=0
CommandTimelineTests (Control) Total=43, Passed=43, Failed=0

New tests: RecognitionIgnoresProductMentionsInListings,
RecognitionClearsStaleRunningProviderAfterOrdinaryRecords,
AutoIntegrationRewritesBarePowerShellCommandlines,
AutoIntegrationRefusesCustomizedOrUnsafeInput.

Builds — ran, clean

Project Result
SettingsModel.UnitTests x64 Release exit 0
Control.UnitTests x64 Release (includes Microsoft.Terminal.Control.Lib with the TermControl changes) exit 0
TerminalAppLib x64 Release (includes TerminalPage.cpp) exit 0

Repository gates — ran, passed

test-command-timeline.ps1, test-visual-progress.ps1, test-privacy.ps1,
verify-version.ps1, test-release-workflow.ps1, test-ci-classification.ps1,
test.ps1 -Suite Smoke -Configuration Release -Platform x64.

Staticgit diff --check clean; clang-format clean over the changed
ranges (TermControl differences verified to be EOL-representation only).

Not run, with reasontest-shell-integration.ps1 -Shell All: blocked by
local antivirus/AMSI on Compatibility.ps1, a file untouched by this PR and
byte-identical to main. It runs in the release workflow's gates.

No screenshot was needed or created. winterm-site is untouched.

Checklist

  • The change is focused and does not include unrelated formatting.
  • Tests were added or updated where appropriate.
  • All tests claimed above actually ran and passed.
  • User-facing behavior and limitations are documented in this repository.
  • This source/docs commit updates the root CHANGELOG.md.
  • The Wiki Development-Changes.md ledger has been pushed with the final source SHA, link, summary, and checkpoint/release.
  • Documentation screenshots reuse a suitable existing sanitized winterm-site asset, or no screenshot was added.
  • Version or schema changes include compatibility and migration notes.
  • Package identity, winterm.exe, and Microsoft Terminal coexistence remain isolated.
  • No command text, terminal output, clipboard content, credentials, or private paths are logged.
  • New source and script files contain the appropriate MIT license header.
  • I did not include generated build output, secrets, certificates, or local absolute paths.

Source ↔ Wiki mapping

Source commit Wiki commit Wiki pages
f3697b8 01de69c Development-Changes

Boundary

No persistent history, no output cache, no output search, no heuristic prompt
detection, no telemetry. Workspace schema (2), docking model (1), shell
protocol (1), theme schema (1), update manifest schema (1), package identity,
and signing policy are unchanged. Version metadata is unchanged. No
winterm-site change.

Next step after this merges: local re-test of the four fixes, then cut
v1.3.0-beta1 on channel beta with the winTerm website's stable/beta
download columns.

Local testing of v1.3.0-alpha1 reported four issues. This change fixes all
four ahead of the 1.3.0 beta.

1. The Command Timeline handle covered terminal content. The floating 28x48
   button is now a 6-pixel strip flush against the terminal's left edge, in
   the manner of an auto-hiding scrollbar. It widens to 20 pixels and shows
   its chevron on pointer hover, keyboard focus, or while the overlay is
   open, driven by _updateCommandTimelineHandleVisual.

2. Clicking the terminal area while the overlay was open did not close it.
   A pointer press on the terminal grid now light-dismisses the overlay and
   still continues into the terminal as normal input. Presses on the overlay
   itself never reach that handler, so overlay interaction is unaffected.

3. A dir listing left the Visual Progress bar animating indefinitely. Three
   recognition defects compounded:
   - _matchGradle claimed ownership from a bare product-name mention (for
     example a ".gradle" directory entry) and, once claimed, rematched every
     later record through an unconditional stage fallback, refreshing the
     bar forever. Each record now needs build-tool evidence of its own: a
     status meter with a real value, a wrapper download, or a task line.
   - A still-running built-in provider bar was never structurally cleared
     when its stream moved on; only Generic was. The engine now tolerates
     one ordinary record and publishes a structural clear on the second
     consecutive ordinary record. Success and Error results still persist,
     and progress-shaped records that keep a live claim do not advance the
     count.
   - _findIntegerFraction read slashed dates such as 2025/10/13 as 76%
     completed/total meters. A digit/digit/digit chain is now rejected.

4. Typed commands never appeared in the Command Timeline because nothing
   ever imported the packaged winTerm.Shell module: the launcher contract in
   docs/powershell-integration.md had no launcher. Connection creation now
   rewrites a bare powershell.exe or pwsh.exe profile commandline (only
   -NoLogo and -NoExit are tolerated) to append -NoExit -Command with a
   fragment that sets WINTERM_SESSION_ID and WINTERM_INTEGRATION_VERSION and
   imports the packaged manifest with -ErrorAction SilentlyContinue. The
   eligibility rules live in src/winterm/Shell/AutoIntegration.h; anything
   not positively recognized launches unchanged, execution policy is never
   altered, quote characters in the manifest path or session id refuse the
   rewrite, and an already-rewritten commandline reused by a restarted
   connection is not rewritten twice. The new per-profile setting
   "shellIntegration.autoInject" (default true) disables the rewrite.

Guards in test-command-timeline.ps1 now assert the auto-hiding handle and
the light-dismiss path. New unit tests cover the listing false positives,
the structural clear, terminal-state persistence, and the auto-integration
eligibility rules including its refusal cases.

No persistent history, no output cache, no heuristic prompt detection, no
telemetry. Workspace schema, docking model, shell protocol, theme schema,
update manifest schema, package identity, and signing policy are unchanged.
@HelloThisWorld
HelloThisWorld merged commit 18310e9 into main Aug 4, 2026
5 checks passed
HelloThisWorld added a commit that referenced this pull request Aug 4, 2026
Promotes the four alpha1 field-report fixes, already on main through pull
request #32, to a second installable alpha. This commit only moves the
release metadata.

- Set application version 1.3.0-alpha2, PowerShell module prerelease suffix
  alpha2, and tag v1.3.0-alpha2. The channel stays alpha, and the module
  version stays 1.3.0.
- Advance the package/file version to 1.3.0.1 so the alpha2 binaries are
  distinguishable from alpha1 in the FILEVERSION and PRODUCTVERSION numeric
  fields. The MSIX manifest and all three Win32 resource scripts move with
  it, and the display ProductVersion strings carry 1.3.0-alpha2.
- Update the version literals pinned by verify-version.ps1,
  verify-branding.ps1, test-visual-progress.ps1, test.ps1, and
  package-shell-assets.ps1.
- Add the 1.3.0-alpha2 release notes with a "Changes since alpha1" section
  covering the four fixes and the unsigned Setup EXE disclosure, and retitle
  the changelog's unreleased section.

The release workflow marks any non-stable channel with --prerelease and
--latest=false, so /releases/latest keeps resolving to v1.2.0, the alpha is
not listed on the winTerm website, and the WinGet workflow skips it.
Workspace schema, docking model, shell protocol, theme schema, update
manifest schema, package identity, and signing policy are unchanged.
@HelloThisWorld
HelloThisWorld deleted the fix/alpha1-feedback branch August 5, 2026 12:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant