pod报错:uninitialized constant ActiveSupport::LoggerThreadSafeLevel::Logger (NameE

Mac电脑啥也没有改结过执行pod install 报如下错误:

hread_safe_level.rb:16:in <module:LoggerThreadSafeLevel>': uninitialized constant ActiveSupport::LoggerThreadSafeLevel::Logger (NameError) from /Library/Ruby/Gems/2.6.0/gems/activesupport-6.1.7.10/lib/active_support/logger_thread_safe_level.rb:9:in module:ActiveSupport' from /Library/Ruby/Gems/2.6.0/gems/activesupport-6.1.7.10/lib/active_support/logger_thread_safe_level.rb:8:in <top (required)>' from /Library/Ruby/Site/2.6.0/rubygems/core_ext/kernel_require.rb:85:in require' from /Library/Ruby/Site/2.6.0/rubygems/core_ext/kernel_require.rb:85:in require' from /Library/Ruby/Gems/2.6.0/gems/activesupport-6.1.7.10/lib/active_support/logger_silence.rb:5:in <top (required)>' from /Library/Ruby/Site/2.6.0/rubygems/core_ext/kernel_require.rb:85:in require' from /Library/Ruby/Site/2.6.0/rubygems/core_ext/kernel_require.rb:85:in require' from /Library/Ruby/Gems/2.6.0/gems/activesupport-6.1.7.10/lib/active_support/logger.rb:3:in <top (required)>' from /Library/Ruby/Site/2.6.0/rubygems/core_ext/kernel_require.rb:85:in require' from /Library/Ruby/Site/2.6.0/rubygems/core_ext/kernel_require.rb:85:in require' from /Library/Ruby/Gems/2.6.0/gems/activesupport-6.1.7.10/lib/active_support.rb:29:in <top (required)>' from /Library/Ruby/Site/2.6.0/rubygems/core_ext/kernel_require.rb:85:in require' from /Library/Ruby/Site/2.6.0/rubygems/core_ext/kernel_require.rb:85:in require' from /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.16.2/lib/cocoapods.rb:7:in <top (required)>' from /Library/Ruby/Site/2.6.0/rubygems/core_ext/kernel_require.rb:85:in require' from /Library/Ruby/Site/2.6.0/rubygems/core_ext/kernel_require.rb:85:in require' from /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.16.2/bin/pod:36:in <top (required)>' from /usr/local/bin/pod:25:in load' from /usr/local/bin/pod:25:in
'

解决方案:

一脸懵逼的我看到有一个关键字ActiveSupport,然后就搜了搜是个啥东西?

ActiveSupport 是 Ruby on Rails 框架中的一个核心库,旨在扩展和增强 Ruby 语言的功能。它提供了大量实用工具和扩展,使得日常的 Ruby 编程更加方便和高效。这些工具涵盖了诸如日期处理、字符串操作、数值计算等多个方面,并且引入了许多有助于简化代码编写和维护的对象和方法。

想着应该是这个版本出啥问题了,所以就搜了个命令重新安装了下好了。具体步骤如下:

  • '把老版本卸载下activesupport'

sudo gem uninstall activesupport

下载最新版本ActiveSupport
  • 执行命令 sudo gem install activesupport
  • 看下安装的情况 gem list
  • 验证是否成功

    pod --vresion

好了问题解决了

相关推荐
天桥吴彦祖5 小时前
判断iOS如何监听手机屏幕是否锁屏
ios
敲代码的鱼1 天前
PDF 预览与签名批注写回 支持安卓 iOS 鸿蒙 UTS插件
android·前端·ios
时光足迹1 天前
uni-app 视频通话实战:康复师与患者视频问诊的 6 个致命 Bug 与解决方案
android·ios·uni-app
时光足迹1 天前
JPush UniApp UTS 插件完全参考手册:API、事件与厂商通道一网打尽
vue.js·ios·uni-app
时光足迹1 天前
极光推送全攻略(下):uni-app 代码实现与 iOS 排查实战
vue.js·ios·uni-app
时光足迹1 天前
极光推送全攻略(上):被iOS证书折磨了三天,我写了一份前端也能看懂的避坑指南
前端·ios·uni-app
编程范式2 天前
SwiftUI 中图片如何适配可用空间
ios
songgeb4 天前
启发式 UI 自动化:从线性剧本到每步读屏决策
ios·测试
Tigger5 天前
受不了 ¥98/年的订阅,我用 Vibe Coding 自己写了个剪贴板工具
人工智能·开源·mac
壹方秘境8 天前
我用Go语言开发了一个跨平台的HTTPS抓包和调试工具
前端·后端·ios