webrtc gclient sync报错问题解决

报错信息

strp_current_url = current_url:-4 if current_url.endswith(

^^^^^^^^^^^^^^^^^^^^

AttributeError: 'NoneType' object has no attribute 'endswith'

bash 复制代码
gclient sync

src/base (ERROR)
----------------------------------------
[0:00:00] Started.
----------------------------------------
Traceback (most recent call last):
  File "/home/lign/depot_tools/metrics.py", line 302, in print_notice_and_exit
    yield
  File "/home/lign/depot_tools/gclient.py", line 4638, in <module>
    sys.exit(main(sys.argv[1:]))
             ^^^^^^^^^^^^^^^^^^
  File "/home/lign/depot_tools/gclient.py", line 4624, in main
    return dispatcher.execute(OptionParser(), argv)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/lign/depot_tools/subcommand.py", line 254, in execute
    return command(parser, args[1:])
           ^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/lign/depot_tools/gclient.py", line 3977, in CMDsync
    ret = client.RunOnDeps('update', args)
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/lign/depot_tools/gclient.py", line 2436, in RunOnDeps
    work_queue.flush(revision_overrides,
  File "/home/lign/depot_tools/gclient_utils.py", line 1026, in flush
    reraise(e[0], e[1], e[2])
  File "/home/lign/depot_tools/gclient_utils.py", line 53, in reraise
    raise value
  File "/home/lign/depot_tools/gclient_utils.py", line 1105, in run
    self.item.run(*self.args, **self.kwargs)
  File "/home/lign/depot_tools/gclient.py", line 1251, in run
    self._got_revision = self._used_scm.RunCommand(
                         ^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/lign/depot_tools/gclient_scm.py", line 137, in RunCommand
    return getattr(self, command)(options, args, file_list)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/home/lign/depot_tools/gclient_scm.py", line 664, in wrapper
    return_val = f(*args)
                 ^^^^^^^^
  File "/home/lign/depot_tools/gclient_scm.py", line 866, in update
    strp_current_url = current_url[:-4] if current_url.endswith(
                                           ^^^^^^^^^^^^^^^^^^^^
AttributeError: 'NoneType' object has no attribute 'endswith'

问题原因:参考https://groups.google.com/a/chromium.org/g/chromium-dev/c/7fv7rSr2sbo

的描述,这个问题似乎是由避免静默覆盖 diff.ignoreSubmodules 配置引入的,该配置在 'git config --list -z' 命令中添加了 '--show-scope' 选项,但该选项从 git v2.26 开始受支持,并且该命令在较旧的 git 中会失败。

解决办法:升级git版本,参考https://blog.csdn.net/ypgsh/article/details/120632001

相关推荐
换个昵称都难25 分钟前
webrtc 音频混音介绍
音视频·webrtc
换个昵称都难17 小时前
webrtc QOS-RemoteBitrateEstimator接收端带宽估计(1)
webrtc
换个昵称都难17 小时前
webrtc QOS-RemoteBitrateEstimator接收端带宽估计-四个实例(2)
webrtc
都在酒里1 天前
【极致低延时】香橙派部署 MediaMTX 实现 WebRTC 推流,延时仅 500-800ms,比局域网 ffmpeg 拉流快近 10 倍!(附踩坑全记录)
linux·arm开发·ffmpeg·webrtc·orangepi·嵌入式软件
换个昵称都难1 天前
WebRTC QoS 实战:从原理到弱网优化
开发语言·php·webrtc
小哈机器人1 天前
Phantom Bridge:一个基于WebRTC的ROS2远程可视化与遥操作工具
机器人·webrtc·数据可视化
换个昵称都难1 天前
webrtc 视频传输Flexfec模块
音视频·webrtc
AndyHuang19761 天前
实战记录:如何在 Release 模式下成功调试 WebRTC 源码(解决断点失效问题)
webrtc
换个昵称都难2 天前
webrtc视频Ulpfec介绍
音视频·webrtc
xiejiashu3 天前
EasyRTC三种工作模式发布,全终端覆盖音视频RTC实时通信99%应用场景
webrtc·webrtc原生sdk·webrtc c sdk·webrtc c++ sdk·webrtc安卓sdk