Isolated per-module weekly docs generation (one stage & PR per module) - #827
Conversation
Each Graph workload module now generates in its own Azure DevOps stage per SDK profile (~86 independent stages), giving every module a fresh agent and a clean assembly-load context. This structurally eliminates the "assembly with same name is already loaded" collisions that produced mass-deletion / no-op refresh PRs. - GenerateMarkDown.ps1: add -GraphProfileFilter and -ModuleFilter scoping; in scoped runs do a complete delete + full regen of the single module, throw before any deletion on import failure (fail-safe), and emit a ModuleGenerated signal only on success. - 9 post-processing scripts: add matching profile/module scoping and empty-commit guards so each touches only the target module folder. - update-template.yml: parameterized install (InstallProfile/Module) that installs only Authentication + the single workload submodule for isolated runs; install failures warn instead of failing. - New common-templates/generate-module-docs-steps.yml: full single-module sequence (install -> generate -> post-process -> push -> PR). Generate step is continueOnError and every later step is gated on ModuleGenerated, so a failing module deletes nothing, opens no PR, and never fails the overall pipeline. - New common-templates/module-stages.yml: emits one dependsOn:[] stage per module. - powershell-docs.yml: invoke module-stages.yml for v1.0 (incl. Authentication) and beta; each stage opens its own pull request. ms.date changes every run (StabilizeMsDate is intentionally not run) for reviewable PRs. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: 4d27d82f-3809-40d2-b4e7-6623436ff2ef
PoliCheck Scan ReportThe following report lists PoliCheck issues in PR files. Before you merge the PR, you must fix all severity-1 and severity-2 issues. The AI Review Details column lists suggestions for either removing or replacing the terms. If you find a false positive result, mention it in a PR comment and include this text: #policheck-false-positive. This feedback helps reduce false positives in future scans. ✅ No issues foundMore information about PoliCheckInformation: PoliCheck | Severity Guidance | Term |
|
Learn Build status updates of commit 00db044: ✅ Validation status: passed
For more details, please refer to the build report. |
Azure DevOps resolves template references relative to the directory of the referencing file. powershell-docs.yml lives in azure-pipelines/, so the "azure-pipelines/common-templates/module-stages.yml@self" path resolved to azure-pipelines/azure-pipelines/common-templates/module-stages.yml and failed with "Not Found". Use a path relative to the file's own directory instead. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: 4d27d82f-3809-40d2-b4e7-6623436ff2ef
PoliCheck Scan ReportThe following report lists PoliCheck issues in PR files. Before you merge the PR, you must fix all severity-1 and severity-2 issues. The AI Review Details column lists suggestions for either removing or replacing the terms. If you find a false positive result, mention it in a PR comment and include this text: #policheck-false-positive. This feedback helps reduce false positives in future scans. ✅ No issues foundMore information about PoliCheckInformation: PoliCheck | Severity Guidance | Term |
|
Learn Build status updates of commit 5202fe4: ✅ Validation status: passed
For more details, please refer to the build report. |
The Authentication module is not present in ModulesMapping.jsonc, so the scoped
module filter ($ModulesToGenerate | Where-Object { $_ -eq $ModuleFilter })
produced an empty list. The folder-based post-processing scripts then passed
that empty array into helper parameters marked [ValidateNotNullOrEmpty()] /
[Parameter(Mandatory)], throwing "The argument is null or empty" and failing the
Escape/UpdateLinks/RemoveInvalidFullStops/CorrectRelatedLinks steps.
These scripts never post-processed Authentication in the original full run either
(its docs are generated but excluded from the module list). Restore that behavior
by skipping gracefully when the filtered module list is empty, so the
Authentication stage succeeds and still opens its PR. RemoveBoilerPlateCode is
unchanged: it intentionally runs its Authentication-specific cleanup and safely
no-ops its (unvalidated) module loop.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot-Session: 4d27d82f-3809-40d2-b4e7-6623436ff2ef
PoliCheck Scan ReportThe following report lists PoliCheck issues in PR files. Before you merge the PR, you must fix all severity-1 and severity-2 issues. The AI Review Details column lists suggestions for either removing or replacing the terms. If you find a false positive result, mention it in a PR comment and include this text: #policheck-false-positive. This feedback helps reduce false positives in future scans. ✅ No issues foundMore information about PoliCheckInformation: PoliCheck | Severity Guidance | Term |
|
Learn Build status updates of commit c49bf4e: ✅ Validation status: passed
For more details, please refer to the build report. |
050866e
into
ramsess/revert-generation-changes
Refactors the weekly documentation pipeline so every Graph workload module generates in its own isolated Azure DevOps stage per SDK profile (~86 independent stages). Each stage runs on a fresh agent with a clean assembly-load context, structurally eliminating the "assembly with same name is already loaded" collisions that caused mass-deletion and no-op refresh PRs.
What changed
GenerateMarkDown.ps1— new-GraphProfileFilter/-ModuleFilterscoping. Scoped runs do a complete delete + full regen of the single module, but throw before any deletion if the module fails to import (fail-safe), and set aModuleGeneratedsignal only on success.update-template.yml— parameterized install (InstallProfile/Module): isolated runs install onlyMicrosoft.Graph.Authentication+ the single workload submodule. Install failures warn instead of failing.generate-module-docs-steps.yml(new) — full single-module sequence: install → generate → post-process → push → PR. Generate step iscontinueOnError; every later step is gated onModuleGenerated, so a failing module deletes nothing, opens no PR, and never fails the overall pipeline.module-stages.yml(new) — emits onedependsOn: []stage per module.powershell-docs.yml— invokesmodule-stages.ymlfor v1.0 (incl. Authentication) and beta. Each stage opens its own pull request.Behaviour guarantees
ms.datechanges every run (StabilizeMsDateintentionally not run) → reviewable PRs.Validation
GenerateMarkDown.ps1 -ModuleFilter Search -GraphProfileFilter v1.0regenerated only the Search v1.0 folder and touched nothing else.