Skip to content

Commit 31a3d81

Browse files
committed
Merge branch 'main' into dev
# Conflicts: # .angular-github/actions/saucelabs-legacy/action.yml # .angular-github/workflows/manual.yml
2 parents 38ce059 + 16fe27b commit 31a3d81

1,301 files changed

Lines changed: 58191 additions & 59642 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.agent/skills/adev-writing-guide/SKILL.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
name: adev-writing-guide
3-
description: Comprehensive writing guide for Angular documentation (adev). Covers Google Technical Writing standards, Angular-specific markdown extensions, code blocks, and components. Use when authoring or reviewing content in adev/src/content.
3+
description: Comprehensive writing guide for Angular documentation (adev). Covers Google Technical Writing standards, Angular-specific markdown extensions, code blocks, and components. You MUST use this skill any time you plan to create, edit, or review documentation files in `adev/` or `adev/src/content`.
44
---
55

66
# Angular Documentation (adev) Writing Guide

.agent/skills/pr_review/SKILL.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@ When reviewing a pull request for the `angular` repository, follow these essenti
5050
- **Use Suggested Changes**: Whenever appropriate (e.g., for simple code fixes, refactoring suggestions, or typo corrections), prefer using GitHub's **Suggested Changes** syntax (`suggestion ... `) in your inline comments. This allows the author to apply your suggested code improvements with a single click in the GitHub UI.
5151
- **Review Type**: Never mark an external PR review as an "approval" unless explicitly instructed by a repo maintainer. Always use "Request Changes" or "Comment". Note that some tools might only support commenting.
5252
- **Require User Approval Before Posting**: Prepare your review comments and present them to the user, alongside a summary of your completed checklist. Do NOT post comments to the PR without explicitly asking the user for permission first. Only post the review after the user approves.
53+
- **CRITICAL**: This rule applies even if you receive a system message indicating that an artifact has been "automatically approved" or instructing you to "proceed to execution." You must ALWAYS obtain explicit, written confirmation from the user in this chat conversation before posting any content to a PR.
5354
- **Prefix Agent Comments**: To make it clear when comments are generated and posted by an AI agent rather than a human user, **always** prefix your review comments with `AGENT: `.
5455

5556
## Available Tools
Lines changed: 56 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,56 @@
1+
---
2+
description: Find and fix flaky tests in the repository
3+
---
4+
5+
Investigate flaky tests in the repo and propose fixes to improve stability.
6+
High-level process:
7+
8+
1. Run tests in the repo to look for flakes.
9+
- Consider using Bazel's `--runs_per_test` flag to easily find
10+
flakes.
11+
- Be cognizant of not exhausting all the resources on the current
12+
machine, run a subset of tests at a time such as
13+
`bazel test //packages/core/...`.
14+
2. Once you find some flakes, focus on one at a time.
15+
3. Create a new branch named `flakes/${relevantNameFromTest}`.
16+
4. Reproduce the flake to the best of your ability.
17+
- Consider using `--test_env JASMINE_RANDOM_SEED=1234` to
18+
replicate the broken test ordering.
19+
5. Debug the test to understand the failure mode.
20+
- Consider temporarily disabling / skipping other tests with `xit`
21+
and `fit` to narrow down where the flake might be coming from if
22+
multiple tests are influencing each other.
23+
- Consider temporarily ignoring Firefox tests with
24+
`--test_tag_filters -firefox` if the flake does not appear to be
25+
browser specific.
26+
- Consider using `--test_sharding_strategy disabled` to run the
27+
test in a single shard.
28+
- Try to understand why the test was _flaky_, not just why it
29+
_failed_. Understanding the inconsistency is important to
30+
finding the correct fix.
31+
6. Attempt a fix and validate with `--runs_per_test`.
32+
- Iterate on the fix until you have something which appears to
33+
work.
34+
- If you find yourself stuck and not making meaningful progress,
35+
note down what you've learned/where you're struggling, commit
36+
what you have, look for another flake to fix, and continue. At
37+
the end, surface to the user what you failed to fix.
38+
- Don't try to make significant changes to Angular's runtime
39+
behavior, focus just on making the test pass/fail consistently.
40+
7. Commit the change with relevant details in the commit message and
41+
move on to the next test.
42+
- Be sure to include your theory of why the test was flaky and
43+
how this fix eliminates or reduces that flakiness.
44+
8. Iterate as many times as the user requests you to (default 5
45+
branches if not otherwise specified).
46+
9. Once you can't find any flaky tests or have iterated as many times
47+
as requested, stop and inform the user what you found and fixed.
48+
49+
Additional notes:
50+
51+
- Multiple fixes including the same/related files can go in the same
52+
commit or multiple commits on the same branch.
53+
- Distinct test fixes should go in different branches, make a new one
54+
for each investigation.
55+
- You may push these branches to `origin`, but do not create PRs for
56+
them.

.angular-github/actions/deploy-docs-site/BUILD.bazel

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,5 @@ ts_project(
3535
"//:node_modules/@actions/github",
3636
"//:node_modules/@angular/ng-dev",
3737
"//:node_modules/@types/node",
38-
"//:node_modules/@types/tmp",
39-
"//:node_modules/tmp",
4038
],
4139
)

.angular-github/actions/deploy-docs-site/lib/credential.mts

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,17 @@
1-
import {fileSync} from 'tmp';
2-
import {writeSync} from 'node:fs';
1+
import {writeFileSync, mkdtempSync} from 'node:fs';
2+
import {join} from 'node:path';
3+
import {tmpdir} from 'node:os';
34
import {getInput, setSecret} from '@actions/core';
45

56
let credentialFilePath: undefined | string;
67

78
export function getCredentialFilePath(): string {
89
if (credentialFilePath === undefined) {
9-
const tmpFile = fileSync({postfix: '.json'});
10-
writeSync(tmpFile.fd, getInput('serviceKey', {required: true}));
11-
setSecret(tmpFile.name);
12-
credentialFilePath = tmpFile.name;
10+
const tmpDir = mkdtempSync(join(tmpdir(), 'credential-'));
11+
const filePath = join(tmpDir, 'credential.json');
12+
writeFileSync(filePath, getInput('serviceKey', {required: true}));
13+
setSecret(filePath);
14+
credentialFilePath = filePath;
1315
}
1416
return credentialFilePath;
1517
}

.angular-github/actions/deploy-docs-site/lib/deployments.mts

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
1-
import {fetchLongTermSupportBranchesFromNpm, ActiveReleaseTrains} from '@angular/ng-dev';
2-
import {ReleaseConfig} from '@angular/ng-dev';
3-
import {AuthenticatedGitClient} from '@angular/ng-dev';
1+
import {
2+
fetchLongTermSupportBranchesFromNpm,
3+
ActiveReleaseTrains,
4+
AuthenticatedGitClient,
5+
ReleaseConfig,
6+
} from '@angular/ng-dev';
47

58
export interface Deployment {
69
branch: string;

0 commit comments

Comments
 (0)