Repository navigation
Import official Android.Media.Quality first-fill documentation - #813
jonathanpeppers merged 6 commits into
Conversation
Import 130 exact, meaningful official Android documentation channels in 13 bounded offline batches, preserving existing authored documentation. Withhold 19 source-bound unsafe parcel, collection-return and type-code channels while retaining their safe direct placeholder siblings. Add full native-fragment production guards and registered proof fixtures. Tracks #153. Co-authored-by: Copilot App <[email protected]>
|
@dalexsoto review |
There was a problem hiding this comment.
Copilot review overview
🔵 Needs a closer look
The broad source import and specialized guard logic warrant final human provenance review despite extensive tests.
Review effort: Balanced
Findings: None
What changed in this PR
Imports 130 official Android.Media.Quality documentation fills while preserving unsafe or authored channels.
Changes:
- Adds source-bound guards for 19 unsafe documentation channels.
- Adds comprehensive self-test fixtures for guarded imports.
- Updates 20 API XML files with official documentation.
| File | Description |
|---|---|
tools/importer.md |
Documents Quality-specific safeguards. |
tools/importer.cs |
Implements guards, declaration parsing, and tests. |
tools/importer-fixtures/quality-firstfill-native.json |
Adds native-source guard fixtures. |
docs/xml/Android.Media.Quality/ActiveProcessingPicture.xml |
Documents Parcelable members. |
docs/xml/Android.Media.Quality/AmbientBacklightEvent.xml |
Documents event and Parcelable members. |
docs/xml/Android.Media.Quality/AmbientBacklightEventType.xml |
Documents event enum values. |
docs/xml/Android.Media.Quality/AmbientBacklightMetadata.xml |
Documents metadata values and members. |
docs/xml/Android.Media.Quality/AmbientBacklightMetadataAlgorithm.xml |
Documents algorithm enum values. |
docs/xml/Android.Media.Quality/AmbientBacklightSettings.xml |
Documents settings values and members. |
docs/xml/Android.Media.Quality/AmbientBacklightSettingsSource.xml |
Documents source enum values. |
docs/xml/Android.Media.Quality/MediaQualityManager.xml |
Documents profile queries and callbacks. |
docs/xml/Android.Media.Quality/MediaQualityManager+ProfileQueryParams.xml |
Documents query Parcelable members. |
docs/xml/Android.Media.Quality/MediaQualityManager+ProfileQueryParams+Builder.xml |
Documents builder operations. |
docs/xml/Android.Media.Quality/ParameterCapability.xml |
Documents capability members. |
docs/xml/Android.Media.Quality/ParameterCapabilityType.xml |
Documents parameter-type values. |
docs/xml/Android.Media.Quality/PictureProfile.xml |
Documents picture-profile members. |
docs/xml/Android.Media.Quality/PictureProfile+Builder.xml |
Documents parameter configuration. |
docs/xml/Android.Media.Quality/PictureProfileErrorType.xml |
Documents picture-profile errors. |
docs/xml/Android.Media.Quality/PictureProfileType.xml |
Documents picture-profile types. |
docs/xml/Android.Media.Quality/SoundProfile.xml |
Documents sound-profile members. |
docs/xml/Android.Media.Quality/SoundProfile+Builder.xml |
Documents parameter configuration. |
docs/xml/Android.Media.Quality/SoundProfileErrorType.xml |
Documents sound-profile errors. |
docs/xml/Android.Media.Quality/SoundProfileType.xml |
Documents sound-profile types. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
Integrate the protected Controls Templates and Media Browse additions while retaining all Quality first-fill channels, registered tests and source fixtures. Resolve the independent production branches and optional source-record tails without changing the existing review round. Co-authored-by: Copilot App <[email protected]>
Integrate the protected NFC CardEmulators additions while retaining all Quality documentation, complete NFC/Browse/Controls/TV production paths, registered ordinary tests, independent source fixtures, optional fields and guide content. Co-authored-by: Copilot App <[email protected]>
|
@dalexsoto review |
Co-authored-by: Copilot App <[email protected]>
Co-authored-by: Copilot App <[email protected]>
dalexsoto
left a comment
There was a problem hiding this comment.
The 130 committed fills and deliberate partial scope match the complete declaring contracts. The full 23-file review, separate integration/completeness pass and final independent sweep leave one current preservation blocker.
Keep first-fill metadata changes inside the newly filled remarks (tools/importer.cs:579-583). This branch calls AddSourceDocumentationIfSafe, which performs whole-Docs duplicate-reference reconciliation. For the exact guarded GetAvailablePictureProfiles(ProfileQueryParams) fixture, retain existing authored summary and collection-return prose with a canonical source-reference paragraph in each, and leave only remarks as a direct placeholder. A safe remarks fill consumes one operation, but the all-descendant selector and Skip(1) duplicate cleanup also remove the recognized reference paragraph from protected <returns>. Returns is then reported source_channel_ambiguous/skipped even though its bytes changed. This occurs with --max-changes 1.
That violates the explicitly accepted first-fill-only preservation contract, not the decision to withhold inaccurate collection returns or retain remaining placeholders. The current authored/nested control has no eligible direct remarks fill, so it never reaches this metadata call.
Attach source reference and attribution only within the newly filled remarks, without reconciling original nonplaceholder/excluded channels. Add a mixed-authored regression with summary/return references plus one direct remarks placeholder, asserting protected-channel byte identity and accurate skipped-return reporting. This is independently verified exact-head source/DOM reachability evidence, not an executed importer result; no additional independent blocker was found.
|
@dalexsoto review |
…ills Attach source references and attribution atomically inside newly filled Quality remarks only. Add mixed-authored regression checks for skipped collection returns and byte preservation across newline/BOM states. Preserve incoming main changes and use source-generated SliceProvider fingerprint JSON without changing its hash contract or runtime policy. Co-authored-by: Copilot App <[email protected]>
|
@dalexsoto review Fixed the preservation blocker from review 5402262968 in 8a80e42. Quality first-fill now attaches the canonical source reference and attribution atomically inside only the newly filled direct remarks; it no longer reconciles references in authored summary or excluded returns. The existing importer self-test now exercises authored summary/collection-return references with one direct remarks placeholder and Normally merged current main (5644f39), retaining both Quality and incoming SliceProvider paths. Also fixed the incoming SliceProvider reflection-serialization failure using explicit source-generated JSON contracts, preserving the literal serialization contract and all seven pinned binding/source hashes without runtime-policy overrides. All 43 Quality XML files are unchanged from the previously reviewed head; the 130 fills and 19 withheld channels are preserved. Affected XML parses and |
dalexsoto
left a comment
There was a problem hiding this comment.
The preservation blocker from review 5402262968 is fixed. The scoped Quality helper attaches source reference and attribution only inside newly filled direct remarks, before recording the one fill operation; authored summary and excluded-return references are no longer reconciled. The registered mixed-authored regression now reaches that budget-one path and checks actual protected-channel/outside-remarks bytes, LF/CRLF, BOM state, accurate skipped-return reporting, dry runs and zero-write repeats.
The complete current 23-file review, independent integration/completeness passes and final blocker searches found no remaining high-confidence independent blocker. The accepted 130 first fills and 19 withheld channels remain intact; all 43 Quality XML files are byte-identical to the previously reviewed head. The incoming SliceProvider fingerprint serialization now uses explicit generated type information while preserving the original ordered JSON inputs and seven pinned contract constants.
Latest CLA, OpenPublishing.Build and PoliCheck results are successful. This is an exact-head immutable-source/static review; importer self-tests and CI were not executed here, and fresh author validation is not treated as retrospective proof of earlier qualification receipts.
Tracks #153.
Documentation scope
Import 130 substantive first fills from 22 official Android developer-reference pages into 20 API XML files, using 13 individually reviewed offline batches capped at ten changes. Every production apply includes both
docs\xml\Android.Media.Qualityanddocs\xml\ns-Android.Media.Quality.xml, plus the namespace. Existing nonplaceholder channels and XML outside Docs remain byte-identical; generated indexes and other namespaces are untouched.The current whole-scope direct Docs leaf placeholder balance is 523 → 393: API 521 → 391, overview 2 → 2. The overview is scanned but its Name-only root is not selected by the existing namespace FullName filter; it remains unchanged. These structural counts are distinct from the issue's historical raw-text count.
Conservative source guards
Withhold 19 exact unsafe channels across 11 owners: eight parcel summary/remarks pairs containing
Flatten this object in to a Parcel., two collection returns describing a single nullable profile, and one parameter-type value advertising combinations of mutually exclusive codes. Full official declarations, source identity, managed DocId/signature/ordered parameters/return and JNI identity bind each guard. Safe sibling channels remain usable through a direct first-fill-only path; authored or nested documentation is not repaired or enriched.The complete final report records zero candidates/errors and 623 skipped entries: 223 missing member registrations, 46 missing type registrations, 19 ambiguous source channels, 37 nonmeaningful channels, 41 empty source documents, 1 missing parameter, 232 already-current remarks, 2 missing remarks, 20 missing returns and 2 missing summaries. Report entries are not a count of remaining placeholders.
Qualification
The ordinary full registered suite passed before changes and at the exact published head using default JIT
dotnet run --no-cache -p:PublishAot=false tools\importer.cs -- --self-test. New tests retain complete original contiguous native declaration fragments and exercise real bounded production applies, zero-write repeats, identity/signature controls and authored/nested preservation. All inherited tests, fixtures, guide content and optional record fields are preserved.A fresh initially empty own-cache online/offline pair differs only in three transport JSON fields and the TXT cache line. A real final offline apply records zero writes/errors with unchanged whole scope/tool bytes. Every authored channel is tied to an independently reviewed complete native source fragment; all 130 fragments compare byte-for-byte against the fresh sources. XML parsing and
git diff --checkpass. The independent complete binary inverse reconstructs the entire actual-main path/mode/blob tree (11,140 paths); the new fixture accounts for the proposed tree's 11,141 paths.Original failures and limitations are retained: guard-test reader/setup failures precede the passing full suite; one concurrent offline evidence after-snapshot failed on disappearing self-test temporary files and has no retrospective native receipt; a separate serialized offline receipt is qualified. The first failed guard-suite snapshot omitted the then-untracked new fixture; later complete scopes include it. A pagination-reader assertion was corrected without changing or rerunning its original API payload. Fresh validation and fixtures are not a historical legacy-output baseline.