Skip to content

Commit 2318ad5

Browse files
Merge pull request #1106 from angular/main
Create a new pull request by comparing changes across two branches.
2 parents c62579b + 7b8c9af commit 2318ad5

File tree

815 files changed

+24461
-35700
lines changed

Some content is hidden

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

815 files changed

+24461
-35700
lines changed

.aspect/rules/external_repository_action_cache/npm_translate_lock_MzA5NzUwNzMx

Lines changed: 0 additions & 22 deletions
This file was deleted.

.bazelignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,3 +16,5 @@ packages/angular_devkit/schematics_cli/node_modules
1616
packages/ngtools/webpack/node_modules
1717
packages/schematics/angular/node_modules
1818
modules/testing/builder/node_modules
19+
tests/node_modules
20+
tools/baseline_browserslist/node_modules

.bazelrc

Lines changed: 18 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -33,18 +33,14 @@ test:no-sharding --flaky_test_attempts=1 --test_sharding_strategy=disabled
3333
# See https://github.com/bazelbuild/bazel/issues/4603
3434
build --symlink_prefix=dist/
3535

36-
# Disable watchfs as it causes tests to be flaky on Windows
37-
# https://github.com/angular/angular/issues/29541
38-
build --nowatchfs
39-
4036
# Turn off legacy external runfiles
4137
build --nolegacy_external_runfiles
4238

4339
# Turn on --incompatible_strict_action_env which was on by default
4440
# in Bazel 0.21.0 but turned off again in 0.22.0. Follow
4541
# https://github.com/bazelbuild/bazel/issues/7026 for more details.
4642
# This flag is needed to so that the bazel cache is not invalidated
47-
# when running bazel via `yarn bazel`.
43+
# when running bazel via `pnpm bazel`.
4844
# See https://github.com/angular/angular/issues/27514.
4945
build --incompatible_strict_action_env
5046
run --incompatible_strict_action_env
@@ -56,9 +52,6 @@ build --experimental_remote_merkle_tree_cache
5652
# Ensure that tags applied in BUILDs propagate to actions
5753
common --experimental_allow_tags_propagation
5854

59-
# Don't check if output files have been modified
60-
build --noexperimental_check_output_files
61-
6255
# Ensure sandboxing is enabled even for exclusive tests
6356
test --incompatible_exclusive_test_sandboxed
6457

@@ -87,14 +80,14 @@ test:saucelabs --define=KARMA_WEB_TEST_MODE=SL_REQUIRED
8780
# Releases should always be stamped with version control info
8881
# This command assumes node on the path and is a workaround for
8982
# https://github.com/bazelbuild/bazel/issues/4802
90-
build:release --workspace_status_command="yarn ng-dev release build-env-stamp --mode=release"
83+
build:release --workspace_status_command="pnpm -s ng-dev release build-env-stamp --mode=release"
9184
build:release --stamp
9285

93-
build:snapshot --workspace_status_command="yarn ng-dev release build-env-stamp --mode=snapshot"
86+
build:snapshot --workspace_status_command="pnpm -s ng-dev release build-env-stamp --mode=snapshot"
9487
build:snapshot --stamp
9588
build:snapshot --//:enable_snapshot_repo_deps
9689

97-
build:e2e --workspace_status_command="yarn ng-dev release build-env-stamp --mode=release"
90+
build:e2e --workspace_status_command="pnpm -s ng-dev release build-env-stamp --mode=release"
9891
build:e2e --stamp
9992
test:e2e --test_timeout=3600 --experimental_ui_max_stdouterr_bytes=2097152
10093

@@ -133,12 +126,13 @@ build:remote --jobs=150
133126

134127
# Setup the toolchain and platform for the remote build execution. The platform
135128
# is provided by the shared dev-infra package and targets k8 remote containers.
136-
build:remote --extra_execution_platforms=@npm//@angular/build-tooling/bazel/remote-execution:platform_with_network
137-
build:remote --host_platform=@npm//@angular/build-tooling/bazel/remote-execution:platform_with_network
138-
build:remote --platforms=@npm//@angular/build-tooling/bazel/remote-execution:platform_with_network
129+
build:remote --extra_execution_platforms=@devinfra//bazel/remote-execution:platform_with_network
130+
build:remote --host_platform=@devinfra//bazel/remote-execution:platform_with_network
131+
build:remote --platforms=@devinfra//bazel/remote-execution:platform_with_network
139132

140133
# Set remote caching settings
141134
build:remote --remote_accept_cached=true
135+
build:remote --remote_upload_local_results=false
142136

143137
# Force remote executions to consider the entire run as linux.
144138
# This is required for OSX cross-platform RBE.
@@ -151,21 +145,16 @@ build:remote --google_default_credentials
151145
# Use HTTP remote cache
152146
build:remote-cache --remote_cache=https://storage.googleapis.com/angular-team-cache
153147
build:remote-cache --remote_accept_cached=true
154-
build:remote-cache --remote_upload_local_results=true
148+
build:remote-cache --remote_upload_local_results=false
155149
build:remote-cache --google_default_credentials
156150

157-
###############################
158-
# NodeJS rules settings
159-
# These settings are required for rules_nodejs
160-
###############################
151+
# Additional flags added when running a "trusted build" with additional access
152+
build:trusted-build --remote_upload_local_results=true
161153

162-
# Fixes use of npm paths with spaces such as some within the puppeteer module
154+
# Fixes issues with browser archives and files with spaces. Could be
155+
# removed in Bazel 8 when Bazel runfiles supports spaces.
163156
build --experimental_inprocess_symlink_creation
164157

