{"action":"created","issue":{"url":"https://api.github.com/repos/bazelbuild/bazel/issues/4682","repository_url":"https://api.github.com/repos/bazelbuild/bazel","labels_url":"https://api.github.com/repos/bazelbuild/bazel/issues/4682/labels{/name}","comments_url":"https://api.github.com/repos/bazelbuild/bazel/issues/4682/comments","events_url":"https://api.github.com/repos/bazelbuild/bazel/issues/4682/events","html_url":"https://github.com/bazelbuild/bazel/issues/4682","id":299299301,"number":4682,"title":"NPE when running with --experimental_one_version_enforcement","user":{"login":"cgrushko","id":1998689,"avatar_url":"https://avatars1.githubusercontent.com/u/1998689?v=4","gravatar_id":"","url":"https://api.github.com/users/cgrushko","html_url":"https://github.com/cgrushko","followers_url":"https://api.github.com/users/cgrushko/followers","following_url":"https://api.github.com/users/cgrushko/following{/other_user}","gists_url":"https://api.github.com/users/cgrushko/gists{/gist_id}","starred_url":"https://api.github.com/users/cgrushko/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cgrushko/subscriptions","organizations_url":"https://api.github.com/users/cgrushko/orgs","repos_url":"https://api.github.com/users/cgrushko/repos","events_url":"https://api.github.com/users/cgrushko/events{/privacy}","received_events_url":"https://api.github.com/users/cgrushko/received_events","type":"User","site_admin":false},"labels":[{"id":392619077,"url":"https://api.github.com/repos/bazelbuild/bazel/labels/category:%20misc%20%3E%20misc","name":"category: misc > misc","color":"d4c5f9","default":false},{"id":106503259,"url":"https://api.github.com/repos/bazelbuild/bazel/labels/type:%20bug","name":"type: bug","color":"0052cc","default":false}],"state":"open","locked":false,"assignee":{"login":"nglorioso","id":565601,"avatar_url":"https://avatars3.githubusercontent.com/u/565601?v=4","gravatar_id":"","url":"https://api.github.com/users/nglorioso","html_url":"https://github.com/nglorioso","followers_url":"https://api.github.com/users/nglorioso/followers","following_url":"https://api.github.com/users/nglorioso/following{/other_user}","gists_url":"https://api.github.com/users/nglorioso/gists{/gist_id}","starred_url":"https://api.github.com/users/nglorioso/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nglorioso/subscriptions","organizations_url":"https://api.github.com/users/nglorioso/orgs","repos_url":"https://api.github.com/users/nglorioso/repos","events_url":"https://api.github.com/users/nglorioso/events{/privacy}","received_events_url":"https://api.github.com/users/nglorioso/received_events","type":"User","site_admin":false},"assignees":[{"login":"nglorioso","id":565601,"avatar_url":"https://avatars3.githubusercontent.com/u/565601?v=4","gravatar_id":"","url":"https://api.github.com/users/nglorioso","html_url":"https://github.com/nglorioso","followers_url":"https://api.github.com/users/nglorioso/followers","following_url":"https://api.github.com/users/nglorioso/following{/other_user}","gists_url":"https://api.github.com/users/nglorioso/gists{/gist_id}","starred_url":"https://api.github.com/users/nglorioso/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nglorioso/subscriptions","organizations_url":"https://api.github.com/users/nglorioso/orgs","repos_url":"https://api.github.com/users/nglorioso/repos","events_url":"https://api.github.com/users/nglorioso/events{/privacy}","received_events_url":"https://api.github.com/users/nglorioso/received_events","type":"User","site_admin":false}],"milestone":null,"comments":5,"created_at":"2018-02-22T10:30:36Z","updated_at":"2018-03-28T21:13:32Z","closed_at":null,"author_association":"MEMBER","body":"### Description of the problem / feature request:\r\n\r\nNPE when running:\r\n\r\n$ bazel build --nocheck_visibility --experimental_one_version_enforcement=error //my:target\r\n\r\n### Bugs: what's the simplest, easiest way to reproduce this bug? Please provide a minimal example if possible.\r\n\r\n$ bazel build --nocheck_visibility --experimental_one_version_enforcement=error //my:target\r\n\r\n### What operating system are you running Bazel on?\r\n\r\nLinux\r\n\r\n### What's the output of `bazel info release`?\r\n\r\nrelease 0.10.1\r\n\r\n### Any other information, logs, or outputs that you want to share?\r\n\r\nStack trace:\r\n\r\n```\r\njava.lang.RuntimeException: Unrecoverable error while evaluating node 'CONFIGURED_TARGET://my:target-redacted b23010847995f45ab4ebf1f7363f8718 (206086621 1631692719)' (requested by nodes )\r\n        at com.google.devtools.build.skyframe.AbstractParallelEvaluator$Evaluate.run(AbstractParallelEvaluator.java:414)\r\n        at com.google.devtools.build.lib.concurrent.AbstractQueueVisitor$WrappedRunnable.run(AbstractQueueVisitor.java:355)\r\n        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)\r\n        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)\r\n        at java.lang.Thread.run(Thread.java:745)\r\nCaused by: java.lang.NullPointerException\r\n        at com.google.common.base.Preconditions.checkNotNull(Preconditions.java:871)\r\n        at com.google.devtools.build.lib.collect.nestedset.NestedSetBuilder.add(NestedSetBuilder.java:61)\r\n        at com.google.devtools.build.lib.rules.java.DeployArchiveBuilder.build(DeployArchiveBuilder.java:345)\r\n        at com.google.devtools.build.lib.rules.java.JavaBinary.create(JavaBinary.java:406)\r\n        at com.google.devtools.build.lib.rules.java.JavaBinary.create(JavaBinary.java:62)\r\n        at com.google.devtools.build.lib.analysis.ConfiguredTargetFactory.createRule(ConfiguredTargetFactory.java:357)\r\n        at com.google.devtools.build.lib.analysis.ConfiguredTargetFactory.createConfiguredTarget(ConfiguredTargetFactory.java:234)\r\n        at com.google.devtools.build.lib.skyframe.SkyframeBuildView.createConfiguredTarget(SkyframeBuildView.java:513)\r\n        at com.google.devtools.build.lib.skyframe.ConfiguredTargetFunction.createConfiguredTarget(ConfiguredTargetFunction.java:616)\r\n        at com.google.devtools.build.lib.skyframe.ConfiguredTargetFunction.compute(ConfiguredTargetFunction.java:261)\r\n        at com.google.devtools.build.skyframe.AbstractParallelEvaluator$Evaluate.run(AbstractParallelEvaluator.java:340)\r\n        ... 4 more\r\njava.lang.RuntimeException: Unrecoverable error while evaluating node 'CONFIGURED_TARGET://my:target-redacted b23010847995f45ab4ebf1f7363f8718 (206086621 1631692719)' (requested by nodes )\r\n        at com.google.devtools.build.skyframe.AbstractParallelEvaluator$Evaluate.run(AbstractParallelEvaluator.java:414)\r\n        at com.google.devtools.build.lib.concurrent.AbstractQueueVisitor$WrappedRunnable.run(AbstractQueueVisitor.java:355)\r\n        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)\r\n        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)\r\n        at java.lang.Thread.run(Thread.java:745)\r\nCaused by: java.lang.NullPointerException\r\n        at com.google.common.base.Preconditions.checkNotNull(Preconditions.java:871)\r\n        at com.google.devtools.build.lib.collect.nestedset.NestedSetBuilder.add(NestedSetBuilder.java:61)\r\n        at com.google.devtools.build.lib.rules.java.DeployArchiveBuilder.build(DeployArchiveBuilder.java:345)\r\n        at com.google.devtools.build.lib.rules.java.JavaBinary.create(JavaBinary.java:406)\r\n        at com.google.devtools.build.lib.rules.java.JavaBinary.create(JavaBinary.java:62)\r\n        at com.google.devtools.build.lib.analysis.ConfiguredTargetFactory.createRule(ConfiguredTargetFactory.java:357)\r\n        at com.google.devtools.build.lib.analysis.ConfiguredTargetFactory.createConfiguredTarget(ConfiguredTargetFactory.java:234)\r\n        at com.google.devtools.build.lib.skyframe.SkyframeBuildView.createConfiguredTarget(SkyframeBuildView.java:513)\r\n        at com.google.devtools.build.lib.skyframe.ConfiguredTargetFunction.createConfiguredTarget(ConfiguredTargetFunction.java:616)\r\n        at com.google.devtools.build.lib.skyframe.ConfiguredTargetFunction.compute(ConfiguredTargetFunction.java:261)\r\n        at com.google.devtools.build.skyframe.AbstractParallelEvaluator$Evaluate.run(AbstractParallelEvaluator.java:340)\r\n        ... 4 more\r\n```"},"comment":{"url":"https://api.github.com/repos/bazelbuild/bazel/issues/comments/377038744","html_url":"https://github.com/bazelbuild/bazel/issues/4682#issuecomment-377038744","issue_url":"https://api.github.com/repos/bazelbuild/bazel/issues/4682","id":377038744,"user":{"login":"nglorioso","id":565601,"avatar_url":"https://avatars3.githubusercontent.com/u/565601?v=4","gravatar_id":"","url":"https://api.github.com/users/nglorioso","html_url":"https://github.com/nglorioso","followers_url":"https://api.github.com/users/nglorioso/followers","following_url":"https://api.github.com/users/nglorioso/following{/other_user}","gists_url":"https://api.github.com/users/nglorioso/gists{/gist_id}","starred_url":"https://api.github.com/users/nglorioso/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nglorioso/subscriptions","organizations_url":"https://api.github.com/users/nglorioso/orgs","repos_url":"https://api.github.com/users/nglorioso/repos","events_url":"https://api.github.com/users/nglorioso/events{/privacy}","received_events_url":"https://api.github.com/users/nglorioso/received_events","type":"User","site_admin":false},"created_at":"2018-03-28T21:13:32Z","updated_at":"2018-03-28T21:13:32Z","author_association":"CONTRIBUTOR","body":"Sorry folks! The feature is still under development (we're hashing out some issues with how strictly to enforce one version on java classes, for example: android resource files, and mechanisms to allow some sort of whitelisting process for codebases with existing violations who want to ease into enforcement).\r\n\r\nLooks like I'm missing a few precondition checks like https://github.com/bazelbuild/bazel/blob/0bf1413833ad78784771fefb468f080a53640136/src/main/java/com/google/devtools/build/lib/rules/java/OneVersionCheckActionBuilder.java#L81 in other places in the Bazel codebase."}}
{"actor":{"display_login":"nglorioso"}}