-
Notifications
You must be signed in to change notification settings - Fork 223
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
.NET 6 #86
Comments
This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 7 days if no further requests are made to keep it open. |
We are working on .NET 5.0 support. Should be available by the end of the year. |
We added .NET 5.0 this week. Please let us know if you notice any issues. |
I just tried to run my pipeline again I am still getting an error |
Thanks for reporting. We'll take another look. |
I know this appcenter related and not azure devops, but I have the exact same problem with azure devops pipeline. Any idea how to solve that? Workaround? Thanks and Greetz |
Hi @MasterEmit, @dersia, Thank you. |
Same issue here. Any updates? |
I'm trying to compile a Xamarin Android app that references a .NET Standard library whose LangVersion is set to 9, and I'm getting the same error. <PropertyGroup>
<TargetFramework>netstandard2.1</TargetFramework>
<DebugType>portable</DebugType>
<ProduceReferenceAssembly>true</ProduceReferenceAssembly>
<Configurations>Debug;Test</Configurations>
<LangVersion>9</LangVersion>
</PropertyGroup> |
I have the same issue. My C Sharp 9 code has stopped compiling on app center android. |
Hi folks, Thanks! |
@AlenaSviridenko I included the elements in the csproj file that will cause the failure. So repro steps would be:
|
@AlenaSviridenko Repro:
|
Sorry it took me some time to come back to you. Basically you just need a csproj file that has the following flag <LangVersion>9</LangVersion> I found a workaround for those who are still looking, but it only works with a custom build script (github action, azure pipelines) WorkaroundiOSmono '/Applications/Visual Studio.app/Contents/Resources/lib/monodevelop/bin/MSBuild/Current/bin/msbuild.dll' /p:Configuration=Release /p:Platform=iPhone <path/to/solutionfile.sln> Androidmono '/Applications/Visual Studio.app/Contents/Resources/lib/monodevelop/bin/MSBuild/Current/bin/msbuild.dll' /p:Configuration=Release /p:Platform=PackageForAndroid <path/to/android/project.csproj> Why it worksusing the MSBuild from the Path Hope this helps |
I´m not sure where your metrics are coming from but you should have noticed that there is a spike in build failures due to C# 9.0 syntax issues.
I had the following in my Xamarin.Forms app if (e.Source is ShellNavigationSource.Pop or ShellNavigationSource.PopToRoot or ShellNavigationSource.Remove)
{...} Visual Studio Mac which is installed on Mac Build Agents could/should be used for building the dlls. |
@dersia thanks for the workaround. What exactly do I do with your mono '/Applications/Visual Studio.app/Contents/Resources/lib/monodevelop/bin/MSBuild/Current/bin/msbuild.dll' /p:Configuration=Release /p:Platform=iPhone <path/to/solutionfile.sln> Is this a build script I need to add in app center, or something in VS, or something else entirely? |
@AdamDiament If you need further help, please let me know. |
@ECDev01 my instructions are for a mac build agent and a macos system respectively |
So there will be no official support for NET MAUI with NET 6? |
You can do the same with github actions, at x10 the price of appcenter (mac vm on github actions consumes x10 credits), and with a non intuitive and complicated UI and scripts (appcenter is simple to use, github actions are horrible). |
I asked for help to appcenter support and they recommend Azure Pipelines, basically @ericbrunner suggestion, by the way, trying to install .NET 6 didn't work at all. Anyway, creating the pipeline for the building process is enough, so now I am building my app using Azure Pipelines (yaml) and the distribution is handled by appcenter. |
Any idea why iOS crashes when Android works well with AppCenter on .Net 6??? |
This is good question and bugs me. I have a unit test project on .net 6 in xamarin.forms project. Basically looks like this
On my build configuration, i have excluded Unit test project and I have choosen Project to be build as "IOS" project but Appcenter build is failing as ".net 6" not supported. Obviously there is a bug for IOS builds whatever you choose, it build all projects in the Project solution. |
Hi @themronion, Thanks in advance. |
We tried to do this (https://codetraveler.io/2019/08/23/using-preview-versions-of-net-core-with-app-center-build/ I don't even need .net 6 for our Xamarin app, but we have our API project in the same solution file - and app center tries to restore it. This has forced us to stick with .net 5 for our API. Does any know how to work around this? I'd like to upgrade our APIs to .net 6 but app center builds then fail. |
I've tried to import the build definition into Azure DevOps after it has been exported from AppCenter.
So this is not related to AppCenter only, because of course, it is backed up by the Azure Devops infrastructure. |
Any news here? I've also switched to net6.0-ios recently. Now I can't build my project with appcenter. Same problem as described above. |
Still no updates? You guys promoting app center and maui and c# 10 and here we are in this issue :) Looks like MS does not care to the consumers :) y'all just promoting bunch of stuff that will be broke some time soon |
Any updates on this? |
See also #2500 which may be related to this issue, although I find Android, Windows and iOS targets are working with .NET MAUI + .NET 7, the problem is only with MacCatalyst. |
Hi all! We support .NET 6 and MAUI in our latest SDK 5.0.1. Check out this release and let us know if you have any feedback. We'd love to hear from you. https://github.com/Microsoft/AppCenter-SDK-DotNet/releases |
@omatrot Since it appears that App Center is now abandonware try to add this to your pipeline: - task: UseDotNet@2
inputs:
packageType: 'sdk'
version: '6.0.x' |
that may solve the problem with Maui but how does this resolve issue with the Unit-tests targeting .net 6? Please see my other comment below.
|
I have ASP.NETCore net6 application and in windows AppCenter fail to start... |
Eu tenho o aplicativo ASP.NETCore net6 e no Windows AppCenter falha ao iniciar ... |
I can't compile with C# 10 and 11 yet, is everything too updated for AppCenter or what?? |
This issue has been automatically marked as stale because it has not had any activity for 60 days. It will be closed if no further activity occurs within 15 days of this comment. |
This issue has been automatically marked as stale because it has not had any activity for 60 days. It will be closed if no further activity occurs within 15 days of this comment. |
Bump |
This is really getting worse and worse. Now Appcenter team changed something and i am getting error even for Android. Although my Build Configuration is targeting .Android.csproj not the solution file, Appcenter is building entire solution by ignoring the configuration file. I can see that Appcenter uses a bash script that restores nuget and builds entire solution, not the specified Project in the configuration. |
AFAIK the downloading of all nugets isn't new. We have post clone scripts that will delete other csproj files that we don't need restored. I'll try dig them up later when I am at my PC. |
This is our #!/usr/bin/env bash
# App Center custom build scripts: https://aka.ms/docs/build/custom/scripts
echo "Disabling MYAPP.iOS.csproj to avoid updating nugets."
# Delete MYAPP.iOS from MYAPP.Forms.sln
SLN_PATH=$BUILD_REPOSITORY_LOCALPATH/Software/MYAPP.Forms.sln
sed -i.bak '/MYAPP.iOS/{N;d;}' $SLN_PATH
rm -f ${SLN_PATH}.bak
# Delete MYAPP.iOS.csproj from the disk.
rm -f $BUILD_REPOSITORY_LOCALPATH/Software/MYAPP.Forms/MYAPP.iOS/MYAPP.iOS.csproj |
We have net 8 but this library still not support net 6 this is really frustrating... |
We have updated our project to .net 5 preview. But CI doesn't support it (.net core 3 is the latest). Please add support for .net 5
The text was updated successfully, but these errors were encountered: