Exception (I think harmless) from the toolchain pl...
# development
a
Exception (I think harmless) from the toolchain plugin on CI for the release wheel build:
https://github.com/pantsbuild/pants/runs/3032844222?check_suite_focus=true
Copy code
Exception in thread Thread-2:
Traceback (most recent call last):
  File "/opt/_internal/cpython-3.7.11/lib/python3.7/threading.py", line 926, in _bootstrap_inner
    self.run()
  File "/__w/pants/pants/src/python/pants/engine/streaming_workunit_handler.py", line 264, in run
    self.poll_workunits(finished=False)
  File "/__w/pants/pants/src/python/pants/engine/streaming_workunit_handler.py", line 257, in poll_workunits
    context=self.context,
  File "/github/home/.cache/pants/named_caches/pex_root/venvs/short/950be9e9/lib/python3.7/site-packages/toolchain/pants/buildsense/reporter.py", line 173, in __call__
    finished=finished,
  File "/github/home/.cache/pants/named_caches/pex_root/venvs/short/950be9e9/lib/python3.7/site-packages/toolchain/pants/buildsense/reporter.py", line 193, in handle_workunits
    self._enqueue_initial_report(context)
  File "/github/home/.cache/pants/named_caches/pex_root/venvs/short/950be9e9/lib/python3.7/site-packages/toolchain/pants/buildsense/reporter.py", line 201, in _enqueue_initial_report
    run_tracker_info = self._get_run_tracker_info(context)
  File "/github/home/.cache/pants/named_caches/pex_root/venvs/short/950be9e9/lib/python3.7/site-packages/toolchain/pants/buildsense/reporter.py", line 216, in _get_run_tracker_info
    _adjust_run_info_fields(run_info, run_tracker.goals, has_ended)
  File "/github/home/.cache/pants/named_caches/pex_root/venvs/short/950be9e9/lib/python3.7/site-packages/toolchain/pants/buildsense/reporter.py", line 271, in _adjust_run_info_fields
    revision = scm.commit_id
AttributeError: 'NoneType' object has no attribute 'commit_id'
👀 1
h
@polite-garden-50641 Thanks for the report!
p
weird, that code relies on https://github.com/pantsbuild/pants/blob/main/src/python/pants/base/build_environment.py#L42 Any reason it won't return detect the git repo ?
@hundreds-father-404 any ideas on the why this happens?
h
I see it says
fatal: No names found, cannot describe anything.
, which is a git message https://stackoverflow.com/questions/4916492/git-describe-fails-with-fatal-no-names-found-cannot-describe-anything I wonder if
get_git
is failing in CI