Skip to content

V11.0.0/docfx - #181

Open
gimlichael wants to merge 27 commits into
mainfrom
v11.0.0/docfx
Open

gimlichael wants to merge 27 commits into
mainfrom
v11.0.0/docfx

Conversation

@gimlichael

Copy link
Copy Markdown
Member

This pull request introduces DocFX run-actions generation and template support so API documentation examples can be executed natively or in Docker, alongside updated API overwrite pages and repository documentation.

DocFX run-actions infrastructure:

  • Added a run-actions build script, manifest, settings, and client-side template script to generate and attach native and Docker execution scripts for API examples, including host sample probe support with build and HTTP probe timeouts.
  • Wired run-actions generation and asset cleanup into the DocFX image build, included generated run-actions assets in the DocFX configuration, and ignored the generated output directory in Git.

API documentation examples and overwrites:

  • Updated API type overwrite examples to use runnable entry points and align with DocFX rendering conventions, removed redundant availability notes, and attached generated run-action script links across the documented types.
  • Fixed include directive syntax on the HMAC authentication namespace overview page.

Repository documentation and guidance:

  • Clarified DocFX overwrite heading rules, namespace-only include restrictions, and interim scratch artifact guidance in the contributor guide.
  • Added the Cuemon.Kernel package entry to the repository README and recorded the DocFX updates in the changelog.

gimlichael and others added 15 commits November 21, 2026 13:15
Exclude the generated .docfx/run-actions/ directory from version control so build-time run-action artifacts do not pollute the working tree.
Clarify DocFX overwrite heading conventions, restrict [!INCLUDE] directives to namespace pages, and generalize interim scratch artifact restrictions.
Introduce DocFX run-actions generation and client-side template integration so API examples can be executed natively or via Docker.
Fix broken include syntax on namespace overview pages and update type overwrite examples to align with DocFX rendering conventions.
Regenerate run-actions manifest and settings to cover the updated DocFX API type examples.
Refine type overwrite examples to align with DocFX rendering and run-actions execution conventions.
Update the run-actions build script, manifest, and settings to match the revised DocFX API type examples.
Adjust type overwrite examples for ChecksumBuilder and PortablePhysicalFileProvider.
Add host-sample runner support in BuildRunActions.ps1 and regenerate the run-actions manifest and settings for updated DocFX API examples.
Update DocFX API type overwrite C# examples and attach generated run-action script links across 382 type pages.
Ensure host sample builds, HTTP probes, and startup delays respect the configured deadline and clean up child processes on timeout or failure.
Switch AppTagHelperOptions from an intrinsic limitation to a probed host run-action harness and regenerate its manifest and API doc snippet.
@gimlichael gimlichael self-assigned this Nov 22, 2026
@greptile-apps

greptile-apps Bot commented Nov 22, 2026 •

Copy link
Copy Markdown

RetriggerView in GreptileConfidence Score: 4/5

[Medium impact] The changes reach the published API documentation and its build workflow.

The previous missing-script problem is addressed, but the new C# entry point needs the XML comments required by the repository before merging.

Fix All in CodexFindings

  1. P2 Entry point lacks required documentation ▶
Fix with agent prompt
### Issue 1
tooling/docfx-multi-tfm/Consolidate.cs:20
`Consolidate.Main` has no XML comments. `AGENTS.md` requires XML comments on all public and protected members in C# files. Before merging, add a summary and document `args`, including the output-directory and framework/directory pairs, so callers do not have to read the argument parser.

```suggestion
    /// <summary>
    /// Combines DocFX metadata from the specified target frameworks into a new output directory.
    /// </summary>
    /// <param name="args">The output directory, followed by one or more target framework and metadata directory pairs.</param>
    public static void Main(string[] args)
```

Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!

---

For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.

Summary

Adds native and Docker scripts for API examples, plus checks that the documentation image includes them.

  • The DocFX build creates native and Docker scripts for API examples.
  • API example pages let readers copy or preview run scripts.
  • API examples now include runnable entry points and script links.
  • The DocFX build checks that run scripts reach the published site.
  • A separate fixture serves API documentation views for selected frameworks.

Diagram

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A[API examples and manifest] --> B[Generate run-action scripts]
    B --> C[Validate scripts and links]
    C --> D[Generate DocFX metadata]
    D --> E[Build documentation image]
    E --> F[Check published site]
    E --> G[Export OCI archive]
    G --> H[Check scripts in each image platform]
