Skip to content

[housekeeping] Automated PR to fix formatting errors - #1

Closed
github-actions[bot] wants to merge 1 commit into
mainfrom
housekeeping/fix-codeformatting
Closed

[housekeeping] Automated PR to fix formatting errors#1
github-actions[bot] wants to merge 1 commit into
mainfrom
housekeeping/fix-codeformatting

Conversation

@github-actions

Copy link
Copy Markdown

Automated PR to fix formatting errors

@github-actions
github-actions Bot force-pushed the housekeeping/fix-codeformatting branch from 7c7aef6 to 2608120 Compare January 30, 2025 01:31
@github-actions
github-actions Bot force-pushed the housekeeping/fix-codeformatting branch 4 times, most recently from 3b1ac28 to ef66fc7 Compare February 4, 2025 01:32
@github-actions
github-actions Bot force-pushed the housekeeping/fix-codeformatting branch from ef66fc7 to 9063f35 Compare February 12, 2025 01:33
@github-actions
github-actions Bot force-pushed the housekeeping/fix-codeformatting branch from 9063f35 to 1ad8bc7 Compare February 28, 2025 01:44
NafeelaNazhir pushed a commit that referenced this pull request Jan 20, 2026
…tnet#33071)

App crashes because of changing a shared Drawable on the fly. I found
out it is the SearchBar. It only happens on Android and in large apps
with lots of screens. Unfortunately I can't reproduce it in the
TestSuite. But by reading the docs of Android this crash is common and
caused by changing a Drawable which is still referenced. With a custom
SearchBarHandler the issues is resolved.

```Backtrace (top frames):
  #00 pc 00000000006b8694  /system/lib64/libhwui.so
      android::getRootAlpha(_JNIEnv*, _jobject*, long) +4

  #1 pc 0000000002256c90  /memfd:jit-cache (deleted)
      art_jni_trampoline +112

  dotnet#2 pc 000000000223bc4c  /memfd:jit-cache (deleted)
      android.graphics.drawable.VectorDrawable.-$$Nest$smnGetRootAlpha +108

  dotnet#3 pc 000000000223bb20  /memfd:jit-cache (deleted)
      android.graphics.drawable.VectorDrawable$VectorDrawableState.getAlpha +144

  dotnet#4 pc 00000000025c50e0  /memfd:jit-cache (deleted)
      android.graphics.drawable.VectorDrawable.getAlpha +128

  dotnet#5 pc 00000000025c4f9c  /memfd:jit-cache (deleted)
      android.graphics.drawable.VectorDrawable.getOpacity +124

  dotnet#6 pc 00000000025c1ea8  /memfd:jit-cache (deleted)
      android.widget.ImageView.isOpaque +152

  dotnet#7 pc 000000000227979c  /memfd:jit-cache (deleted)
      android.view.View.invalidateInternal +428

  dotnet#8 pc 00000000025c4790  /memfd:jit-cache (deleted)
      android.widget.ImageView.invalidateDrawable +256

  dotnet#9 pc 000000000224419c  /memfd:jit-cache (deleted)
      android.graphics.drawable.Drawable.invalidateSelf +156

  dotnet#10 pc 000000000260e710  /memfd:jit-cache (deleted)
      android.graphics.drawable.VectorDrawable.setTintList +192

  dotnet#11 pc 00000000025d0094  /memfd:jit-cache (deleted)
      **android.graphics.drawable.Drawable.setTint +148**
```

### Description of Change

- Changes tinting of Androids SearchBar to unified setTint instead of
setColorFilter
-  Mutates the drawable before setting the tint.

### Issues Fixed
Issue is fixed with a custom handler for now.

