Skip to content

Commit

Permalink
build: update rules_js and pnpm version (scionproto#4568)
Browse files Browse the repository at this point in the history
Updated tooling allows to use lockfile version 9 in pnpm-lock.yaml.
We've recently seen that dependabot PRs for dependency updates seem to
create lock files with that lockfile version; as the tooling did not
support it, the dependabot changes could not be used. Plausibly,
dependabot PRs will work after this change.

Note that pnpm cannot be upgraded to the very latest version 9.5.0, as
this needs to be explicitly enabled in aspect_rules_js first.

Note that I've explicitly "downgraded" the nodejs node_version to the
default version used in the previous rules_nodejs version. The default
version of the current rules_nodjs version requires a too new glibc for
my ancient setup.

This might be hard to review manually because of all the formatting
changes in pnpm-lock.yaml.
Comparing only the lines that contain the sha512 checksums shows no diff
to master, which to me seems to indicate that the exact same versions of
all the dependencies are still used.
  • Loading branch information
matzf authored Jul 12, 2024
1 parent 60b4932 commit 36128d6
Show file tree
Hide file tree
Showing 4 changed files with 2,198 additions and 1,734 deletions.
17 changes: 9 additions & 8 deletions WORKSPACE
Original file line number Diff line number Diff line change
Expand Up @@ -28,9 +28,9 @@ lint_setup({

http_archive(
name = "aspect_bazel_lib",
sha256 = "a185ccff9c1b8589c63f66d7eb908de15c5d6bb05562be5f46336c53e7a7326a",
strip_prefix = "bazel-lib-2.0.0-rc1",
url = "https://github.com/aspect-build/bazel-lib/releases/download/v2.0.0-rc1/bazel-lib-v2.0.0-rc1.tar.gz",
sha256 = "714cf8ce95a198bab0a6a3adaffea99e929d2f01bf6d4a59a2e6d6af72b4818c",
strip_prefix = "bazel-lib-2.7.8",
url = "https://github.com/aspect-build/bazel-lib/releases/download/v2.7.8/bazel-lib-v2.7.8.tar.gz",
)

load("@aspect_bazel_lib//lib:repositories.bzl", "aspect_bazel_lib_dependencies", "aspect_bazel_lib_register_toolchains")
Expand Down Expand Up @@ -257,9 +257,9 @@ install_python_lint_deps()

http_archive(
name = "aspect_rules_js",
sha256 = "a949d56fed8fa0a8dd82a0a660acc949253a05b2b0c52a07e4034e27f11218f6",
strip_prefix = "rules_js-1.33.1",
url = "https://github.com/aspect-build/rules_js/releases/download/v1.33.1/rules_js-v1.33.1.tar.gz",
sha256 = "a723815986f3dd8b2c58d0ea76fde0ed56eed65de3212df712e631e5fc7d8790",
strip_prefix = "rules_js-2.0.0-rc6",
url = "https://github.com/aspect-build/rules_js/releases/download/v2.0.0-rc6/rules_js-v2.0.0-rc6.tar.gz",
)

load("@aspect_rules_js//js:repositories.bzl", "rules_js_dependencies")
Expand All @@ -270,14 +270,15 @@ load("@rules_nodejs//nodejs:repositories.bzl", "DEFAULT_NODE_VERSION", "nodejs_r

nodejs_register_toolchains(
name = "nodejs",
node_version = DEFAULT_NODE_VERSION,
node_version = "16.19.0", # use DEFAULT_NODE_VERSION from previous version rules_nodejs; the current version links against too new glibc
)

load("@aspect_rules_js//npm:npm_import.bzl", "npm_translate_lock")
load("@aspect_rules_js//npm:repositories.bzl", "npm_translate_lock")

npm_translate_lock(
name = "npm",
pnpm_lock = "@com_github_scionproto_scion//private/mgmtapi/tools:pnpm-lock.yaml",
pnpm_version = "9.4.0",
verify_node_modules_ignored = "@com_github_scionproto_scion//:.bazelignore",
)

Expand Down
18 changes: 18 additions & 0 deletions licenses/data/coreutils_linux_amd64/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
Copyright (c) uutils developers

Permission is hereby granted, free of charge, to any person obtaining a copy of
this software and associated documentation files (the "Software"), to deal in
the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software is furnished to do so,
subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
1 change: 1 addition & 0 deletions private/mgmtapi/tools/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
"@stoplight/spectral-cli": "^6.11.1"
},
"pnpm": {
"onlyBuiltDependencies": [],
"packageExtensions": {
"styled-components@5.3.11": {
"dependencies": {
Expand Down
Loading

0 comments on commit 36128d6

Please sign in to comment.