diff options
Diffstat (limited to 'examples/py_native')
-rw-r--r-- | examples/py_native/BUILD | 3 | ||||
-rw-r--r-- | examples/py_native/bin.py | 2 | ||||
-rw-r--r-- | examples/py_native/fail.py | 2 | ||||
-rw-r--r-- | examples/py_native/test.py | 2 |
4 files changed, 3 insertions, 6 deletions
diff --git a/examples/py_native/BUILD b/examples/py_native/BUILD index aafa7b77c7..9d52fd6848 100644 --- a/examples/py_native/BUILD +++ b/examples/py_native/BUILD @@ -10,7 +10,6 @@ filegroup( py_binary( name = "bin", srcs = ["bin.py"], - legacy_create_init = False, deps = [ ":lib", "//examples/py_native/fibonacci", @@ -25,7 +24,6 @@ py_library( py_test( name = "test", srcs = ["test.py"], - legacy_create_init = False, deps = [ ":lib", "//examples/py_native/fibonacci", @@ -35,6 +33,5 @@ py_test( py_test( name = "fail", srcs = ["fail.py"], - legacy_create_init = False, deps = [":lib"], ) diff --git a/examples/py_native/bin.py b/examples/py_native/bin.py index b7e1223988..45c68b26e5 100644 --- a/examples/py_native/bin.py +++ b/examples/py_native/bin.py @@ -1,7 +1,7 @@ # pylint: disable=superfluous-parens """A tiny example binary for the native Python rules of Bazel.""" +from examples.py_native.lib import GetNumber from fib import Fib -from lib import GetNumber print("The number is %d" % GetNumber()) print("Fib(5) == %d" % Fib(5)) diff --git a/examples/py_native/fail.py b/examples/py_native/fail.py index a505ac41aa..98e35f4ee7 100644 --- a/examples/py_native/fail.py +++ b/examples/py_native/fail.py @@ -1,6 +1,6 @@ """A tiny example binary for the native Python rules of Bazel.""" import unittest -from lib import GetNumber +from examples.py_native.lib import GetNumber class TestGetNumber(unittest.TestCase): diff --git a/examples/py_native/test.py b/examples/py_native/test.py index b860940a38..f9543aa727 100644 --- a/examples/py_native/test.py +++ b/examples/py_native/test.py @@ -1,8 +1,8 @@ """A tiny example binary for the native Python rules of Bazel.""" import unittest +from examples.py_native.lib import GetNumber from fib import Fib -from lib import GetNumber class TestGetNumber(unittest.TestCase): |