Fixes dotnet#33070
NafeelaNazhir pushed a commit that referenced this pull request Feb 26, 2026
…es (dotnet#33963)

<!-- Please let the below note in for people that find this PR -->
> [!NOTE]
> Are you waiting for the changes in this PR to be merged?
> It would be very helpful if you could [test the resulting
artifacts](https://github.com/dotnet/maui/wiki/Testing-PR-Builds) from
this PR and let us know in a comment if this change resolves your issue.
Thank you!

## Description

Adds rule dotnet#2 to the Git Workflow section in copilot-instructions.md:

**When fixing CI or amending an existing PR, commit directly to the PR
branch.** Do not create a separate branch off a PR branch — the PR
branch already IS a feature branch. Creating a new branch means CI will
not run on the PR, defeating the purpose.

Also adds a code example showing the correct workflow (`gh pr checkout`
→ commit → push).

## Motivation

Copilot CLI was incorrectly creating separate branches when asked to fix
CI on existing PRs, because rule #1 ("never commit to main, create a
feature branch") was being over-generalized to PR branches. This caused
wasted time since CI only runs on PR branches.

---------

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Shane Neuville <shneuvil@microsoft.com>
NafeelaNazhir pushed a commit that referenced this pull request Jul 17, 2026
…dotnet#36461)

> [!NOTE]
> Are you waiting for the changes in this PR to be merged?
> It would be very helpful if you could [test the resulting
artifacts](https://github.com/dotnet/maui/wiki/Testing-PR-Builds) from
this PR and let us know in a comment if this change resolves your issue.
Thank you!

## What this changes

Follow-up to dotnet#36317 (the self-watching `ci-status-fix` loop). Today,
when a `[ci-fix]` draft PR's CI comes back green — or red only on
**unrelated** flakes — the loop posts a comment but **leaves the PR as a
draft forever**. A maintainer has to notice it, confirm the specific
fixed test actually passed, and flip it to ready. In practice these
validated-green draft PRs sit unreviewed for weeks.

This PR adds a **target-test verification + mark-ready gate (Step 3.6)**
to both twins (`main` + `net11.0`). When a draft `[ci-fix]` /
`[ci-fix-net11]` PR reaches the green-surface or unrelated-flake branch,
the loop now drills into the PR's **own** AzDO test-results for the
**specific test(s)** the fix targeted. If every target test is `Passed`
on ≥1 leg and `Failed` on none (VALIDATED-GREEN), it:

- posts a `🎯 Target test validated green on <headSha>` comment (naming
the test + legs + buildId), and
- transitions the draft PR to **ready for review**.

This is a **state transition only** — it never approves and never
merges; a human still reviews and merges. Overall red on **unrelated**
legs no longer keeps a validated fix parked as a draft.

## How it works

- **Preconditions** (all required): PR `isDraft == true`; it is
unmistakably this workflow's own PR (`[ci-fix]`/`[ci-fix-net11]` title
prefix **and** `agentic-workflows` label); and it was reached from the
green or **unrelated-flake** path (never from caused-by-fix — that path
advances an attempt instead).
- **T1 — identify target test(s)** from the `[ci-scan]` issue signature
+ the PR diff. If no specific test can be identified (e.g. a product
build-break), it records a skip — build-only fixes are validated by
overall-green, which the existing green branch already handles.
- **T2 — drill AzDO test-results** for the build(s) on the PR's current
head SHA, filtered to the target test's `testCaseTitle`. A test that
never ran (e.g. an `/azp`-gated `maui-pr-uitests`/`maui-pr-devicetests`
leg that wasn't kicked) is **not** validated — the loop records an
honest "not yet executed" skip and does **not** mark ready. No
overclaiming: a green *sibling* leg is not the target test.
- **T3 — mark ready + report**, guarded by a per-head-SHA idempotency
marker and the existing `dry_run` gate (dry-run emits nothing and
tallies `would-mark-ready`).

## Safe-output

Adds the `mark-pull-request-as-ready-for-review` safe-output to both
twins (`max: 3`, `target: "*"`, `required-title-prefix` +
`required-labels`). Unlike `update-pull-request`, this output's
`required-*` guards **do** survive the gh-aw v0.80.9 compile (verified
against the generated locks), so which-PR scoping is enforced at the
handler level in addition to the Step 3.6 preconditions and
`min-integrity: approved`. No gh-aw version bump is required — the
capability already exists at our pinned v0.80.9.

## Enabling fix — the loop's own create-PR commit no longer counts as
"human engaged"

While validating this feature against dotnet#36429 I found the mark-ready path
was **unreachable for every loop-owned draft PR**, and traced it to a
regression from dotnet#36317's own review-hardening.

gh-aw's `create_pull_request` builds a PR's initial commit through the
GitHub API, which stamps `author=github-actions[bot]` but
**`committer=web-flow`**. Commit `2f6b77b330` (in dotnet#36317) removed
`web-flow` from the prefetch's bot-login denylist so a maintainer
"Update branch" would correctly hand the PR off — but that also made
`Test-AnyHumanCommitActor`'s committer check read the loop's **own**
first commit as human engagement. Result: every freshly opened
`[ci-fix]` draft PR computed `humanEngaged=true` from commit #1, so the
watch loop skipped it forever — never surfacing green, never marking
ready. This regression is live on `main` today (all four open loop-owned
draft PRs have `committer=web-flow`).

Fix (`Query-CiFixPRs.ps1`): a human **committer** only trips the
hand-off when the commit **author** is not one of this workflow's own
bot identities (`$LoopBotCommitAuthors`). A human **author** still
counts unconditionally, so maintainer direct commits and
web-flow-authored "Update branch" merges continue to hand off correctly.
Unit-tested across all six author/committer shapes.

## Validation

- Both twins recompiled with `gh aw compile` (0 errors / 0 warnings);
locks show no action-SHA or `compiler_version` drift (only
frontmatter/body hash + the new handler config).
- `mark_pull_request_as_ready_for_review` config confirmed present in
**both** locks with the correct `[ci-fix] ` / `[ci-fix-net11] ` prefixes
and `agentic-workflows` label; the `safe_outputs` job carries
`pull-requests: write`.
- Twin symmetry preserved (only `[ci-fix]` ↔ `[ci-fix-net11]` /
`ci-scan` ↔ `ci-scan-net11` token differences).
- **Live dry-run against dotnet#36429** (scoped `workflow_dispatch`,
`dry_run=true`, this branch): the workflow prefetch now computes
`humanEngaged=false` for dotnet#36429 (was `true` pre-fix), and the agent's
gate walk correctly advances **past** the human-engaged gate to the
CI-pending WAIT gate — `checksSettled=false` because dotnet#36429's macOS
`SafeAreaEdges` leg is still queued. Once that leg settles green, the
same run path reaches Step 3.6 and marks the PR ready. Emitted zero
writes (dry-run).

Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>

---------

Co-authored-by: PureWeen <223556219+Copilot@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants