bazelbuild / rules_webtesting

Bazel rules to allow testing against a browser with WebDriver.
Apache License 2.0
97 stars 56 forks source link

[Bazel CI] Error: 'struct' value has no field or method 'to_json' #475

Closed sgowroji closed 6 months ago

sgowroji commented 7 months ago

CI: https://buildkite.com/bazel/bazel-at-head-plus-downstream/builds/3740#018e5f2f-8857-484c-944d-e6fe7355e74d

Platform: Multiple

Logs:

ERROR: /private/var/tmp/_bazel_buildkite/32696f2e4b06998450ed8fec732f2644/external/io_bazel_rules_scala/third_party/dependency_analyzer/src/main/BUILD:3:9: in scala_library_for_plugin_bootstrapping rule @@io_bazel_rules_scala//third_party/dependency_analyzer/src/main:scala_version:
Traceback (most recent call last):
    File "/private/var/tmp/_bazel_buildkite/32696f2e4b06998450ed8fec732f2644/external/io_bazel_rules_scala/scala/private/rules/scala_library.bzl", line 142, column 22, in _scala_library_for_plugin_bootstrapping_impl
        return run_phases(
    File "/private/var/tmp/_bazel_buildkite/32696f2e4b06998450ed8fec732f2644/external/io_bazel_rules_scala/scala/private/phases/api.bzl", line 45, column 23, in run_phases
        return _run_phases(ctx, builtin_customizable_phases, target = None)
    File "/private/var/tmp/_bazel_buildkite/32696f2e4b06998450ed8fec732f2644/external/io_bazel_rules_scala/scala/private/phases/api.bzl", line 77, column 32, in _run_phases
        new_provider = function(ctx, current_provider)
    File "/private/var/tmp/_bazel_buildkite/32696f2e4b06998450ed8fec732f2644/external/io_bazel_rules_scala/scala/private/phases/phase_default_info.bzl", line 20, column 23, in phase_default_info
        phase_names.remove("to_json")
Error in remove: item "to_json" not found in list

Culprit: bazelbuild/bazel@8f18d36

Steps:

 git clone https://github.com/bazelbuild/rules_webtesting
git reset ce5e6d63b23b01c2a71178ef764384f64a81ad23  --hard
export USE_BAZEL_VERSION=b100e4f1631da2d7c78621c040e88b7644985cd8
bazel build //... 

CC Greenteam @SalmaSamy

sgowroji commented 7 months ago

CC @c-mita

c-mita commented 7 months ago

rules_scala has a pending PR to fix the issue: https://github.com/bazelbuild/rules_scala/pull/1554

rules_webtesting will then need to update the version of rules_scala used to one that includes that change.