Closed TheAlmightyBob closed 3 years ago
Hm. I forgot about AppCenter...
Hi, any news about new version? What's wrong with the AppCenter, I don't seem to have access to those pipelines?
Hi @maxkoshevoi . I hadn't forgotten about this, just been very busy. This weekend is a long weekend though, so hopefully I'll be able to find some time to dig in.
Yeah, I'm a bit confused on the AppCenter setup actually... the theoretical benefit of using it is that it runs and shows results on the PRs, and that it actually runs on Macs and builds the native iOS/Android test projects rather than just the library itself. However, it didn't run on your PR, and I guess you're unable to view the results for this PR? That makes it seem less-useful...
But I still like the idea of having PR checks and building the test projects, so want to at least try fixing it rather than just disabling it now...
Anyhow, the actual failures seem environment-related, I'm guessing because this library is so old.... hopefully updating some target versions for iOS/Android (just as was already being done for Windows here) will help...? Unsure if the actual AppCenter configuration needs to be updated.
iOS Error:
xcode-select: error: invalid developer directory '/Applications/Xcode_11.1.app/Contents/Developer'
(I'm really not sure what's looking for that... this is where I'm wondering if this is an issue with the AppCenter configuration...)
Android errors:
"/Users/runner/work/1/s/Tests/Calendars.Plugin.Android.Tests/Calendars.Plugin.Android.Tests.csproj" (PackageForAndroid target) (1) ->
(_ValidateAndroidPackageProperties target) ->
/Library/Frameworks/Mono.framework/External/xbuild/Xamarin/Android/Xamarin.Android.Common.targets(737,2): error XA5207: Could not find android.jar for API Level 19. This means the Android SDK platform for API Level 19 is not installed. Either install it in the Android SDK Manager (Tools > Open Android SDK Manager...), or change your Xamarin.Android project to target an API version that is installed. (/Users/runner/Library/Android/sdk/platforms/android-19/android.jar missing.) [/Users/runner/work/1/s/Tests/Calendars.Plugin.Android.Tests/Calendars.Plugin.Android.Tests.csproj]
But I still like the idea of having PR checks and building the test projects, so want to at least try fixing it rather than just disabling it now.
Yeah, CI is great, you definitely should keep it. But I cannot see AppCenter results (you can try to open an AppCenter build from a private window and see for yourself).
the theoretical benefit of using it is that it runs and shows results on the PRs, and that it actually runs on Macs and builds the native iOS/Android test projects rather than just the library itself.
You can use GitHub Action for that. They are free, also run on whatever platform you need (as long as it's linux, windows or mac) and results are public.
Android errors:
This one explicitly says what's wrong: This means the Android SDK platform for API Level 19 is not installed.
I think, you should be able to use latest SDK (30) to build your app and keep minSdk as 19.
iOS Error:
Have no idea what iOS error means since I've never developed for it. But totally possible that it's also an SDK problem.
You can use GitHub Action for that.
I actually thought this did use GitHub Actions, but apparently not. This might have predated those... I remember the AppCenter integration was very new when I set it up and there were a lot of kinks to work out back then... Do you happen to know of other Xamarin projects that are using GitHub Actions?
I think you're right about Android and will try that when I get time.
Do you happen to know of other Xamarin projects that are using GitHub Actions?
I use them to build one of mine: https://github.com/maxkoshevoi/NureTimetable/blob/main/.github/workflows/build.yml
So nullable annotations improved with new SDK? Interesting. Maybe some null checks can now be removed
So nullable annotations improved with new SDK? Interesting. Maybe some null checks can now be removed
That was my hope, but unfortunately seems like the opposite to me... just as many things return null
, but now fewer things accept null arguments...
Now it looks like both iOS and Android are failing with the same syntax errors.... progress?? 😬
So it looks like now the failures are due to the C#9 usage, and it turns out this is simply a known issue with AppCenter... it does not support C#9. And AppCenter itself is no longer being supported, so this won't be fixed. I was unaware of this... boy it didn't last long.
I'll try a workaround or two from the various GitHub issue comments, but chances are I'll need to abandon AppCenter and look into GitHub Actions after all (if so, I won't hold up this release for that).
this is simply a known issue with AppCenter... it does not support C#9
Oh, right. That's why I moved to GitHub Action in the first place. I thought they fixed it be now.
AppCenter itself is no longer being supported, so this won't be fixed
Didn't know about that. Is it just builds that are not supported or whole AppCenter (issue tracking and other things)?
this is simply a known issue with AppCenter... it does not support C#9
Oh, right. That's why I moved to GitHub Action in the first place. I thought they fixed it be now.
Yeah there are a lot of angry comments in the GitHub issues of "I can't believe you haven't fixed this yet, it's been so long" etc.
AppCenter itself is no longer being supported, so this won't be fixed
Didn't know about that. Is it just builds that are not supported or whole AppCenter (issue tracking and other things)?
"No longer being supported" was perhaps a slight exaggeration on my part. It is in "maintenance mode," and they consider this to be a "new feature" and thus out of scope: https://github.com/microsoft/appcenter/wiki/Roadmap https://github.com/microsoft/appcenter/issues/2120#issuecomment-797598264
Hm. Okay, AppCenter is now passing on the FixCI branch itself.... just not on the PR? I guess the PR uses different configuration. Hopefully this is close to working though...
According to https://cakebuild.net/docs/getting-started/upgrade#argument-syntax, the latest version of Cake requires more dashes.
After fixing that, there were still some Windows-specific errors, which appear to have been resolved by updating the target version (which was quite a few years old at this point).