无效的“Podfile”文件:套接字错误不支持操作
Posted
技术标签:
【中文标题】无效的“Podfile”文件:套接字错误不支持操作【英文标题】:Invalid `Podfile` file: Operation not supported on socket error 【发布时间】:2020-03-21 05:55:57 【问题描述】:尝试在 iPhone 11 pro max - 13.2.2 模拟器上运行时出现此错误。
在调试模式下在 iPhone 11 Pro Max 上启动 lib/main.dart...
Running pod install...CocoaPods' output: ↳ [!] Invalid `Podfile` file: Operation not supported on socket @ rb_file_s_symlink -
(/Users/x/flutter/bin/cache/artifacts/engine, .symlinks/flutter)。
来自 /Volumes/VMware 共享文件夹/C/app/ios/Podfile:51
------------------------------------------- # 符号链接 = 文件.join('.symlinks', 'flutter')
File.symlink(File.dirname(p[:path]), symlink) # pod 'Flutter', :path => File.join(symlink, File.basename(p[:path])) #
/Library/Ruby/Gems/2.6.0/gems/cocoapods-core-1.8.4/lib/cocoapods-core/podfile.rb:301:in
rescue in block in from_ruby' /Library/Ruby/Gems/2.6.0/gems/cocoapods-core-1.8.4/lib/cocoapods-core/podfile.rb:295:in
block in from_ruby' /Library/Ruby/Gems/2.6.0/gems/cocoapods-core-1.8.4/lib/cocoapods-core/podfile.rb:50:ininstance_eval' /Library/Ruby/Gems/2.6.0/gems/cocoapods-core-1.8.4/lib/cocoapods-core/podfile.rb:50:in
initialize' /Library/Ruby/Gems/2.6.0/gems/cocoapods-core-1.8.4/lib/cocoapods-core/podfile.rb:293:innew' /Library/Ruby/Gems/2.6.0/gems/cocoapods-core-1.8.4/lib/cocoapods-core/podfile.rb:293:in
from_ruby' /Library/Ruby/Gems/2.6.0/gems/cocoapods-core-1.8.4/lib/cocoapods-core/podfile.rb:259:infrom_file' /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.8.4/lib/cocoapods/config.rb:200:in
podfile' /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.8.4/lib/cocoapods/command.rb:150:inverify_podfile_exists!' /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.8.4/lib/cocoapods/command/install.rb:46:in
run' /Library/Ruby/Gems/2.6.0/gems/claide-1.0.3/lib/claide/command.rb:334:inrun' /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.8.4/lib/cocoapods/command.rb:52:in
run' /Library/Ruby/Gems/2.6.0/gems/cocoapods-1.8.4/bin/pod:55:in<top (required)>' /usr/local/bin/pod:23:in
load' /usr/local/bin/pod:23:in `'运行 pod install 时出错 在 iPhone 11 Pro 上启动应用程序时出错 最大。
pod --version
1.8.4
【问题讨论】:
【参考方案1】:当我的文件存储在 Windows NTFS 中并且我尝试从 MAC 访问它时,我遇到了类似的错误,为了解决我将文件夹从 Windows NTFS 分区移动到我的桌面的问题。
当您的 MAC 无法在不受支持的分区上创建符号链接文件时,会出现符号链接错误。
【讨论】:
以上是关于无效的“Podfile”文件:套接字错误不支持操作的主要内容,如果未能解决你的问题,请参考以下文章
React Native-iOS-无效的Podfile文件:nil:NilClass的未定义方法'[]'
React Native - iOS - 无效的`Podfile`文件:nil:NilClass的未定义方法`[]'