Loading

Reviews (3) · Last reviewed commit: "📝 document docfx local build prerequisi..." · Reviewed by Greptile

Comment thread .docfx/BuildDocfxImage.ps1 Resolved
Comment thread .docfx/run-actions.manifest.json Resolved
Comment thread README.md Resolved
@codecov

codecov Bot commented Nov 22, 2026 •

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 94.27%. Comparing base (7aac501) to head (53875b1).

Additional details and impacted files
@@           Coverage Diff           @@
##             main     #181   +/-   ##
=======================================
  Coverage   94.27%   94.27%           
=======================================
  Files         610      610           
  Lines       19319    19319           
  Branches     1874     1874           
=======================================
  Hits        18213    18213           
  Misses       1078     1078           
  Partials       28       28           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

gimlichael and others added 11 commits November 22, 2026 14:11
Allow net4x target frameworks in DocFX run-actions by skipping Docker transport for .NET Framework examples, adding reference assemblies and latest LangVersion for net4x host builds, and updating the CallerArgumentExpressionAttribute example to target net48 with native-only transport.
Tighten manifest validation and deterministic script generation in BuildRunActions.ps1, add TestRunActions.ps1 and verify-docfx-site.sh to verify generated scripts and built site assets, and preserve run-actions in the Docker build context.
Add a docfx_validation job to pr.yml to check deterministic run-action generation and Docker build context, and validate run-action assets in release.yml before and after building the OCI image.
Add a DocFX Build Entry Points section to AGENTS.md explaining local scripted builds, direct Docker builds, and CI validation.
Add a proof-of-concept tool and test harness to consolidate per-TFM DocFX managed-reference metadata across net10.0, net11.0, and netstandard2.0 without losing framework-specific APIs or relationships.
Drop the pinned net10.0 TargetFramework property from the remaining DocFX metadata groups in docfx.json so all groups follow the same unpinned configuration.
Add a proof-of-concept pipeline, NGINX routing config, browser adapter, and HTTP/Playwright verification scripts to build and serve independent per-TFM DocFX API views.
Skip assembly signing during metadata generation when cuemon.snk is absent locally, and resolve framework-prefixed API paths against framework-views.json during HTML link validation.
Replace the standalone PoC build, nginx config, and client script with the pinned docfx-oci-build shared implementation and ms-style template, and expand browser navigation and mobile assertions.
Add an opt-in workflow_dispatch input and matrix job on Ubuntu and Windows to build and validate the DocFX framework-view fixture.
Document required host tools, Docker configuration, and automatic signing-key fallback for the scripted local DocFX build.
private const string ManagedReference = "### YamlMime:ManagedReference";
private const string TableOfContent = "### YamlMime:TableOfContent";

public static void Main(string[] args)

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Entry point lacks required documentation

Consolidate.Main has no XML comments. AGENTS.md requires XML comments on all public and protected members in C# files. Before merging, add a summary and document args, including the output-directory and framework/directory pairs, so callers do not have to read the argument parser.

Suggested change
public static void Main(string[] args)
/// <summary>
/// Combines DocFX metadata from the specified target frameworks into a new output directory.
/// </summary>
/// <param name="args">The output directory, followed by one or more target framework and metadata directory pairs.</param>
public static void Main(string[] args)

Context Used: AGENTS.md (source)

Prompt To Fix With AI
This is a comment left during a code review.
Path: tooling/docfx-multi-tfm/Consolidate.cs
Line: 20

Comment:
**Entry point lacks required documentation**

`Consolidate.Main` has no XML comments. `AGENTS.md` requires XML comments on all public and protected members in C# files. Before merging, add a summary and document `args`, including the output-directory and framework/directory pairs, so callers do not have to read the argument parser.

```suggestion
    /// <summary>
    /// Combines DocFX metadata from the specified target frameworks into a new output directory.
    /// </summary>
    /// <param name="args">The output directory, followed by one or more target framework and metadata directory pairs.</param>
    public static void Main(string[] args)
```

**Context Used:** AGENTS.md ([source](https://github.com/codebeltnet/cuemon/blob/main/AGENTS.md))

---

For each issue above, determine whether it is valid and should be fixed. If so, fix it directly.

Note: If this suggestion doesn't match your team's coding style, reply to this and let me know. I'll remember it for next time!

Fix in Codex

@sonarqubecloud

Copy link
Copy Markdown

This branch has not been deployed

No deployments
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.

2 participants