Skip to content

Add missing XML documentation to PythonModuleBuilder public members - #14743

Merged
Anna Tisch (annatisch) merged 2 commits into
pythonapphostfrom
copilot/sub-pr-13947
Feb 26, 2026
Merged

Anna Tisch (annatisch) merged 2 commits into
pythonapphostfrom
copilot/sub-pr-13947

Conversation

Copilot AI commented Feb 26, 2026 •

Copy link
Copy Markdown
Contributor

Two public members in PythonModuleBuilder were missing <summary> XML documentation tags, inconsistent with the rest of the class and the repo's XML doc standards.

Changes

  • Added <summary> to the MethodParameters property describing it as the dictionary of method parameter type class definitions keyed by parameter type name
  • Added <summary> to the DistributedApplicationBuilder constant identifying it as the Python class definition string for the generated SDK

Checklist

  • Is this feature complete?
    • Yes. Ready to ship.
    • No. Follow-up changes expected.
  • Are you including unit tests for the changes and scenario tests if relevant?
    • Yes
    • No
  • Did you add public API?
    • Yes
      • If yes, did you have an API Review for it?
        • Yes
        • No
      • Did you add <remarks /> and <code /> elements on your triple slash comments?
        • Yes
        • No
    • No
  • Does the change make any security assumptions or guarantees?
    • Yes
      • If yes, have you done a threat model and had a security review?
        • Yes
        • No
    • No
  • Does the change require an update in our Aspire docs?

💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more Copilot coding agent tips in the docs.

…butedApplicationBuilder constant

Co-authored-by: annatisch <[email protected]>
Copilot AI changed the title [WIP] Update PythonAppHost code generator based on feedback Add missing XML documentation to PythonModuleBuilder public members Feb 26, 2026
@annatisch
Anna Tisch (annatisch) marked this pull request as ready for review February 26, 2026 21:08
@annatisch
Anna Tisch (annatisch) merged commit b8b412d into pythonapphost Feb 26, 2026
2 of 3 checks passed
@annatisch
Anna Tisch (annatisch) deleted the copilot/sub-pr-13947 branch February 26, 2026 21:09
Sébastien Ros (sebastienros) added a commit that referenced this pull request Mar 26, 2026
* Start porting over Python API

* Merged latest changes

* Update to module builder

* Support recursive interface collection

* Fix interfaces

* Support sync and async variants

* More merging

* Fixed merge

* Updates

* Updates

* Fixed generic interface

* Update AspireList

* Cached properties

* Added resource constructors with kwargs

* Fixed ABCs and list/dict registration

* Fix handles and logging

* Fix some tests

* More test fixes

* Update python lookup

* Fix Python CodeGeneration build errors and update tests

- Add XML documentation to AtsPythonCodeGenerator class
- Remove unused 'using System.Text;' and 'using Aspire.Hosting.ApplicationModel;' directives
- Update test file key from 'aspire.py' to '__init__.py' to match generator output
- Update test assertions to use actual generated method names (with_env instead of with_environment)
- Update verified snapshots to match new generator output

* Patch files

* Fix Python polyglot validation test to match scaffold output

The scaffold generates 'builder.run()' but the validation test was looking
for 'builder.build().run()'. Updated the grep/sed pattern to match the
actual scaffold output.

* Update Go, Java, and Rust CodeGeneration test snapshots

Updated verified snapshots to match current scanner output after main merge.

* Fix Python validation test indentation

The inserted Redis code needs proper 4-space indentation to be valid
inside the Python 'with' block.

* Improvements to errors + rename

* Regenerate snapshots

* Revert fallback cast error handling

