Nuget Plugin.Messaging fails to Deploy on latest VS2019 Version 16.9.0-Update
Xam.Plugins.Messaging does not deploy after Build 3.2.1 which is missing Settings(). Latest 5.2.0 compiles successfully buy does not Deploy with error
.../assets/Plugin.Messaging.pdb because its being used by another process...
Xamarin
-
JessieZhang-MSFT 7,706 Reputation points • Microsoft Vendor
2021-03-08T01:53:47.127+00:00 Latest 5.2.0 compiles successfully buy does not Deploy with error
Hi @Universal Camera ,I did a test but I couldn't reproduce this problem. You can try to restart you PC and visual studio, and try again.
-
Universal Camera 276 Reputation points
2021-03-08T02:21:38.617+00:00 Thanks for looking...
So I did recent update on both Windows and VS2019. Prior to this I have an old application that is a working application. But after upgrade the old application fail to deploy.
So I created a new App1 with CrossPlatform Xamarin.Forms. Did Nuget Updates which there were none and then deployed to Android 10 Mobile Device. This was successful.
I then installed through Nuget Xam.Plugins.Messaging as a reference in only PCL and Android. Try to deploy it to same device and it failed.
I then deleted both reference (PCL and Android) and tried to deploy to same device and it was successful.
I then tried including various version of Xam. The versions 3.2.1 or lower deploy successfully. But I need higher then 4.0.0 since earlier version does not support Settings().
Thanks
-
JessieZhang-MSFT 7,706 Reputation points • Microsoft Vendor
2021-03-09T06:18:19.703+00:00 I tried to install nuget
Xam.Plugin.Messaging
5.2.0 and I couldn't reproduce this problem. Would you please help share your steps? -
Universal Camera 276 Reputation points
2021-03-09T13:14:40.367+00:00 Heading
So the outlined steps are for VS2019 Community.
How do I restore VS to previous build?
I really need my App back on my device. Do you have suggestions?
-
JessieZhang-MSFT 7,706 Reputation points • Microsoft Vendor
2021-03-11T02:31:28.133+00:00 Sorry,I couldn't find the steps you posted.
You can try to delete bin and obj folders, then restart VS and try again .
-
Universal Camera 276 Reputation points
2021-03-11T05:46:15.637+00:00 strong text
Thanks for looking...this is what I sent earlier... sorry you didn't see it...I have tried all your recommendations without success.
So I did recent update on both Windows and VS2019. Prior to this I have an old application that is a working application. But after upgrade the old application fail to deploy.
So I created a new App1 with CrossPlatform Xamarin.Forms. Did Nuget Updates which there were none and then deployed to Android 10 Mobile Device. This was successful.
I then installed through Nuget Xam.Plugins.Messaging as a reference in only PCL and Android. Try to deploy it to same device and it failed.
I then deleted both reference (PCL and Android) and tried to deploy to same device and it was successful.
I then tried including various version of Xam. The versions 3.2.1 or lower deploy successfully. But I need higher then 4.0.0 since earlier version does not support Settings().
Thanks
-
JessieZhang-MSFT 7,706 Reputation points • Microsoft Vendor
2021-03-11T08:22:46.643+00:00 I then installed through Nuget Xam.Plugins.Messaging as a reference in only PCL and Android. Try to deploy it to same device and it failed.
Could you please post a basic demo to github or onedriver so that we can test on our side?
-
Universal Camera 276 Reputation points
2021-03-11T19:36:54.133+00:00 thank you
There is really nothing to post. I am creating a brand new App1 in VS2019 Community 16.9.1.
This new App1 compiles and successfully deploys to Android 11 Phone.
However if I just add a just a reference to Xam.Plugins.Messaging then it compiles but does not Deploy to device with errorThe Process cannot access file ...\Plugins.Messaging.pdb because it is being used by another process...
thans
-
JessieZhang-MSFT 7,706 Reputation points • Microsoft Vendor
2021-03-14T08:17:11.55+00:00 I created a new app again and installed nuget
Xam.Plugins.Messaging
, and when I tried to deploy it , there was a similar error . But after I tried to delete the obj and bin folders ,restart my Visual studio and resbuilt it , my app could been deployed to my device successfully.
And the nugets in my app is:
-
Universal Camera 276 Reputation points
2021-03-14T08:44:17.123+00:00 thank you
Good effort. When I match your GIT I get the same "Busy Process" issue.
However if you use the latest GIT and put VS2019 into Release mode then it deploys. However, Android 11 does not turn on the speakerphone. But, Android 10 does turn on the speakerphone.
I think you have done a good job to show the team that there is a problem in deployment and most importantly in the AudioManager for turning on the speakerphone.
I will look forward to you!
Thank you -
JessieZhang-MSFT 7,706 Reputation points • Microsoft Vendor
2021-03-15T07:27:16.11+00:00 However if you use the latest GIT and put VS2019 into Release mode then it deploys.
Do you mean you have resolved this problem by putting your app to github and set VS to Release mode,right ? Congrats. For the new problem , we can talk it in another thread: https://learn.microsoft.com/en-us/answers/questions/312067/speakerphone-not-responding-on-android-11-but-resp.html
-
Universal Camera 276 Reputation points
2021-03-15T13:27:57.297+00:00 Thank you
Sorry for confusion...rather than compiling it under Debug mode in VS2019 where it doesn't deploy I put it into Release mode and now it deploys. This does not allow me to debug the code.
But the biggest problem persist with speaker phone.
Can you recommend another way to turns-on the speakerphone in Android 11. The above code turns-on the Speakerphone in Android 10.
Thank you
-
JessieZhang-MSFT 7,706 Reputation points • Microsoft Vendor
2021-03-16T02:03:25.013+00:00 Hi @Universal Camera , if we check link Xam.Plugins.Messaging ,we will find that nuget
Xam.Plugins.Messaging
hasn't been updated for a long time. So we don't recommend you to useXam.Plugins.Messaging
. And we recommend you useXamarin.Essentials
, which includes the features you need above. You can check it here: https://learn.microsoft.com/en-us/xamarin/essentials/phone-dialer?context=xamarin%2Fandroid&tabs=android -
Universal Camera 276 Reputation points
2021-03-16T05:35:27.79+00:00 Thank you
So based on your suggestion Plugin.Messaging is not working. Xamarin.Essential does not have AutoDial=true option while Plugin does therefore it really would be nice to fix Plugin.Messaging library.
Thank you
-
JessieZhang-MSFT 7,706 Reputation points • Microsoft Vendor
2021-03-17T09:52:10.28+00:00 For this, you can post a new feature request here : https://github.com/xamarin/Essentials/issues .
-
Adam Hill 1 Reputation point
2021-03-18T16:38:26.51+00:00 I have a production app in the stores this is now happening to as well after upgrading to VS 16.9.2.
Release mode does not fix it either.
Since we now have >1 confirmed report caused can someone from MS suggest a workaround since we have narrowed this down to the VS upgrade?
Upgrading to Xam.Essentials is not an option at the moment for us as well.
Any ideas?
-
Universal Camera 276 Reputation points
2021-03-18T17:09:48.02+00:00 Thank you
Brilliant!
Thank you
-
JessieZhang-MSFT 7,706 Reputation points • Microsoft Vendor
2021-03-20T05:34:08.79+00:00 After the VS upgrade, does the problem occur in one app, or in other apps?
-
Universal Camera 276 Reputation points
2021-03-20T15:36:39.11+00:00 Thank you
After upgrade AudioManager does not turn on SpeakerPhone on Android 11 phone. However, after the upgrade AudioManager still turn on SpeakerPhone on Android 10.
Thank you!
-
Adam Hill 1 Reputation point
2021-03-22T15:01:12.227+00:00 Only the Xamarin app.
We only have one Xamarin app that uses Plugin.Messaging, but all other projects:
- WebAPI
- pure desktop & mobile dotNet support libraries
- WinForms with and without ADO
- straight up .aspx style web apps
- apps with Entity Framework (Core and .NET Framework style, Web and Desktop)
All compile and deploy fine.
There is something about the Nuget. I removed the package and commented out all code referencing it. It built and released just fine.
-
JessieZhang-MSFT 7,706 Reputation points • Microsoft Vendor
2021-03-23T05:54:43.103+00:00 When we check Xam.Plugins.Messaging , we will find that nuget Xam.Plugins.Messaging hasn't been updated for long time. So we don't recommend it.
-
Universal Camera 276 Reputation points
2021-04-02T16:26:39.42+00:00 Thank you
Do you any idea the time line for AudioManager fix. Is there another way to turn-on speakerphone during phone call besides AudioManager.
I have written alternative solution to Xam.Plugin so that issue is not impacting me.
Thank you
Sign in to comment