Skip to content

Commit 314447d

Browse files
committed
revert REPL-related things
1 parent 286b4f1 commit 314447d

File tree

5 files changed

+3
-39
lines changed

5 files changed

+3
-39
lines changed

python/bin/BUILD.bazel

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -9,16 +9,3 @@ label_flag(
99
name = "bin",
1010
build_setting_default = "//python:none",
1111
)
12-
13-
py_binary(
14-
name = "repl",
15-
srcs = ["repl.py"],
16-
deps = [
17-
":repl_dep",
18-
],
19-
)
20-
21-
label_flag(
22-
name = "repl_dep",
23-
build_setting_default = "//python:none",
24-
)

python/bin/repl.py

Lines changed: 0 additions & 17 deletions
This file was deleted.

python/private/sentinel.bzl

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,15 +18,13 @@ Label attributes with defaults cannot accept None, otherwise they fall
1818
back to using the default. A sentinel allows detecting an intended None value.
1919
"""
2020

21-
load(":py_info.bzl", "PyInfo")
22-
2321
SentinelInfo = provider(
2422
doc = "Indicates this was the sentinel target.",
2523
fields = [],
2624
)
2725

2826
def _sentinel_impl(ctx):
2927
_ = ctx # @unused
30-
return [SentinelInfo(), PyInfo(transitive_sources=depset())]
28+
return [SentinelInfo()]
3129

3230
sentinel = rule(implementation = _sentinel_impl)

python/private/site_init_template.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,6 @@
2727
# Runfiles-relative path to the coverage tool entry point, if any.
2828
_COVERAGE_TOOL = "%coverage_tool%"
2929

30-
print("Hi")
3130

3231
def _is_verbose():
3332
return bool(os.environ.get("RULES_PYTHON_BOOTSTRAP_VERBOSE"))

python/private/stage2_bootstrap_template.py

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -24,9 +24,6 @@
2424
# Runfiles-relative path to the main Python source file.
2525
MAIN = "%main%"
2626

27-
# Whether this script is used as a sitecustomize script.
28-
USED_AS_SITECUSTOMIZE = "%used_as_sitecustomize%"
29-
3027
# ===== Template substitutions end =====
3128

3229

@@ -378,8 +375,6 @@ def main():
378375
if runfiles_envkey:
379376
os.environ[runfiles_envkey] = runfiles_envvalue
380377

381-
sys.path[0:0] = prepend_path_entries
382-
383378
main_filename = os.path.join(module_space, main_rel_path)
384379
main_filename = get_windows_path_with_unc_prefix(main_filename)
385380
assert os.path.exists(main_filename), (
@@ -391,6 +386,8 @@ def main():
391386

392387
sys.stdout.flush()
393388

389+
sys.path[0:0] = prepend_path_entries
390+
394391
if os.environ.get("COVERAGE_DIR"):
395392
import _bazel_site_init
396393
coverage_enabled = _bazel_site_init.COVERAGE_SETUP

0 commit comments

Comments
 (0)