165-
# Enable runfiles even on Windows.
166-
# Architect resolves output files from data files, and this isn't possible without runfile support.
167-
build --enable_runfiles
168-
169158
####################################################
170159
# rules_js specific flags
171160
####################################################
@@ -174,6 +163,11 @@ build --enable_runfiles
174163
# Prevents the npm package extract from occuring or caching on RBE which overwhelms our quota
175164
build --modify_execution_info=NpmPackageExtract=+no-remote
176165

166+
# Allow the Bazel server to check directory sources for changes. `rules_js` previously
167+
# heavily relied on this, but still uses directory "inputs" in some cases.
168+
# See: https://github.com/aspect-build/rules_js/issues/1408.
169+
startup --host_jvm_args=-DBAZEL_TRACK_SOURCE_DIRECTORIES=1
170+
177171
####################################################
178172
# User bazel configuration
179173
# NOTE: This needs to be the *last* entry in the config.

.bazelversion

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
6.5.0
1+
7.6.1

.eslintrc.json

Lines changed: 0 additions & 150 deletions
This file was deleted.
Lines changed: 78 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,78 @@
1+
name: 'Native Windows Bazel e2e test'
2+
description: 'Runs an Angular CLI e2e Bazel test on native Windows (dispatched from inside WSL)'
3+
author: 'Angular'
4+
5+
inputs:
6+
test_target_name:
7+
description: E2E test target name
8+
required: true
9+
test_args:
10+
description: |
11+
Text representing the command line arguments that
12+
should be passed to the e2e test runner.
13+
required: false
14+
default: ''
15+
16+
runs:
17+
using: composite
18+
steps:
19+
- name: Initialize WSL
20+
id: init_wsl
21+
uses: angular/dev-infra/github-actions/setup-wsl@43b8195028f62c7a10f793a0f7c48893531a32dc
22+
with:
23+
wsl_firewall_interface: 'vEthernet (WSL (Hyper-V firewall))'
24+
25+
- name: Installing pnpm (in WSL)
26+
run: npm install -g pnpm@9
27+
shell: wsl-bash {0}
28+
29+
- name: Install node modules in WSL (re-using from previous install/cache restore)
30+
run: |
31+
cd ${{steps.init_wsl.outputs.repo_path}}
32+
pnpm install --frozen-lockfile
33+
shell: wsl-bash {0}
34+
35+
- name: Build test binary for Windows (inside WSL)
36+
shell: wsl-bash {0}
37+
run: |
38+
cd ${{steps.init_wsl.outputs.repo_path}}
39+
pnpm bazel \
40+
build --config=e2e //tests/legacy-cli:${{inputs.test_target_name}} --platforms=tools:windows_x64
41+
env:
42+
# See: https://devblogs.microsoft.com/commandline/share-environment-vars-between-wsl-and-windows
43+
WSLENV: 'GOOGLE_APPLICATION_CREDENTIALS/p'
44+
45+
- name: Copying binary artifact to host
46+
shell: wsl-bash {0}
47+
run: |
48+
cd ${{steps.init_wsl.outputs.repo_path}}
49+
tar -cf /tmp/test.tar.gz dist/bin/tests/legacy-cli/${{inputs.test_target_name}}_
50+
mkdir /mnt/c/test
51+
mv /tmp/test.tar.gz /mnt/c/test
52+
(cd /mnt/c/test && tar -xf /mnt/c/test/test.tar.gz)
53+
54+
- name: Convert symlinks for Windows host
55+
shell: wsl-bash {0}
56+
run: |
57+
cd ${{steps.init_wsl.outputs.repo_path}}
58+
59+
runfiles_dir="/mnt/c/test/dist/bin/tests/legacy-cli/${{inputs.test_target_name}}_/${{inputs.test_target_name}}.bat.runfiles"
60+
61+
# Make WSL symlinks compatible on Windows native file system.
62+
node scripts/windows-testing/convert-symlinks.mjs $runfiles_dir "${{steps.init_wsl.outputs.cmd_path}}"
63+
64+
# Needed for resolution because Aspect/Bazel looks for repositories at `<workspace>/external`.
65+
# TODO(devversion): consult with Aspect on why this is needed.
66+
(cd $runfiles_dir/_main && ${{steps.init_wsl.outputs.cmd_path}} /C "mklink /D external ..")
67+
68+
- name: Run tests
69+
# Note: This is Git Bash.
70+
shell: bash
71+
env:
72+
BAZEL_BINDIR: '.'
73+
working-directory: "C:\\test"
74+
run: |
75+
node "${{github.workspace}}\\scripts\\windows-testing\\parallel-executor.mjs" \
76+
$PWD/dist/bin/tests/legacy-cli/${{inputs.test_target_name}}_/${{inputs.test_target_name}}.bat.runfiles \
77+
${{inputs.test_target_name}} \
78+
"${{inputs.test_args}}" \

.github/workflows/assistant-to-the-branch-manager.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,6 @@ jobs:
1616
- uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
1717
with:
1818
persist-credentials: false
19-
- uses: angular/dev-infra/github-actions/branch-manager@15db94d9a481826aed42ecf761c263c981931c9c
19+
- uses: angular/dev-infra/github-actions/branch-manager@43b8195028f62c7a10f793a0f7c48893531a32dc
2020
with:
2121
angular-robot-key: ${{ secrets.ANGULAR_ROBOT_PRIVATE_KEY }}

0 commit comments

Comments
 (0)