Warning: file_get_contents(/data/phpspider/zhask/data//catemap/3/wix/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
React native CDN:主干相对路径:CocoaPods-version.yml存在_React Native_Cocoapods_Yarnpkg_Podfile - Fatal编程技术网

React native CDN:主干相对路径:CocoaPods-version.yml存在

React native CDN:主干相对路径:CocoaPods-version.yml存在,react-native,cocoapods,yarnpkg,podfile,React Native,Cocoapods,Yarnpkg,Podfile,这一问题也报告了 所以我在测试我的项目(运行RN0.59.10)的Jest,安装了酶并运行良好,一切都很好。当我将它们合并到当前项目(在RN0.61上运行)时,解决了一些合并冲突,然后在pod安装过程中遇到问题。其间可能出了什么问题 项目在RN0.59中一次又一次地进行设置时没有问题,只有在RN0.61附带podfile时才会出现问题。需要指出的一点是,在集成这两个分支之前,我在RN0.61上的项目与pod安装配合得很好 下面是我试图克服这个问题的方法列表,运气不好的话,我仍然被卡住了 pod回

这一问题也报告了

所以我在测试我的项目(运行RN0.59.10)的Jest,安装了酶并运行良好,一切都很好。当我将它们合并到当前项目(在RN0.61上运行)时,解决了一些合并冲突,然后在
pod安装过程中遇到问题。其间可能出了什么问题

项目在RN0.59中一次又一次地进行设置时没有问题,只有在RN0.61附带podfile时才会出现问题。需要指出的一点是,在集成这两个分支之前,我在RN0.61上的项目与
pod安装
配合得很好

下面是我试图克服这个问题的方法列表,运气不好的话,我仍然被卡住了

  • pod回购更新
  • pod安装--repo更新
  • 移除
    节点\u模块
    +
    纱线。锁定
    +
    吊舱
    +
    吊舱文件。锁定
    +纱线安装并再次安装吊舱
  • pod安装日志--详细

    Resolving dependencies of `Podfile`
      CDN: trunk Relative path: CocoaPods-version.yml exists! Returning local because checking is only perfomed in repo update
    [!] Unable to find a specification for `Firebase/Core (~> 6.9.0)`
    
    You have either:
     * out-of-date source repos which you can update with `pod repo update` or with `pod install --repo-update`.
     * mistyped the name or version.
     * not added the source repo that hosts the Podspec to your Podfile.
    
    
    我的播客文件的一部分(这给了我一个问题):

    当我删除上面的4行时会发生什么?(这太错误了,我怀疑我的本地电脑出了问题)

    Pod版本:1.8.4

    反应本机信息:

    System:
        OS: macOS Mojave 10.14.6
        CPU: (4) x64 Intel(R) Core(TM) i5-6360U CPU @ 2.00GHz
        Memory: 65.95 MB / 8.00 GB
        Shell: 3.2.57 - /bin/bash
      Binaries:
        Node: 12.10.0 - /usr/local/bin/node
        Yarn: 1.19.0 - /usr/local/bin/yarn
        npm: 6.12.0 - /usr/local/bin/npm
        Watchman: 4.9.0 - /usr/local/bin/watchman
      SDKs:
        iOS SDK:
          Platforms: iOS 13.2, DriverKit 19.0, macOS 10.15, tvOS 13.2, watchOS 6.1
        Android SDK:
          API Levels: 23, 28, 29
          Build Tools: 28.0.3, 29.0.2
          System Images: android-24 | Google APIs Intel x86 Atom_64, android-29 | Google Play Intel x86 Atom_64
          Android NDK: 19.2.5345600
      IDEs:
        Android Studio: 3.5 AI-191.8026.42.35.5791312
        Xcode: 11.2.1/11B500 - /usr/bin/xcodebuild
      npmPackages:
        react: 16.9.0 => 16.9.0 
        react-native: 0.61.0 => 0.61.0 
      npmGlobalPackages:
        react-native-cli: 2.0.1
    

    更新: 实际上,我在安装过程中删除了Podfile.lock。当我返回到上一个成功状态(podfile.lock和warn.lock位于我的目录中)时,pod安装成功了

    我决定进一步挖掘这个问题,下面是一些案例场景的结果

    删除podfile.lock,显示以下内容:

    [!] Unable to find a specification for `Firebase/Core (~> 6.9.0)`
    
    You have either:
     * out-of-date source repos which you can update with `pod repo update` or with `pod install --repo-update`.
     * mistyped the name or version.
     * not added the source repo that hosts the Podspec to your Podfile.
    
    [!] CocoaPods could not find compatible versions for pod "FBSDKCoreKit":
      In snapshot (Podfile.lock):
        FBSDKCoreKit (= 5.7.0, ~> 5.0, ~> 5.5)
    
      In Podfile:
        react-native-fbsdk (from `../node_modules/react-native-fbsdk`) was resolved to 1.1.1, which depends on
          react-native-fbsdk/Core (= 1.1.1) was resolved to 1.1.1, which depends on
            FBSDKCoreKit (= 5.8)
    
    
    You have either:
     * out-of-date source repos which you can update with `pod repo update` or with `pod install --repo-update`.
     * changed the constraints of dependency `FBSDKCoreKit` inside your development pod `react-native-fbsdk`.
       You should run `pod update FBSDKCoreKit` to apply changes you've made.
    
    [!] Unable to find a specification for `Firebase/Core (~> 6.9.0)`
    
    You have either:
     * out-of-date source repos which you can update with `pod repo update` or with `pod install --repo-update`.
     * mistyped the name or version.
     * not added the source repo that hosts the Podspec to your Podfile.
    
    卸下纱线。锁紧,显示以下内容:

    [!] Unable to find a specification for `Firebase/Core (~> 6.9.0)`
    
    You have either:
     * out-of-date source repos which you can update with `pod repo update` or with `pod install --repo-update`.
     * mistyped the name or version.
     * not added the source repo that hosts the Podspec to your Podfile.
    
    [!] CocoaPods could not find compatible versions for pod "FBSDKCoreKit":
      In snapshot (Podfile.lock):
        FBSDKCoreKit (= 5.7.0, ~> 5.0, ~> 5.5)
    
      In Podfile:
        react-native-fbsdk (from `../node_modules/react-native-fbsdk`) was resolved to 1.1.1, which depends on
          react-native-fbsdk/Core (= 1.1.1) was resolved to 1.1.1, which depends on
            FBSDKCoreKit (= 5.8)
    
    
    You have either:
     * out-of-date source repos which you can update with `pod repo update` or with `pod install --repo-update`.
     * changed the constraints of dependency `FBSDKCoreKit` inside your development pod `react-native-fbsdk`.
       You should run `pod update FBSDKCoreKit` to apply changes you've made.
    
    [!] Unable to find a specification for `Firebase/Core (~> 6.9.0)`
    
    You have either:
     * out-of-date source repos which you can update with `pod repo update` or with `pod install --repo-update`.
     * mistyped the name or version.
     * not added the source repo that hosts the Podspec to your Podfile.
    
    删除两个warn.lock+podfile.lock,如下所示:

    [!] Unable to find a specification for `Firebase/Core (~> 6.9.0)`
    
    You have either:
     * out-of-date source repos which you can update with `pod repo update` or with `pod install --repo-update`.
     * mistyped the name or version.
     * not added the source repo that hosts the Podspec to your Podfile.
    
    [!] CocoaPods could not find compatible versions for pod "FBSDKCoreKit":
      In snapshot (Podfile.lock):
        FBSDKCoreKit (= 5.7.0, ~> 5.0, ~> 5.5)
    
      In Podfile:
        react-native-fbsdk (from `../node_modules/react-native-fbsdk`) was resolved to 1.1.1, which depends on
          react-native-fbsdk/Core (= 1.1.1) was resolved to 1.1.1, which depends on
            FBSDKCoreKit (= 5.8)
    
    
    You have either:
     * out-of-date source repos which you can update with `pod repo update` or with `pod install --repo-update`.
     * changed the constraints of dependency `FBSDKCoreKit` inside your development pod `react-native-fbsdk`.
       You should run `pod update FBSDKCoreKit` to apply changes you've made.
    
    [!] Unable to find a specification for `Firebase/Core (~> 6.9.0)`
    
    You have either:
     * out-of-date source repos which you can update with `pod repo update` or with `pod install --repo-update`.
     * mistyped the name or version.
     * not added the source repo that hosts the Podspec to your Podfile.
    
    太长,读不下去了 追加
    源代码'https://cdn.cocoapods.org/“
    到Podfile(在目标“projectName”do之前)


    最终找到了根本原因并找到了解决方案! 原因是,我的pod文件中有一个privateRepo,它覆盖了从Cocoapods获取podspec的默认源。错误示例如下

    # Uncomment the next line to define a global platform for your project
    platform :ios, '9.0'
    require_relative '../node_modules/@react-native-community/cli-platform-ios/native_modules'
    source 'https://github.com/privateRepo/Specs.git'
    
    target 'project' do
      # Comment the next line if you don't want to use dynamic frameworks
      # use_frameworks!
    .....
    ....
    ...
    ..
    .
    end
    
    因此,一个简单的回过头来的解决方案将解决这个问题

    # Uncomment the next line to define a global platform for your project
    platform :ios, '9.0'
    require_relative '../node_modules/@react-native-community/cli-platform-ios/native_modules'
    source 'https://github.com/privateRepo/Specs.git'
    
    target 'project' do
      # Comment the next line if you don't want to use dynamic frameworks
      # use_frameworks!
    .....
    ....
    ...
    ..
    .
    end
    
    太长,读不下去了 追加
    源代码'https://cdn.cocoapods.org/“
    到Podfile(在目标“projectName”do之前)


    最终找到了根本原因并找到了解决方案! 原因是,我的pod文件中有一个privateRepo,它覆盖了从Cocoapods获取podspec的默认源。错误示例如下

    # Uncomment the next line to define a global platform for your project
    platform :ios, '9.0'
    require_relative '../node_modules/@react-native-community/cli-platform-ios/native_modules'
    source 'https://github.com/privateRepo/Specs.git'
    
    target 'project' do
      # Comment the next line if you don't want to use dynamic frameworks
      # use_frameworks!
    .....
    ....
    ...
    ..
    .
    end
    
    因此,一个简单的回过头来的解决方案将解决这个问题

    # Uncomment the next line to define a global platform for your project
    platform :ios, '9.0'
    require_relative '../node_modules/@react-native-community/cli-platform-ios/native_modules'
    source 'https://github.com/privateRepo/Specs.git'
    
    target 'project' do
      # Comment the next line if you don't want to use dynamic frameworks
      # use_frameworks!
    .....
    ....
    ...
    ..
    .
    end
    

    尝试
    pod安装--repo-update
    @PaulBeusterien我已经尝试了上面提到的命令,我得到了
    您已经:*输入了错误的名称或版本。*未将承载Podspec的源repo添加到您的Podfile中。
    asresult@PaulBeusterien我已经用更新部分作为标题更新了这篇文章。我在这里提供了更多的发现。请尝试
    pod安装--repo update
    @PaulBeusterien我已经尝试了上面提到的命令,我得到了
    您的答案:*输入了错误的名称或版本。*未将承载Podspec的源repo添加到您的Podfile中。
    asresult@PaulBeusterien我已经用更新部分作为标题更新了这篇文章。我在这里提供了更多的发现。两个片段完全相同,您在第二个片段中没有应用修复。两个片段完全相同,您在第二个片段中没有应用修复