Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add testing for Bazel browser setup #397

Merged
merged 8 commits into from
Feb 12, 2022
Merged

Conversation

devversion
Copy link
Member

@devversion devversion commented Feb 9, 2022

See individual commits. A lot of things were coupled as some issues just surfaced due to cache invalidation and new CI executors. All of these issues are confirmed locally and they are reasonable (so nothing was flakiness!)

@devversion devversion force-pushed the browser-misc branch 5 times, most recently from 732c3ef to a25a177 Compare February 10, 2022 19:04
@devversion devversion marked this pull request as ready for review February 10, 2022 19:04
@devversion devversion added the action: review The PR is still awaiting reviews from at least one requested reviewer label Feb 10, 2022
@devversion
Copy link
Member Author

@josephperrott this would fix the firefox shasum error in FW

Copy link
Member

@josephperrott josephperrott left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall LGTM

Just a couple questions.

.circleci/config.yml Outdated Show resolved Hide resolved
.circleci/config.yml Outdated Show resolved Hide resolved
bazel/browsers/update-script/browser-artifact.ts Outdated Show resolved Hide resolved
The update script currently fails to detect the archive extensions
for Firefox since the substituted version in the download URL
causes no known extension to be discovered. The `97.0` period/dot
for example throws of the `extname` detection.
Adds a test for the Bazel browser configuration.
Fixes an invalid geckodriver checksum caused by a previously
invalid download (fixed in the previous commits).
This also fixes a pythion shebang issue with Linux:

bazelbuild/bazel@2945ef5.
Updates the bazelignore to exclude more integration node module folders
that could throw off tests when they exist locally. This can happen because
symlinks would be rewritten to hardlinks when the tests are running locally
in a sandbox --> resulting in e.g. `node_modules/.bin` to be broken for
bazelisk which uses `__dirname` and relies on symlink resolution/following.
Updates the test job resource class to match with the CircleCI Bazelrc
configurtion which explicitly sets the resources to `xlarge`.

Note: Looks like this is also needed looking at CPU and RAM:
https://app.circleci.com/pipelines/github/angular/dev-infra/123691/workflows/aba2854d-9866-4295-ad09-72e438a3fd8c/jobs/124876/resources
Firefox tests will run in the Bazel sandbox, but Firefox currently requires, regardless
of us specifying a custom profile directory, that the default profile directory exists.

I've tracked down the Firefox launch issue, created a standalone repro without Bazel for
Darwin, and submitted: https://bugzilla.mozilla.org/show_bug.cgi?id=1754821#c3

Until then, we can just make the test run on CI like this. This seems to be a long-standing
issue so it does not seem worth currently reworking the Bazel Karma rules, or browser setup
to workaround this. Most of the time folks can just run without sandbox, have launched firefox
before (resulting in the directory to be available), or they can use `--sandbox_writable_path`.

In any case though, this is something we'd need to do as a follow-up. The goal currently is
to just set up a CI job to ensure that the binaries are valid, and resolved by dev-infra.
@devversion devversion added action: merge The PR is ready for merge by the caretaker and removed action: review The PR is still awaiting reviews from at least one requested reviewer labels Feb 12, 2022
@devversion devversion merged commit 0e1a218 into angular:main Feb 12, 2022
@devversion devversion deleted the browser-misc branch February 12, 2022 09:11
@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Mar 15, 2022
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
action: merge The PR is ready for merge by the caretaker
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants