dotnet / maui

.NET MAUI is the .NET Multi-platform App UI, a framework for building native device applications spanning mobile, tablet, and desktop.
https://dot.net/maui
MIT License
22.04k stars 1.73k forks source link

Can't create APK file - Error AMM000 #11682

Closed joaquim66 closed 1 year ago

joaquim66 commented 1 year ago

Description

Created a normal .net maui application, it was so normal that it does nothing: is the regular Hello World application automaticaly generated when you create your first .net maui application. Than run it on the emulator: OK; Than prepare to compile it an publish to install on my mobile phone. The only things i changed in project properties was Android Manifest:

Steps to Reproduce

  1. Using Visual Studio 2022 17.4.1 on a Windows 10 Enterprise 21H2;
  2. created a .net maui application;
  3. Run it on emulator (Pixel 5 - API 29 (Android 10.0): ok;
  4. In project properties, Android Manifest: set name of the app;
  5. In project properties, Android Manifest: set name of the package;
  6. generated a keystore file with the keytool as explained here: https://learn.microsoft.com/en-us/dotnet/maui/android/deployment/publish-cli?view=net-maui-7.0
  7. In project properties , in "Android signing": Set true to Sign the app,
  8. In project properties, in android signing select the keystore file in the key repository, filled in the password, filled in the alias for the key;
  9. Select compile soluction 2022-11-27 10_07_09-

Link to public reproduction project repository

-

Version with bug

Unknown/Other (please specify)

Last version that worked well

Unknown/Other

Affected platforms

Android

Affected platform versions

Android 10

Did you find any workaround?

No

Relevant log output

No response

joaquim66 commented 1 year ago

After some googling found a answer, in stack overflow, to some case smiliar to mine, saying "As a consequence of adding the package name via the options of the project, the AndroidManifest.xml package attribute was updated, wich is what is expected, but there was also a tag that was being added, wich was unwanted. The tag was the following:

<uses-sdk />

It would be enough to remove this line. I've done so and afterwards the AMM000 error disapears.

ghost commented 1 year ago

Thanks for the issue report @joaquim66! This issue appears to be a problem with Visual Studio, so we ask that you use the VS feedback tool to report the issue. That way it will get to the routed to the team that owns this experience in VS.

If you encounter a problem with Visual Studio, we want to know about it so that we can diagnose and fix it. By using the Report a Problem tool, you can collect detailed information about the problem, and send it to Microsoft with just a few button clicks.

  1. Go to the Visual Studio for Windows feedback tool or Visual Studio for Mac feedback tool to report the issue
  2. Close this bug, and consider adding a link to the VS Feedback issue so that others can follow its activity there.

This issue will be automatically closed in 3 days if there are no further comments.

ghost commented 1 year ago

This issue is being closed due to inactivity. If this issue is still affecting you, please follow the steps above to use the VS Feedback Tool to report the issue.