* Add missing XML documentation to PythonModuleBuilder public members (#14743)

* Initial plan

* Add missing XML documentation to MethodParameters property and DistributedApplicationBuilder constant

Co-authored-by: annatisch <[email protected]>

---------

Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: annatisch <[email protected]>

* Add comprehensive XML documentation to PythonLanguageSupport public API (#14744)

* Initial plan

* Add comprehensive XML documentation to PythonLanguageSupport public members

Co-authored-by: annatisch <[email protected]>

---------

Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: annatisch <[email protected]>

* Add descriptive XML documentation for AtsTypeRef.ImplementedInterfaces and AtsTypeRef.BaseType (#14746)

* Initial plan

* Improve XML documentation for ImplementedInterfaces and BaseType on AtsTypeRef

Co-authored-by: annatisch <[email protected]>

---------

Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: annatisch <[email protected]>

* Re-record tests

* Remove extra project reference

* Re-record tests

* Re-record tests

* Restructure packaging

* Refactored aspire module to single file

* Generate to .modules

* Generate modules before installing

* Support conditional ref expr

* Remove additionalArgs

* Tests

* Renames to prevent naming conflicts

* Group similar overloads

* Support param defaults

* Update Python codegen snapshots

Accept regenerated Python snapshots after the cancellation token and process timeout fixes.

Co-authored-by: Copilot <[email protected]>

* Fix polyglot and CLI template validation

Co-authored-by: Copilot <[email protected]>

* Add Python polyglot playground validation

Co-authored-by: Copilot <[email protected]>

* Skip unsupported Python SDK playgrounds

Exclude Azure.Sql, Foundry, and Maui from Python polyglot playground validation until Python code generation supports their current API surface.

Co-authored-by: Copilot <[email protected]>

* Fix Python codegen naming conflicts

Sanitize Python identifiers derived from capability parameters and derive generic Python type names without leaking CLR assembly metadata so the Python playground validation can cover Azure.Sql, Foundry, and Maui again.

Co-authored-by: Copilot <[email protected]>

* Address PR review feedback

Co-authored-by: Copilot <[email protected]>

* Refresh Python playground apphosts

Remove the stale .modules sys.path bootstrap from the generated Python playground ValidationAppHosts so they match the shared Python scaffold, and add a regression test to keep new scaffolds importing aspire_app directly.

Co-authored-by: Copilot <[email protected]>

* Remove Python scaffold assertion test

Drop the implementation-shaped Python scaffold test and rely on the existing generated-output verification for this area.

Co-authored-by: Copilot <[email protected]>

* Add PythonAppHost playground

Create a Python AppHost playground that orchestrates a Redis cache, a Uvicorn-hosted Python app, and a Vite frontend that references the Python service.

Co-authored-by: Copilot <[email protected]>

* Update Python codegen snapshot

Co-authored-by: Copilot <[email protected]>

* Fix Java validation selection

Co-authored-by: Copilot <[email protected]>

* Fix describe replica test

Co-authored-by: Copilot <[email protected]>

---------

Co-authored-by: Sebastien Ros <[email protected]>
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
Adam Ratzman (adamint) pushed a commit to adamint/aspire that referenced this pull request Mar 28, 2026
* Start porting over Python API

* Merged latest changes

* Update to module builder

* Support recursive interface collection

* Fix interfaces

* Support sync and async variants

* More merging

* Fixed merge

* Updates

* Updates

* Fixed generic interface

* Update AspireList

* Cached properties

* Added resource constructors with kwargs

* Fixed ABCs and list/dict registration

* Fix handles and logging

* Fix some tests

* More test fixes

* Update python lookup

* Fix Python CodeGeneration build errors and update tests

- Add XML documentation to AtsPythonCodeGenerator class
- Remove unused 'using System.Text;' and 'using Aspire.Hosting.ApplicationModel;' directives
- Update test file key from 'aspire.py' to '__init__.py' to match generator output
- Update test assertions to use actual generated method names (with_env instead of with_environment)
- Update verified snapshots to match new generator output

* Patch files

* Fix Python polyglot validation test to match scaffold output

The scaffold generates 'builder.run()' but the validation test was looking
for 'builder.build().run()'. Updated the grep/sed pattern to match the
actual scaffold output.

* Update Go, Java, and Rust CodeGeneration test snapshots

Updated verified snapshots to match current scanner output after main merge.

* Fix Python validation test indentation

The inserted Redis code needs proper 4-space indentation to be valid
inside the Python 'with' block.

* Improvements to errors + rename

* Regenerate snapshots

* Revert fallback cast error handling

* Add missing XML documentation to PythonModuleBuilder public members (microsoft#14743)

* Initial plan

* Add missing XML documentation to MethodParameters property and DistributedApplicationBuilder constant

Co-authored-by: annatisch <[email protected]>

---------

Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: annatisch <[email protected]>

* Add comprehensive XML documentation to PythonLanguageSupport public API (microsoft#14744)

* Initial plan

* Add comprehensive XML documentation to PythonLanguageSupport public members

Co-authored-by: annatisch <[email protected]>

---------

Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: annatisch <[email protected]>

* Add descriptive XML documentation for AtsTypeRef.ImplementedInterfaces and AtsTypeRef.BaseType (microsoft#14746)

* Initial plan

* Improve XML documentation for ImplementedInterfaces and BaseType on AtsTypeRef

Co-authored-by: annatisch <[email protected]>

---------

Co-authored-by: copilot-swe-agent[bot] <[email protected]>
Co-authored-by: annatisch <[email protected]>

* Re-record tests

* Remove extra project reference

* Re-record tests

* Re-record tests

* Restructure packaging

* Refactored aspire module to single file

* Generate to .modules

* Generate modules before installing

* Support conditional ref expr

* Remove additionalArgs

* Tests

* Renames to prevent naming conflicts

* Group similar overloads

* Support param defaults

* Update Python codegen snapshots

Accept regenerated Python snapshots after the cancellation token and process timeout fixes.

Co-authored-by: Copilot <[email protected]>

* Fix polyglot and CLI template validation

Co-authored-by: Copilot <[email protected]>

* Add Python polyglot playground validation

Co-authored-by: Copilot <[email protected]>

* Skip unsupported Python SDK playgrounds

Exclude Azure.Sql, Foundry, and Maui from Python polyglot playground validation until Python code generation supports their current API surface.

Co-authored-by: Copilot <[email protected]>

* Fix Python codegen naming conflicts

Sanitize Python identifiers derived from capability parameters and derive generic Python type names without leaking CLR assembly metadata so the Python playground validation can cover Azure.Sql, Foundry, and Maui again.

Co-authored-by: Copilot <[email protected]>

* Address PR review feedback

Co-authored-by: Copilot <[email protected]>

* Refresh Python playground apphosts

Remove the stale .modules sys.path bootstrap from the generated Python playground ValidationAppHosts so they match the shared Python scaffold, and add a regression test to keep new scaffolds importing aspire_app directly.

Co-authored-by: Copilot <[email protected]>

* Remove Python scaffold assertion test

Drop the implementation-shaped Python scaffold test and rely on the existing generated-output verification for this area.

Co-authored-by: Copilot <[email protected]>

* Add PythonAppHost playground

Create a Python AppHost playground that orchestrates a Redis cache, a Uvicorn-hosted Python app, and a Vite frontend that references the Python service.

Co-authored-by: Copilot <[email protected]>

* Update Python codegen snapshot

Co-authored-by: Copilot <[email protected]>

* Fix Java validation selection

Co-authored-by: Copilot <[email protected]>

* Fix describe replica test

Co-authored-by: Copilot <[email protected]>

---------

Co-authored-by: Sebastien Ros <[email protected]>
Co-authored-by: Copilot <[email protected]>
Co-authored-by: Copilot <[email protected]>
@github-actions github-actions Bot locked and limited conversation to collaborators Mar 29, 2026
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants