Skip to content

Commit b09b45f

Browse files
authored
Make TensorBoard work with latest Bazel (#590)
Fixes #585
1 parent 46c153f commit b09b45f

File tree

4 files changed

+37
-27
lines changed

4 files changed

+37
-27
lines changed

.travis.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ branches:
1515
- /^\d+\.\d+(\.\d+)?(-\S*)?$/
1616

1717
env:
18-
- BAZEL=0.5.1 TF=NIGHTLY
18+
- BAZEL=0.5.4 TF=NIGHTLY
1919

2020
cache:
2121
directories:

WORKSPACE

Lines changed: 25 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -2,38 +2,48 @@ workspace(name = "org_tensorflow_tensorboard")
22

33
http_archive(
44
name = "io_bazel_rules_closure",
5-
sha256 = "e9e2538b1f7f27de73fa2914b7d2cb1ce2ac01d1abe8390cfe51fb2558ef8b27",
6-
strip_prefix = "rules_closure-4c559574447f90751f05155faba4f3344668f666",
5+
sha256 = "110fe68753413777944b473c25eed6368c4a0487cee23a7bac1b13cc49d3e257",
6+
strip_prefix = "rules_closure-4af89ef1db659eb41f110df189b67d4cf14073e1",
77
urls = [
8-
"http://mirror.bazel.build/github.com/bazelbuild/rules_closure/archive/4c559574447f90751f05155faba4f3344668f666.tar.gz",
9-
"https://github.com/bazelbuild/rules_closure/archive/4c559574447f90751f05155faba4f3344668f666.tar.gz", # 2017-06-21
8+
"http://mirror.bazel.build/github.com/bazelbuild/rules_closure/archive/4af89ef1db659eb41f110df189b67d4cf14073e1.tar.gz",
9+
"https://github.com/bazelbuild/rules_closure/archive/4af89ef1db659eb41f110df189b67d4cf14073e1.tar.gz", # 2017-08-28
1010
],
1111
)
1212

13-
load("@io_bazel_rules_closure//closure:defs.bzl", "closure_repositories")
14-
15-
closure_repositories()
13+
http_archive(
14+
name = "io_bazel_rules_go",
15+
sha256 = "8c333df68fb0096221e2127eda2807384e00cc211ee7e7ea4ed08d212e6a69c1",
16+
strip_prefix = "rules_go-0.5.4",
17+
urls = [
18+
"http://mirror.bazel.build/github.com/bazelbuild/rules_go/archive/0.5.4.tar.gz",
19+
"https://github.com/bazelbuild/rules_go/archive/0.5.4.tar.gz",
20+
],
21+
)
1622

1723
http_archive(
1824
name = "io_bazel_rules_go",
19-
sha256 = "f7e42a4c1f9f31abff9b2bdee6fe4db18bc373287b7e07a5b844446e561e67e2",
20-
strip_prefix = "rules_go-4c9a52aba0b59511c5646af88d2f93a9c0193647",
25+
sha256 = "4781af250cd34ca10369124c82dc0b8d48633db709997cfb965dc779a205eaee",
26+
strip_prefix = "rules_go-aa9a9cfed3d23e2821807d90b288fecd9f68124c",
2127
urls = [
22-
"http://mirror.bazel.build/github.com/bazelbuild/rules_go/archive/4c9a52aba0b59511c5646af88d2f93a9c0193647.tar.gz", # 2017-05-05
23-
"https://github.com/bazelbuild/rules_go/archive/4c9a52aba0b59511c5646af88d2f93a9c0193647.tar.gz",
28+
"http://mirror.bazel.build/github.com/bazelbuild/rules_go/archive/aa9a9cfed3d23e2821807d90b288fecd9f68124c.tar.gz", # 2017-09-29
29+
"https://github.com/bazelbuild/rules_go/archive/aa9a9cfed3d23e2821807d90b288fecd9f68124c.tar.gz",
2430
],
2531
)
2632

2733
http_archive(
2834
name = "io_bazel_rules_webtesting",
29-
sha256 = "bb278df2afe88ed01490e4b25e2c048d453a518cb77d4795f6232a10fbae6c1f",
30-
strip_prefix = "rules_webtesting-dc0530015f201c2707085deba93ad210e89e6d18",
35+
sha256 = "4a34918cdb57b7c0976c1d6a9a7af1d657266b239c9c1066c87d6f9a4058bc7d",
36+
strip_prefix = "rules_webtesting-a9f624ac542d2be75f6f0bdd255f108f2795924a",
3137
urls = [
32-
"http://mirror.bazel.build/github.com/bazelbuild/rules_webtesting/archive/dc0530015f201c2707085deba93ad210e89e6d18.tar.gz", # 2017-05-10
33-
"https://github.com/bazelbuild/rules_webtesting/archive/dc0530015f201c2707085deba93ad210e89e6d18.tar.gz",
38+
"http://mirror.bazel.build/github.com/bazelbuild/rules_webtesting/archive/a9f624ac542d2be75f6f0bdd255f108f2795924a.tar.gz", # 2017-09-11
39+
"https://github.com/bazelbuild/rules_webtesting/archive/a9f624ac542d2be75f6f0bdd255f108f2795924a.tar.gz",
3440
],
3541
)
3642

43+
load("@io_bazel_rules_closure//closure:defs.bzl", "closure_repositories")
44+
45+
closure_repositories()
46+
3747
load("@io_bazel_rules_go//go:def.bzl", "go_repositories")
3848

3949
go_repositories()
@@ -53,4 +63,3 @@ load("//third_party:workspace.bzl", "tensorboard_workspace")
5363

5464
# Please add all new dependencies in workspace.bzl.
5565
tensorboard_workspace()
56-

tensorboard/plugins/text/summary_test.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,7 @@ def test_non_string_value_in_op(self):
144144
with six.assertRaisesRegex(
145145
self,
146146
Exception,
147-
r'Const:0 must be of type <dtype: \'string\'>'):
147+
r'must be of type <dtype: \'string\'>'):
148148
with tf.Session() as sess:
149149
sess.run(summary.op('so', tf.constant(5)))
150150

