Skip to content

build: fix devserver sh_binary not working on systems with runfiles enabled #23721

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

Merged
merged 1 commit into from
Oct 11, 2021

Conversation

devversion
Copy link
Member

The devserver currently does not work on systems with runfiles enabled.
This is commonly macOS and Linux. The devserver breaks here because we
do not have a runfile tree directory built as this would cause a significant
slow-down for RBE and caching.

This commit ensures the runfile manifest is consulted always, unless the
dev-server runs in a test where a runfile directory is resolved to the test
directory.

Inside the test action, with runfiles enabled, there would be no runfile
manifest file.. causing the devserver to fail. e.g.

/b/f/w/bazel-out/k8-fastbuild/bin/src/material-experimental/mdc-table/e2e_tests_chromium.sh.runfiles/angular_material/tools/dev-server/dev-server_bin.sh: line 52: RUNFILES_MANIFEST_FILE: unbound variable

…nabled

The devserver currently does not work on systems with runfiles enabled.
This is commonly macOS and Linux. The devserver breaks here because we
do not have a runfile tree directory built as this would cause a significant
slow-down for RBE and caching.

This commit ensures the runfile manifest is consulted _always_, unless the
dev-server runs in a test where a runfile directory is resolved to the test
directory.

Inside the test action, with runfiles enabled, there would be no runfile
manifest file.. causing the devserver to fail. e.g.

```
/b/f/w/bazel-out/k8-fastbuild/bin/src/material-experimental/mdc-table/e2e_tests_chromium.sh.runfiles/angular_material/tools/dev-server/dev-server_bin.sh: line 52: RUNFILES_MANIFEST_FILE: unbound variable

```
@devversion devversion requested a review from a team as a code owner October 9, 2021 09:01
@google-cla google-cla bot added the cla: yes PR author has agreed to Google's Contributor License Agreement label Oct 9, 2021
@devversion devversion added merge safe target: rc This PR is targeted for the next release-candidate labels Oct 9, 2021
Copy link
Member

@crisbeto crisbeto left a comment

Choose a reason for hiding this comment

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

LGTM

@devversion devversion added the action: merge The PR is ready for merge by the caretaker label Oct 9, 2021
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.

LGTM

@zarend zarend merged commit 83da73f into angular:master Oct 11, 2021
zarend pushed a commit that referenced this pull request Oct 11, 2021
…nabled (#23721)

The devserver currently does not work on systems with runfiles enabled.
This is commonly macOS and Linux. The devserver breaks here because we
do not have a runfile tree directory built as this would cause a significant
slow-down for RBE and caching.

This commit ensures the runfile manifest is consulted _always_, unless the
dev-server runs in a test where a runfile directory is resolved to the test
directory.

Inside the test action, with runfiles enabled, there would be no runfile
manifest file.. causing the devserver to fail. e.g.

```
/b/f/w/bazel-out/k8-fastbuild/bin/src/material-experimental/mdc-table/e2e_tests_chromium.sh.runfiles/angular_material/tools/dev-server/dev-server_bin.sh: line 52: RUNFILES_MANIFEST_FILE: unbound variable

```

(cherry picked from commit 83da73f)
@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 Nov 11, 2021
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 cla: yes PR author has agreed to Google's Contributor License Agreement target: rc This PR is targeted for the next release-candidate
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants