Skip to content

Group processing per source type (ProcessGroupsAD/ProcessGroupsGoogle); one deactivate-strip gate that honors WhatIf — release 26.10.9.0 - #15

Merged
SamSCN merged 2 commits into
mainfrom
feature/per-type-group-processing
Oct 9, 2026
Merged

SamSCN merged 2 commits into
mainfrom
feature/per-type-group-processing

Conversation

@SamSCN

@SamSCN SamSCN commented Oct 9, 2026

Copy link
Copy Markdown
Contributor

Summary

Group processing could only be switched on or off per directory (AD / Google.enableGroupProcessing), so a district couldn't, for example, manage student groups while leaving staff groups alone.

  • Per-record flags ProcessGroupsAD / ProcessGroupsGoogle on New-IDBridgeSourceRecord, default $true. When a record's flag is $false, that directory's group processing leaves the person alone entirely: no adds, no removes, and no deactivate strip. It's a user-level skip rather than an empty GroupsProposed, which with Remove on would strip every group. The flags only narrow enableGroupProcessing; they can never turn it on. Get-ADUserGroupsToUpdate / Get-GoogleUserGroupsToUpdate log the skipped count at Trace, and the groups-not-processed trace ignores opted-out users.
  • Templates expose it. Staff (TemplateVersion 2): $ADProcessGroups / $GoogleProcessGroups. Skyward (TemplateVersion 3) and Infinite Campus (TemplateVersion 2): per grade via AD/Google.ProcessGroups in GradeDefaultSettings / GradeOverrides, read as -ne $false so a settings block without the key stays opted in. Installed plugins need no change.
  • One deactivate-strip gate that honors WhatIf. AD stripped groups on deactivate whenever enableGroupProcessingTrash was on, even with AD.enableGroupProcessing = $false. Google also required the master switch. Neither checked enableGroupProcessingWhatIf, so with Trash on, deactivations stripped groups for real in WhatIf mode, contradicting the documented "no group writes happen". Both directories now strip only when enableGroupProcessing and enableGroupProcessingTrash are on, WhatIf is off, and the user hasn't opted out. Behavior change: Trash on with WhatIf on (either directory), or with AD group processing off, no longer strips on deactivate.
  • Docs: plugins.md, configuration.md, functions.md, getting-started.md, CLAUDE.md safety model.
  • Release 26.10.9.0 as the last commit.

Verification

  • Pester before (clean main): 252 passed, 0 failed. After: 259 passed, 0 failed (7 new cases). Against the old code, the 6 behavior cases fail and the 2 regression guards (record without the property; AD-only opt-out still processed in Google) pass. Test-ModuleManifest passes at 26.10.9.0.
  • The trash gate lives in Invoke-IDBridge's execute phase, which the decide-phase suite doesn't cover. Its actual expressions were lifted from the file through the PowerShell parser and checked against all 8 Enable/Trash/WhatIf combinations × 4 flag values ($null, $true, $false, 'FALSE') for both directories.
  • Not executed: a live run against AD or Google.

Not included

The shipped Invoke-PluginStaffOverride only accepts a fixed list of override Types, so the override sheet can't set these flags yet. Merge-IDBridgeOverrideData already handles them, including a sheet's 'FALSE' string.

After merge

Tag the merge commit v26.10.9.0 (or dispatch the Publish workflow), which publishes to the Gallery and creates the GitHub Release.

🤖 Generated with Claude Code

SamSCN and others added 2 commits October 9, 2026 11:18
…); one deactivate-strip gate that honors WhatIf

New per-record [bool] flags on New-IDBridgeSourceRecord (default $true). A record with
ProcessGroups<Dir> = $false is left alone by that directory's group processing: no adds,
no removes, no deactivate strip. The flags only narrow enableGroupProcessing. Staff,
Skyward and Infinite Campus templates expose them (staff-wide / per grade) and bump their
TemplateVersion. Tests cover the diff skip, override-sheet strings, and factory defaults.

The deactivate group strip now requires enableGroupProcessing + enableGroupProcessingTrash
on and enableGroupProcessingWhatIf off in both directories (AD ignored the master switch,
and neither honored WhatIf), and skips opted-out users.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@SamSCN
SamSCN merged commit e4d83e1 into main Oct 9, 2026
2 checks passed
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