我使用 Visual Studio Code 应用程序中心来构建我的 Android 应用程序,之后一切正常,但现在构建失败,出现以下异常。我该如何解决这个问题?
FAILURE: Build failed with an exception.
* Where:
Build file '/Users/runner/work/1/s/app/build.gradle' line: 1
* What went wrong:
A problem occurred evaluating project ':app'.
> Failed to apply plugin 'com.android.internal.application'.
> Android Gradle plugin requires Java 11 to run. You are currently using Java 1.8.
You can try some of the following options:
- changing the IDE settings.
- changing the JAVA_HOME environment variable.
- changing `org.gradle.java.home` in `gradle.properties`.
* Try:
Run with --stacktrace …Run Code Online (Sandbox Code Playgroud) 我正在开发一个移动应用程序并使用MS App Center for CI.昨天单元测试项目无法在App Center中构建,但出现以下错误.我无法在任何开发人员计算机上重新创建此问题,此错误仅在App Center中出现.
error : NETSDK1061: The project was restored using Microsoft.NETCore.App version 1.0.0, but with current settings, version 2.0.9 would be used instead. To resolve this issue, make sure the same settings are used for restore and for subsequent operations such as build or publish. Typically this issue can occur if the RuntimeIdentifier property is set during build or publish but not during restore. For more information, see https://aka.ms/dotnet-runtime-patch-selection.
Run Code Online (Sandbox Code Playgroud)
他们的付费支持只是提供基础,清理项目,回滚我的最后一次提交等.有人在App Center之前遇到过这个问题吗?
在理解这两种服务的能力以及它们之间的核心差异时,我"有点"困惑.
一般来说,我理解它们提供的内容,并且我之前分别使用它们(主要是VSTS作为问题跟踪器),以及用于构建和部署源的AppCenter.
然而:
他们都具备building(显然)publishing能力.
在DevOps中可以选择设置管道:
与AppCenter大致相同:
他们俩都有Tests类似功能的部分(似乎).
3.它们都提供了将构建部署到Play/App Stores的能力.
AppCenter - 带有"Stores"部分,DevOps带有此插件(至少).
它们还具有一些特定功能(例如AppCenter具有PushNotifications功能,Azure DevOps具有问题跟踪),但是,对于应用程序分发,它们看起来非常相似.
那么,哪些应该用于哪些特定任务呢?或者这只是微软的现代"营销"功能之一,当时几乎没有区别,但那些只是两个相似的东西包裹着不同颜色的信封?
app-store mobile-development azure-devops visual-studio-app-center
我开始在我的原生React应用程序中使用MS appcenter,在设置过程中,他们要求我向项目添加两个新文件:
<dict>
<key>AppSecret</key>
<string><MY_SECRET_KEY></string>
</dict>
Run Code Online (Sandbox Code Playgroud)
{
"app_secret": "<MY_SECRET_KEY>"
}
Run Code Online (Sandbox Code Playgroud)
我已经在我的应用程序中使用一个包来处理 .env 文件:https : //github.com/luggit/react-native-config
有什么方法可以使用这个包或另一个包,以便APP_SECRET从 ENV 变量中获取appcenter 配置文件?
我只是不想让这些密钥处于版本控制之下。
environment-variables react-native react-native-config visual-studio-app-center
当我尝试安装下载的SDK时,始终出现此错误。有任何想法吗?
该应用程序可以正确构建和测试。我没有得到详细的错误消息App not installed
如何获得更详细的错误消息?有任何想法吗?
我的第一个版本起作用了,所以我想可能是版本号不匹配。但是,我尝试将数字编码,但仍无法安装:
defaultConfig {
applicationId "com.rgcalendar"
minSdkVersion 16
targetSdkVersion 22
versionCode 23
versionName "1.0"
ndk {
abiFilters "armeabi-v7a", "x86"
}
}
Run Code Online (Sandbox Code Playgroud) 我刚刚按照此处的文章将我的应用程序设置为在 App Center 上构建。
尽管 Android 版本在 App Center 上构建和部署良好,但我在 iOS 构建中遇到错误,如下面构建输出的摘录所示:
==============================================================================
Task : CocoaPods
Description : Install CocoaPods dependencies for Swift and Objective-C Cocoa projects
Version : 0.151.1
Author : Microsoft Corporation
Help : https://docs.microsoft.com/azure/devops/pipelines/tasks/package/cocoapods
==============================================================================
[command]/usr/local/lib/ruby/gems/2.6.0/bin/pod --version
1.9.1
[command]/usr/local/lib/ruby/gems/2.6.0/bin/pod install --repo-update
[!] Invalid `Podfile` file: Generated.xcconfig must exist. If you're running pod install manually, make sure flutter pub get is executed first.
# from /Users/runner/runners/2.165.2/work/1/s/bdstories/ios/Podfile:51
# -------------------------------------------
# unless File.exist?(generated_xcode_build_settings_path)
> raise "Generated.xcconfig …Run Code Online (Sandbox Code Playgroud) 我正在尝试从 appcenter.ms 构建和分发 Android 应用程序。最初,我在推出第三次更新后遭到拒绝,我尝试重建更改。但是在分发到商店时我遇到了以下问题。
由于错误而无法提交编辑。更改无法自动发送以供审核。请将查询参数changesNotSentForReview设置为true。提交后,可以从 Google Play 控制台 UI 发送此编辑中的更改以供审核。
我不想从 Google Play Console UI 进行更改,只想从 appcenter.ms 进行更改。如何在代码中设置该参数。帮助将非常可观!
android android-app-indexing google-play-console visual-studio-app-center visual-studio-app-center-distribute
我的 iOS 项目包括一些私有 pod。我已经在我的本地机器(以及团队成员)上完成了使用此处概述的私有 pod 的步骤。
如何为 VS App Center 添加相同的过程来更新和检索 repo?
目前,我在构建输出中得到了这个:
[command]/usr/local/bin/pod install --repo-update
Updating local specs repositories
Cloning spec repo fooBar from git@github.com:fooBar/Podspec.git
[!] Unable to add a source with url git@github.fooBar/Podspec.git named fooBar.
You can try adding it manually in ~/.cocoapods/repos or via pod repo add.
[error]/usr/local/bin/pod failed with return code: 1
[error]The 'pod' command failed with error: /usr/local/bin/pod failed with return code: 1
我继承了一个用 Carthage 构建的项目。使用 Xcode 12,我遇到了这个错误:
致命错误:/Applications/Xcode_12.3.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/lipo:/Users/runner/Library/Caches/org.carthage.CarthageKit/DerivedData/12.3_12C33/AEXML/ 4.6.0/Build/Intermediates.noindex/ArchiveIntermediates/AEXML iOS/IntermediateBuildFilesPath/UninstalledProducts/iphoneos/AEXML.framework/AEXML 和 /Users/runner/Library/Caches/org.carthage.CarthageKit/DerivedData/12.3_12C33/AEXML/4.6 .0/Build/Products/Release-iphonesimulator/AEXML.framework/AEXML 具有相同的体系结构 (arm64),并且不能位于同一个 fat 输出文件中
使用通用架构构建通用框架是不可能的。“AEXML”的设备和模拟器切片均针对以下版本构建:arm64 使用 --use-xcframeworks 重新构建以创建 xcframework 捆绑包。
快速的谷歌搜索让我发现了这个适用于我的本地机器。
第一次使用 AppCenter,我使用以下内容创建了一个预构建脚本:
#!/usr/bin/env bash
# Pre-build
# See: https://learn.microsoft.com/en-us/appcenter/build/custom/scripts/#pre-build
echo "Pre-build has started."
sh ./carthage.sh update --use-submodules
echo "Pre-build has ended."
Run Code Online (Sandbox Code Playgroud)
我认为应该使用迦太基来构建这个?我在 AppCenter 中收到错误:
*** 在 AEXML.xcodeproj 中构建方案“AEXML iOS” shell 任务 (/usr/bin/xcrun lipo -create /Users/runner/Library/Caches/org.carthage.CarthageKit/DerivedData/12.3_12C33/AEXML/4.6. 0/Build/Intermediates.noindex/ArchiveIntermediates/AEXML\ iOS/IntermediateBuildFilesPath/UninstalledProducts/iphoneos/AEXML.framework/AEXML /Users/runner/Library/Caches/org.carthage.CarthageKit/DerivedData/12.3_12C33/AEXML/4.6.0 /Build/Products/Release-iphonesimulator/AEXML.framework/AEXML -output /Users/runner/work/1/s/Carthage/Build/iOS/AEXML.framework/AEXML) 失败,退出代码 1:致命错误:/Applications /Xcode_12.3.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/lipo:/Users/runner/Library/Caches/org.carthage.CarthageKit/DerivedData/12.3_12C33/AEXML/4.6.0/Build /Intermediates.noindex/ArchiveIntermediates/AEXML iOS/IntermediateBuildFilesPath/UninstalledProducts/iphoneos/AEXML.framework/AEXML 和 /Users/runner/Library/Caches/org.carthage.CarthageKit/DerivedData/12.3_12C33/AEXML/4.6.0/Build/ Products/Release-iphonesimulator/AEXML.framework/AEXML 具有相同的架构 (arm64),并且不能位于同一个 fat 输出文件中
使用通用架构构建通用框架是不可能的。“AEXML”的设备和模拟器切片均针对以下版本构建:arm64 使用 --use-xcframeworks …
mobile carthage visual-studio-app-center visual-studio-app-center-distribute
因此,似乎在整个地方都有文档的精神,docs.microsoft再次取得了成功.
考虑发送推送通知,我遇到了这两个页面:
请注意,从任一页面到另一页面都没有引用.
所以我尝试搜索谷歌,对这个问题的标题进行类似的搜索,只发现上述两页以外的内容.
这让我想到了这个问题:App Center Push和Azure Notification Hub之间的关系(和/或区别)是什么?
push-notification azure-notificationhub uwp visual-studio-app-center
android ×3
ios ×2
react-native ×2
visual-studio-app-center-distribute ×2
.net ×1
app-store ×1
azure-devops ×1
build ×1
c# ×1
carthage ×1
cocoapods ×1
flutter ×1
mobile ×1
uwp ×1
xamarin ×1