Commit 9434b4b
[build] delete platform-31 folder on test jobs (#6103)
Context: #6089
We currently have lots of test failures due to the warning:
warning XA1008: The TargetFrameworkVersion (Android API level 30) is lower than the targetSdkVersion (31). Please increase the `$(TargetFrameworkVersion)` or decrease the `android:targetSdkVersion` in the `AndroidManifest.xml` so that the API levels match.
Looking at `Properties\AndroidManifest.xml`, Xamarin.ProjectTools
generated:
<uses-sdk android:minSdkVersion="19" android:targetSdkVersion="31" />
This appears to be due to the `GetMaxInstalledPlatform()` method:
https://github.com/xamarin/xamarin-android/blob/1b71da0cd3a44861b006ac41c77a24eedf066281/src/Xamarin.Android.Build.Tasks/Tests/Xamarin.ProjectTools/Android/AndroidSdkResolver.cs#L121-L138
I think what happened is:
* #6089 is opened, platform-31 gets installed on many of the CI
machines.
* Future PRs install `platform-S` side-by-side `platform-31`.
And so we ended up with test failures...
To fix this for now, manually delete the `sdk/platform-31` folder on
test jobs.1 parent ec2a35c commit 9434b4b
File tree
3 files changed
+16
-0
lines changed- build-tools/automation
- yaml-templates
3 files changed
+16
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
171 | 171 | | |
172 | 172 | | |
173 | 173 | | |
| 174 | + | |
| 175 | + | |
174 | 176 | | |
175 | 177 | | |
176 | 178 | | |
| |||
291 | 293 | | |
292 | 294 | | |
293 | 295 | | |
| 296 | + | |
| 297 | + | |
294 | 298 | | |
295 | 299 | | |
296 | 300 | | |
| |||
Lines changed: 10 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
Lines changed: 2 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
19 | 19 | | |
20 | 20 | | |
21 | 21 | | |
| 22 | + | |
| 23 | + | |
22 | 24 | | |
23 | 25 | | |
24 | 26 | | |
| |||
0 commit comments