bazelbuild / bazel-skylib

Common useful functions and rules for Bazel
https://bazel.build/
Apache License 2.0
387 stars 180 forks source link

Error in rule: Use of Starlark transition without allowlist attribute '_allowlist_function_transition' with Bazel@HEAD #469

Closed sgowroji closed 10 months ago

sgowroji commented 10 months ago

https://buildkite.com/bazel/bazel-at-head-plus-downstream/builds/3388#018b36a4-b294-45e2-89d8-be5c2bebf631

Platform : Multiple

Logs:

ERROR: Traceback (most recent call last):
    File "/var/lib/buildkite-agent/.cache/bazel/_bazel_buildkite-agent/9f810845f19b78a657258e912e02a888/external/io_bazel_rules_go/go/private/context.bzl", line 556, column 23, in <toplevel>
        go_context_data = rule(
Error in rule: Use of Starlark transition without allowlist attribute '_allowlist_function_transition'. See Starlark transitions documentation for details and usage: @io_bazel_rules_go//go/private:context.bzl NORMAL
(02:03:23) INFO: Repository rules_java instantiated at:
  /var/lib/buildkite-agent/builds/bk-docker-28rd/bazel-downstream-projects/bazel-skylib/WORKSPACE:39:21: in <toplevel>
  /var/lib/buildkite-agent/.cache/bazel/_bazel_buildkite-agent/9f810845f19b78a657258e912e02a888/external/io_bazel_stardoc/setup.bzl:34:28: in stardoc_repositories
  /var/lib/buildkite-agent/.cache/bazel/_bazel_buildkite-agent/9f810845f19b78a657258e912e02a888/external/io_bazel_stardoc/setup.bzl:21:18: in _include_if_not_defined
Repository rule http_archive defined at:
  /var/lib/buildkite-agent/.cache/bazel/_bazel_buildkite-agent/9f810845f19b78a657258e912e02a888/external/bazel_tools/tools/build_defs/repo/http.bzl:379:31: in <toplevel>
(02:03:23) ERROR: Skipping '@bazel_skylib_gazelle_plugin//...': error loading package under directory '': error loading package '@bazel_skylib_gazelle_plugin//bzl': at /var/lib/buildkite-agent/.cache/bazel/_bazel_buildkite-agent/9f810845f19b78a657258e912e02a888/external/io_bazel_rules_go/go/def.bzl:26:5: initialization of module 'go/private/context.bzl' failed
(02:03:23) ERROR: error loading package under directory '': error loading package '@bazel_skylib_gazelle_plugin//bzl': at /var/lib/buildkite-agent/.cache/bazel/_bazel_buildkite-agent/9f810845f19b78a657258e912e02a888/external/io_bazel_rules_go/go/def.bzl:26:5: initialization of module 'go/private/context.bzl' failed

Steps:

git clone -v https://github.com/bazelbuild/bazel-skylib.git
git reset 652c8f0b2817daaa2570b7a3b2147643210f7dc7 --hard
export USE_BAZEL_VERSION=0adcc8db4c368f30dc4ef048c421ab0911a1023c
bazel build //... @bazel_skylib_gazelle_plugin//...

CC Greenteam @fweikert

sgowroji commented 10 months ago

@tetromino Can you take a look ?

tetromino commented 10 months ago

@tetromino Can you take a look ?

I'm sorry, on baby bonding leave until mid January; I only have time to occasionally check my messages.

Please ask @brandjon and (for gazelle errors, which seems to be the case here) @achew22

keith commented 10 months ago

seems like this was fixed, likely by https://github.com/bazelbuild/bazel-skylib/commit/d17d36915c1c1a3d6be70131bd1558524338653c