Tensorboard version conflict

Guildai tensorboard functionallity donćt work for me for some time. Now I would like to make it work.

If I execute command guild tensorboard --started 'last 1 hour' I get:

(base) PS C:\Users\Mislav\Documents\GitHub\trademl> guild tensorboard --started 'last 1 hour'
Preparing runs for TensorBoard
2020-09-24 11:32:59.909813: I tensorflow/stream_executor/platform/default/dso_loader.cc:48] Successfully opened dynamic library cudart64_101.dll
Traceback (most recent call last):
  File "c:\programdata\anaconda3\lib\runpy.py", line 194, in _run_module_as_main
    return _run_code(code, main_globals, None,
  File "c:\programdata\anaconda3\lib\runpy.py", line 87, in _run_code
    exec(code, run_globals)
  File "C:\ProgramData\Anaconda3\Scripts\guild.exe\__main__.py", line 7, in <module>
  File "c:\programdata\anaconda3\lib\site-packages\guild\main_bootstrap.py", line 40, in main
    guild.main.main()
  File "c:\programdata\anaconda3\lib\site-packages\guild\main.py", line 33, in main
    _main()
  File "c:\programdata\anaconda3\lib\site-packages\guild\main.py", line 40, in _main
    main_cmd.main(standalone_mode=False)
  File "c:\programdata\anaconda3\lib\site-packages\guild\external\click\core.py", line 829, in __call__
    return self.main(*args, **kwargs)
  File "c:\programdata\anaconda3\lib\site-packages\guild\external\click\core.py", line 782, in main
    rv = self.invoke(ctx)
  File "c:\programdata\anaconda3\lib\site-packages\guild\external\click\core.py", line 1259, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "c:\programdata\anaconda3\lib\site-packages\guild\external\click\core.py", line 1066, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "c:\programdata\anaconda3\lib\site-packages\guild\external\click\core.py", line 610, in invoke
    return callback(*args, **kwargs)
  File "c:\programdata\anaconda3\lib\site-packages\guild\click_util.py", line 201, in fn
    return fn0(*(args + (Args(**kw),)))
  File "c:\programdata\anaconda3\lib\site-packages\guild\commands\tensorboard.py", line 108, in tensorboard
    tensorboard_impl.main(args)
  File "c:\programdata\anaconda3\lib\site-packages\guild\commands\tensorboard_impl.py", line 46, in main
    _run_tensorboard(args)
  File "c:\programdata\anaconda3\lib\site-packages\guild\commands\tensorboard_impl.py", line 98, in _run_tensorboard
    tensorboard.serve_forever(
  File "c:\programdata\anaconda3\lib\site-packages\guild\tensorboard.py", line 607, in serve_forever
    app = create_app(logdir, reload_interval, tensorboard_options=tensorboard_options)
  File "c:\programdata\anaconda3\lib\site-packages\guild\tensorboard.py", line 508, in create_app
    plugins = _tensorboard_plugins(disabled_plugins)
  File "c:\programdata\anaconda3\lib\site-packages\guild\tensorboard.py", line 522, in _tensorboard_plugins
    base_plugins = tensorboard.base_plugins()
  File "c:\programdata\anaconda3\lib\site-packages\guild\plugins\tensorboard.py", line 232, in base_plugins
    return list(set(default.get_plugins() + default.get_dynamic_plugins()))
  File "c:\programdata\anaconda3\lib\site-packages\tensorboard\default.py", line 122, in get_dynamic_plugins
    return [
  File "c:\programdata\anaconda3\lib\site-packages\tensorboard\default.py", line 123, in <listcomp>
    entry_point.load()
  File "C:\Users\Mislav\AppData\Roaming\Python\Python38\site-packages\pkg_resources\__init__.py", line 2471, in load
    self.require(*args, **kwargs)
  File "C:\Users\Mislav\AppData\Roaming\Python\Python38\site-packages\pkg_resources\__init__.py", line 2494, in require
    items = working_set.resolve(reqs, env, installer, extras=self.extras)
  File "C:\Users\Mislav\AppData\Roaming\Python\Python38\site-packages\pkg_resources\__init__.py", line 790, in resolve
    raise VersionConflict(dist, req).with_context(dependent_req)
pkg_resources.VersionConflict: (requests 2.18.4 (c:\users\mislav\appdata\roaming\python\python38\site-packages), Requirement.parse('requests<3,>=2.21.0'))

Conda list requests gives:

(base) PS C:\Users\Mislav\Documents\GitHub\trademl> conda list requests
# packages in environment at C:\ProgramData\Anaconda3:
#
# Name                    Version                   Build  Channel
requests                  2.24.0             pyh9f0ad1d_0    conda-forge
requests-oauthlib         1.3.0                    pypi_0    pypi

so it is greater than 2.21 and lower than 3?

I haven’t seen this sort of error from pkg_resources. I’m surprised it’s checking versions and failing there for what it’s being asked to do (simply load entry points).

Do you see the same error when you run tensorboard directly (without Guild)?

I would certainly try upgrading requests (e.g. pip install --upgrade requests). This particular version requirement is not coming from Guild — my guess is that it’s from tensorboard.

Whatever conda is showing you there is different from what is coming from c:\users\mislav\appdata\roaming\python\python38\site-packages. I’d run the pip from the python38 location to verify that requests is 2.18.4.

The safest way to run pip for a given Python instance is this way:

python -m pip [ARGS]...