I have configured appcenter build for my flutter application and when I run the build from appcenter, getting the following error:
FAILURE: Build failed with an exception.
Where:
Settings file '/Users/runner/work/1/s/android/settings.gradle' line: 11
What went wrong:
A problem occurred evaluating settings 'android'.
> java.net.URISyntaxException: Illegal character in opaque part at index 2: C:\Users\...\Flutter\sdk\flutter_windows_2.8.1-stable\flutter\packages\flutter_tools\gradle\app_plugin_loader.gradle
BUILD FAILED in 14s
Error: /Users/runner/work/1/s/android/gradlew failed with return code: 1
at ChildProcess.<anonymous> (/Users/runner/work/_tasks/Gradle_8d8eebd8-2b94-4c97-85af-839254cc6da4/1.128.0/node_modules/vsts-task-lib/toolrunner.js:569:30)
at emitTwo (events.js:106:13)
at ChildProcess.emit (events.js:191:7)
at maybeClose (internal/child_process.js:920:16)
at Socket.<anonymous> (internal/child_process.js:351:11)
at emitOne (events.js:96:13)
at Socket.emit (events.js:188:7)
at Pipe._handle.close [as _onclose] (net.js:509:12)
##[error]Error: /Users/runner/work/1/s/android/gradlew failed with return code: 1
//settings.gradle
include ':app'
def localPropertiesFile = new File(rootProject.projectDir, "local.properties")
def properties = new Properties()
assert localPropertiesFile.exists()
localPropertiesFile.withReader("UTF-8") { reader -> properties.load(reader) }
def flutterSdkPath = properties.getProperty("flutter.sdk")
assert flutterSdkPath != null, "flutter.sdk not set in local.properties"
apply from: "$flutterSdkPath\packages\flutter_tools\gradle\app_plugin_loader.gradle"
//local.properties
sdk.dir=C:\Users\..\AppData\Local\Android\sdk
flutter.sdk=C:\Users\..\Flutter\sdk\flutter_windows_2.8.1-stable\flutter
flutter.buildMode=debug
flutter.versionName=1.0.0
flutter.versionCode=1
Any idea whats happening here please?
Note: I am able to successfully run the application from android studio.