Skip to content

docs: an Update section, and small fixes in the pivot module - #172

Merged
eizedev merged 3 commits into
mainfrom
docs/update-guide
Nov 23, 2026
Merged

eizedev merged 3 commits into
mainfrom
docs/update-guide

Conversation

@eizedev

@eizedev eizedev commented Nov 23, 2026

Copy link
Copy Markdown
Owner

A review of main at 0f29450 found that the docs say nothing about updating a module, and four small points in the pivot module. This pull request fixes them.

What changed

  • docs/getting-started.md has an Update section: install the new version next to the old one, restart PSU, readers reload, remove the old folder. It also says what to check: each module carries its own copy of the shared code, where readers' views live, view file formats when going back, and the published schema folder. The last two link to the templates page, which owns them.
  • The five module READMEs link to that section instead of repeating it.
  • Pivot: Remove-UDPivotErrorRecord is the one place that removes the record of a handled error from $Error. It replaces three copies of the same guarded RemoveAt(0). The five catches that parse a server's answer use it too, so the rule in AGENTS.md holds for every catch around an HTTP request or its answer.
  • Pivot: the settings files in Private/Settings/ load in name order on every file system (Get-ChildItem returns the order the file system keeps).
  • New-UDPivotReport has a comment that names its steps.
  • AGENTS.md: the -Bound pattern and the test that checks it, and the $Error rule.

How the Update facts were checked

  • Install-PSResource and Update-PSResource install a newer version side by side and keep the old folder (Microsoft's PSResourceGet docs).
  • With two versions in one module folder, PowerShell imports the newest; a process that has imported a module keeps it. I measured this with plain pwsh, not on PSU.
  • The PSU docs do not say which version an app loads or whether an app restart is enough. That is why the section says "restart PSU", which starts every process fresh. I did not measure an app restart on PSU.
  • The bundle name carries a content hash ([contenthash] in build/webpack.base.cjs).
  • View file formats: ConvertFrom-UDPivotViewFile reads formats 1 and 2 and refuses newer ones.

Not changed

  • The catch in Invoke-UDPivotCli that parses the command line's output is no HTTP answer. It stays as it is.

Checks

  • Pester: all pass. Two new tests: two failed calls in a row keep the caller's records and leave no token in $Error; the helper removes the newest record only when it is the error caught. A mutation of the helper (no removal, or an unconditional RemoveAt(0)) fails them. The timing test of ConvertTo-PSUComponentData failed once under load in a full run and passed alone.
  • PSScriptAnalyzer as in CI: no findings. npm test: all pass. npm run growth: all four guards ok. Build-Module.ps1 for all five modules.
  • Places checked: getting-started, the five module READMEs, the root README and docs/index.md (no install text to change), docs/pivot/templates.md, AGENTS.md, the Pivot CHANGELOG.

🤖 Generated with Claude Code

eizedev and others added 3 commits November 23, 2026 01:06
…vot module

- docs/getting-started.md: how to update a module (new version folder, restart the apps, reload,
  remove the old folder) and what carries over (shared code per module release, stored views, view
  file formats, the published schema folder). The module READMEs link to it.
- Pivot: Remove-UDPivotErrorRecord is the one place that removes a handled error's record from
  $Error (three copies before); a test checks two failed calls in a row.
- Pivot: the settings files load in the order of their names on every file system.
- New-UDPivotReport: a comment names its steps.
- AGENTS.md: the -Bound pattern and its test, and the $Error rule.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
… Update section with verified steps only

- The five catches that parse a server's answer call Remove-UDPivotErrorRecord as well, so the
  AGENTS.md rule holds for every catch around a request or its answer.
- A direct test of the helper: the newest record is removed only when it is the error caught; the
  two-call test also checks that no token is left in $Error.
- Update section: only what is verified (Install-PSResource side by side, PowerShell imports the
  newest version, restart PSU); the view file formats and the schema folder link to the templates
  page instead of repeating it.
- Pivot CHANGELOG: the settings load order.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@eizedev
eizedev merged commit dbe81b5 into main Nov 23, 2026
11 checks passed
@eizedev
eizedev deleted the docs/update-guide branch November 23, 2026 00:34
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