Skip to content
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

incompatible_disallow_native_in_build_file: Forbid native module in BUILD files #7513

Closed
laurentlb opened this issue Feb 22, 2019 · 1 comment
Assignees
Labels
incompatible-change Incompatible/breaking change P1 I'll work on this now. (Assignee required)

Comments

@laurentlb
Copy link
Contributor

The native module was created to access BUILD file functions in bzl files.

The native module has been exposed by accident to BUILD files. We are going to remove it from BUILD files, and keep it only in bzl files.
Fixing the issue should be trivial, e.g.

- native.cc_library(
+ cc_library(
-    srcs = native.glob(["*.java"])
+    srcs = glob(["*.java"])

The fix is mechanical, it can be fixed automatically using:
buildifier --lint=fix file.bzl

@laurentlb laurentlb added P1 I'll work on this now. (Assignee required) team-Starlark incompatible-change Incompatible/breaking change labels Feb 22, 2019
bazel-io pushed a commit that referenced this issue Feb 22, 2019
…ve module in BUILD files

#7513

RELNOTES:
  Using the `native` module in BUILD files is deprecated. It will be forbidden with --incompatible_disallow_native_in_build_file.
PiperOrigin-RevId: 235207912
@laurentlb laurentlb self-assigned this Feb 28, 2019
@katre
Copy link
Member

katre commented Mar 1, 2019

I am assuming the migration window is one release: if this is not the case please let me know.

bazel-io pushed a commit that referenced this issue May 23, 2019
*** Reason for rollback ***

Breaks tests [GOOGLE] testing head Blaze against the depot which hasn't been migrated yet.

*** Original change description ***

Flip the --incompatible_disallow_native_in_build_file flag

Fixes #7513

RELNOTES[INC]: The "native" module is no longer available in BUILD files, all its members can be accessed directly as global symbols. This can be temporarily reverted by providing --incompatible_disallow_native_in_build_file=false as a flag to Blaze.

PiperOrigin-RevId: 249639134
bazel-io pushed a commit that referenced this issue May 28, 2019
Fixes #7513

RELNOTES[INC]: The "native" module is no longer available in BUILD files, all its members can be accessed directly as global symbols. This can be temporarily reverted by providing --incompatible_disallow_native_in_build_f...

PiperOrigin-RevId: 250284808
bazel-io pushed a commit that referenced this issue Jun 13, 2019
#7513

RELNOTES: None.
PiperOrigin-RevId: 253062497
irengrig pushed a commit to irengrig/bazel that referenced this issue Jun 18, 2019
Fixes bazelbuild#7513

RELNOTES[INC]: The "native" module is no longer available in BUILD files, all its members can be accessed directly as global symbols. This can be temporarily reverted by providing --incompatible_disallow_native_in_build_file=false as a flag to Blaze.

PiperOrigin-RevId: 249508813
irengrig pushed a commit to irengrig/bazel that referenced this issue Jun 18, 2019
*** Reason for rollback ***

Breaks tests [GOOGLE] testing head Blaze against the depot which hasn't been migrated yet.

*** Original change description ***

Flip the --incompatible_disallow_native_in_build_file flag

Fixes bazelbuild#7513

RELNOTES[INC]: The "native" module is no longer available in BUILD files, all its members can be accessed directly as global symbols. This can be temporarily reverted by providing --incompatible_disallow_native_in_build_file=false as a flag to Blaze.

PiperOrigin-RevId: 249639134
irengrig pushed a commit to irengrig/bazel that referenced this issue Jun 18, 2019
Fixes bazelbuild#7513

RELNOTES[INC]: The "native" module is no longer available in BUILD files, all its members can be accessed directly as global symbols. This can be temporarily reverted by providing --incompatible_disallow_native_in_build_f...

PiperOrigin-RevId: 250284808
irengrig pushed a commit to irengrig/bazel that referenced this issue Jun 18, 2019
siberex pushed a commit to siberex/bazel that referenced this issue Jul 4, 2019
irengrig pushed a commit to irengrig/bazel that referenced this issue Jul 15, 2019
*** Reason for rollback ***

Breaks tests [GOOGLE] testing head Blaze against the depot which hasn't been migrated yet.

*** Original change description ***

Flip the --incompatible_disallow_native_in_build_file flag

Fixes bazelbuild#7513

RELNOTES[INC]: The "native" module is no longer available in BUILD files, all its members can be accessed directly as global symbols. This can be temporarily reverted by providing --incompatible_disallow_native_in_build_file=false as a flag to Blaze.

PiperOrigin-RevId: 249639134
irengrig pushed a commit to irengrig/bazel that referenced this issue Jul 15, 2019
Fixes bazelbuild#7513

RELNOTES[INC]: The "native" module is no longer available in BUILD files, all its members can be accessed directly as global symbols. This can be temporarily reverted by providing --incompatible_disallow_native_in_build_f...

PiperOrigin-RevId: 250284808
irengrig pushed a commit to irengrig/bazel that referenced this issue Jul 15, 2019
celskeggs pushed a commit to sipb/homeworld that referenced this issue Sep 3, 2019
An upgrade to upstream bazel exposed an error in one of our BUILD
files:
 - bazelbuild/bazel#7513
celskeggs pushed a commit to sipb/homeworld that referenced this issue Sep 4, 2019
An upgrade to upstream bazel exposed an error in one of our BUILD
files:
 - bazelbuild/bazel#7513
luca-digrazia pushed a commit to luca-digrazia/DatasetCommitsDiffSearch that referenced this issue Sep 4, 2022
luca-digrazia pushed a commit to luca-digrazia/DatasetCommitsDiffSearch that referenced this issue Sep 4, 2022
…ive module in BUILD files

    bazelbuild/bazel#7513

    RELNOTES:
      Using the `native` module in BUILD files is deprecated. It will be forbidden with --incompatible_disallow_native_in_build_file.
    PiperOrigin-RevId: 235207912
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
incompatible-change Incompatible/breaking change P1 I'll work on this now. (Assignee required)
Projects
None yet
Development

No branches or pull requests

2 participants