third_party/workspace.bzl

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -46,15 +46,16 @@ def tensorboard_workspace():
4646
# We need to import the protobuf library under the names com_google_protobuf
4747
# and com_google_protobuf_cc to enable proto_library support in bazel.
4848
# Unfortunately there is no way to alias http_archives at the moment.
49-
native.http_archive(
50-
name = "com_google_protobuf",
51-
urls = [
52-
"http://mirror.bazel.build/github.com/google/protobuf/archive/2b7430d96aeff2bb624c8d52182ff5e4b9f7f18a.tar.gz",
53-
"https://github.com/google/protobuf/archive/2b7430d96aeff2bb624c8d52182ff5e4b9f7f18a.tar.gz",
54-
],
55-
sha256 = "e5d3d4e227a0f7afb8745df049bbd4d55474b158ca5aaa2a0e31099af24be1d0",
56-
strip_prefix = "protobuf-2b7430d96aeff2bb624c8d52182ff5e4b9f7f18a",
57-
)
49+
if "com_google_protobuf" not in native.existing_rules():
50+
native.http_archive(
51+
name = "com_google_protobuf",
52+
urls = [
53+
"http://mirror.bazel.build/github.com/google/protobuf/archive/2b7430d96aeff2bb624c8d52182ff5e4b9f7f18a.tar.gz",
54+
"https://github.com/google/protobuf/archive/2b7430d96aeff2bb624c8d52182ff5e4b9f7f18a.tar.gz",
55+
],
56+
sha256 = "e5d3d4e227a0f7afb8745df049bbd4d55474b158ca5aaa2a0e31099af24be1d0",
57+
strip_prefix = "protobuf-2b7430d96aeff2bb624c8d52182ff5e4b9f7f18a",
58+
)
5859

5960
# Protobuf's BUILD file depends on //external:six.
6061
native.bind(

0 commit comments

Comments
 (0)