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

[Question] Protobuf version #6649

Open
meerfrau opened this issue Oct 19, 2023 · 4 comments
Open

[Question] Protobuf version #6649

meerfrau opened this issue Oct 19, 2023 · 4 comments

Comments

@meerfrau
Copy link

I'm getting a compilation failure:

ERROR: /external/com_google_protobuf/BUILD:513:10: Compiling src/google/protobuf/compiler/main.cc failed: (Exit 1): gcc failed: error executing command /usr/lib/ccache/bin/gcc -U_FORTIFY_SOURCE -fstack-protector -Wall -Wunused-but-set-parameter -Wno-free-nonheap-object -fno-omit-frame-pointer -g0 -O2 '-D_FORTIFY_SOURCE=1' -DNDEBUG -ffunction-sections ... (remaining 37 arguments skipped)

Environment information (required)

diagnose_tensorboard.py output:

Diagnostics

Diagnostics output
--- check: autoidentify
INFO: diagnose_tensorboard.py version df7af2c6fc0e4c4a5b47aeae078bc7ad95777ffa

--- check: general
INFO: sys.version_info: sys.version_info(major=3, minor=10, micro=10, releaselevel='final', serial=0)
INFO: os.name: posix
INFO: os.uname(): posix.uname_result(sysname='Linux', nodename='main', release='6.6.0-1-mainline', version='#1 SMP PREEMPT_DYNAMIC Mon, 09 Oct 2023 04:56:39 +0000', machine='x86_64')
INFO: sys.getwindowsversion(): N/A

--- check: package_management
INFO: has conda-meta: False
INFO: $VIRTUAL_ENV: None

--- check: installed_packages
WARNING: no installation among: ['tb-nightly', 'tensorboard', 'tensorflow-tensorboard']
INFO: installed: tensorflow==2.14.0
INFO: installed: tensorflow-estimator==2.12.0

--- check: tensorboard_python_version
Traceback (most recent call last):
  File "/tmp/diagnose_tensorboard.py", line 511, in main
    suggestions.extend(check())
  File "/tmp/diagnose_tensorboard.py", line 81, in wrapper
    result = fn()
  File "/tmp/diagnose_tensorboard.py", line 260, in tensorboard_python_version
    from tensorboard import version
ModuleNotFoundError: No module named 'tensorboard'

--- check: tensorflow_python_version
WARNING: Limited tf.compat.v2.summary API due to missing TensorBoard installation.
WARNING: Limited tf.compat.v2.summary API due to missing TensorBoard installation.
WARNING: Limited tf.compat.v2.summary API due to missing TensorBoard installation.
WARNING: Limited tf.summary API due to missing TensorBoard installation.
WARNING: Limited tf.compat.v2.summary API due to missing TensorBoard installation.
WARNING: Limited tf.compat.v2.summary API due to missing TensorBoard installation.
WARNING: Limited tf.compat.v2.summary API due to missing TensorBoard installation.
INFO: Note: NumExpr detected 12 cores but "NUMEXPR_MAX_THREADS" not set, so enforcing safe limit of 8.
INFO: NumExpr defaulting to 8 threads.
INFO: tensorflow.__version__: '2.14.0'
INFO: tensorflow.__git_version__: 'v2.14.0-rc1-21-g4dacf3f368e'

--- check: tensorboard_data_server_version
INFO: no data server installed

--- check: tensorboard_binary_path
INFO: which tensorboard: b'/usr/bin/tensorboard\n'

--- check: addrinfos
socket.has_ipv6 = True
socket.AF_UNSPEC = <AddressFamily.AF_UNSPEC: 0>
socket.SOCK_STREAM = <SocketKind.SOCK_STREAM: 1>
socket.AI_ADDRCONFIG = <AddressInfo.AI_ADDRCONFIG: 32>
socket.AI_PASSIVE = <AddressInfo.AI_PASSIVE: 1>
Loopback flags: <AddressInfo.AI_ADDRCONFIG: 32>
Loopback infos: [(<AddressFamily.AF_INET6: 10>, <SocketKind.SOCK_STREAM: 1>, 6, '', ('::1', 0, 0, 0)), (<AddressFamily.AF_INET: 2>, <SocketKind.SOCK_STREAM: 1>, 6, '', ('127.0.0.1', 0))]
Wildcard flags: <AddressInfo.AI_PASSIVE: 1>
Wildcard infos: [(<AddressFamily.AF_INET: 2>, <SocketKind.SOCK_STREAM: 1>, 6, '', ('0.0.0.0', 0)), (<AddressFamily.AF_INET6: 10>, <SocketKind.SOCK_STREAM: 1>, 6, '', ('::', 0, 0, 0))]

--- check: readable_fqdn
INFO: socket.getfqdn(): 'main'

--- check: stat_tensorboardinfo
INFO: directory: /tmp/.tensorboard-info
INFO: .tensorboard-info directory does not exist

--- check: source_trees_without_genfiles
INFO: tensorboard_roots (0): []; bad_roots (0): []

--- check: full_pip_freeze
INFO: pip freeze --all:
absl-py==1.4.0
[1684 more lines]

Issue description

Does tensorboard support protobuf 24.3?

@arcra
Copy link
Member

arcra commented Oct 24, 2023

I believe tensorboard should be compatible with protobuf 24.3. At least we're not aware of any particular issues, but this doesn't seem like an issue with library compatibility to me.

Can you share what you were trying to compile and how? Or how you encountered this issue?

We use bazel to build TB locally. You can take a look at our DEVELOPMENT guide. However, if you just want to use tensorboard, I suggest installing a released version of TB via pip, e.g. $ pip install tensorboard, or $ pip install tb-nightly for the nightly version.

@meerfrau
Copy link
Author

meerfrau commented Oct 25, 2023

I do use bazel build //tensorboard/pip_package:build_pip_package (sticking to bazel 5.3.2, but can update to 6.3.2 if this is advised)

My https://github.com/mitmproxy/mitmproxy is linked against the same python-protobuf and working well.

@arcra
Copy link
Member

arcra commented Oct 25, 2023

I don't understand why you're getting such error message: ERROR: /external/com_google_protobuf/BUILD:513:10, we don't have such path anywhere in our package. I also can't tell which version of protobuf you're using since the output of pip freeze was cut out in the diagnostics file you included.

I couldn't reproduce the error you've shown, but if you're attempting to build a custom pip package (which is distributed as a "wheel file"), you'd need to run these commands (possibly in a virtual env):

bazel build -c opt //tensorboard/pip_package
bazel run -c opt //tensorboard/pip_package:extract_pip_package -- path/to/location

This is how I did it from a clean env:

~$ virtualenv /tmp/tb_test
~$ source /tmp/tb_test/bin/activate
~$ cd tensorboard/
~/tensorboard$ pip install --upgrade pip
~/tensorboard$ pip install tf-nightly -r tensorboard/pip_package/requirements.txt -r tensorboard/pip_package/requirements_dev.txt
~/tensorboard$ bazel build -c opt //tensorboard/pip_package
~/tensorboard$ bazel run -c opt //tensorboard/pip_package:extract_pip_package -- /tmp/tb_test/
~/tensorboard$ ls /tmp/tb_test/
bin  lib  pyvenv.cfg  tensorboard-2.16.0a0-py3-none-any.whl

@arcra arcra closed this as completed Oct 25, 2023
@arcra
Copy link
Member

arcra commented Oct 26, 2023

Closed accidentally.

@arcra arcra reopened this Oct 26, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants