You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
AndroidManifest not found with custom configurations #9540
I've waited nearly an hour on an android project to try publish a release build and its taken so long I gave up on it so posting my concern here. As this is my first attempt on a MAUI release build I cannot comment on previous versions.
Got this working through the command line by specifying both the framework and configuration dotnet/maui#24621.
I did initially get an error though through the command line though which was a bit more revealing then the VS GUI.
error XA1018: Specified AndroidManifest file does not exist: C:\xxxx\Platforms\Android\Release\AndroidManifest.xml.
I Resolved this by specifying the --configuration so my guess is perhaps because we use different configurations i.e. AndroidManifest files placed in certain directories, that it defaulted to a Release path although the issue I see here is that it did not honor the AndroidManifest path as defined in the .csproj file like the following
Any issue(s) with the VS Archiving experience would be owned by the VS integration team who does not use GitHub for issue tracking.
Please use the tools available inside of VS to report this issue. This allows the issue to be routed to the correct team, and provides them the correct logs they need to diagnose it.
As for the command line error:
error XA1018: Specified AndroidManifest file does not exist: C:\xxxx\Platforms\Android\Release\AndroidManifest.xml.
@jonathanpeppers@dellis1972 Would this be expected if custom configurations are being used? Or do we possibly have a bug here?
It's hard to say without a build log, can you share a .binlog file that contains the error? https://aka.ms/binlog
In general, I would only use Debug and Release for your configuration names, as no one knows the full set of properties you would need to set to make a configuration such as DebugFoo or ReleaseFoo correct:
Also, I have the MSBuild_Logs folder, is there a particular .binlog file you would like or the entire folder? To avoid exposing sensitive information should I share this with you directly?
You can share with my email on my Github repo if you like. Can you just use Configuration=Release for everything? And then invent a new property like -p:Foo=true to make changes for a special build?
@jonathanpeppers Maybe but I don't see how that's a whole lot different to specifying as a configuration i.e. Configuration=CustomFoo vs -p:BuildFlavor=CustomFoo and correct if I am wrong but I lose the benefit of the DefineConstants when switching between the configurations.
@jonathanpeppers correction I might have confused myself here, what your saying here is I can just use the custom property -p for selecting the correct signing identities and the manifests/info.plist files?
Yes, using any property other than $(Configuration) would work. Otherwise you would need to review a .binlog from a build to discover the set of properties for a Debug-like configuration vs a Release-like one. No one really knows the full list as noted in the dotnet/sdk issue above.
As of now I can do the publishing via the cmd line without any issues by explicitly specifying the config, as I'm a little snowed under other things including wrapping up our migration Ill try revisit this again later and if this becomes an issue.
Activity
LeoJHarris commentedon Nov 21, 2024
UPDATE:
Got this working through the command line by specifying both the framework and configuration dotnet/maui#24621.
I did initially get an error though through the command line though which was a bit more revealing then the VS GUI.
I Resolved this by specifying the --configuration so my guess is perhaps because we use different configurations i.e.
AndroidManifestfiles placed in certain directories, that it defaulted to aReleasepath although the issue I see here is that it did not honor the AndroidManifest path as defined in the .csproj file like the followingjpobst commentedon Nov 21, 2024
Any issue(s) with the VS Archiving experience would be owned by the VS integration team who does not use GitHub for issue tracking.
Please use the tools available inside of VS to report this issue. This allows the issue to be routed to the correct team, and provides them the correct logs they need to diagnose it.
As for the command line error:
@jonathanpeppers @dellis1972 Would this be expected if custom configurations are being used? Or do we possibly have a bug here?
[-]Android Publishing Gets Stuck on Archiving[/-][+]AndroidManifest not found with custom configurations[/+]jonathanpeppers commentedon Nov 21, 2024
It's hard to say without a build log, can you share a
.binlogfile that contains the error? https://aka.ms/binlogIn general, I would only use
DebugandReleasefor your configuration names, as no one knows the full set of properties you would need to set to make a configuration such asDebugFooorReleaseFoocorrect:$(Configuration)names sdk#31918LeoJHarris commentedon Nov 25, 2024
@jonathanpeppers We do something like the following to get the full set of properties depending on the Constants defined.
Also, I have the MSBuild_Logs folder, is there a particular .binlog file you would like or the entire folder? To avoid exposing sensitive information should I share this with you directly?
jonathanpeppers commentedon Dec 2, 2024
You can share with my email on my Github repo if you like. Can you just use
Configuration=Releasefor everything? And then invent a new property like-p:Foo=trueto make changes for a special build?LeoJHarris commentedon Dec 11, 2024
@jonathanpeppers Maybe but I don't see how that's a whole lot different to specifying as a configuration i.e.
Configuration=CustomFoovs-p:BuildFlavor=CustomFooand correct if I am wrong but I lose the benefit of theDefineConstantswhen switching between the configurations.LeoJHarris commentedon Dec 11, 2024
@jonathanpeppers correction I might have confused myself here, what your saying here is I can just use the custom property
-pfor selecting the correct signing identities and the manifests/info.plist files?jonathanpeppers commentedon Dec 11, 2024
Yes, using any property other than $(Configuration) would work. Otherwise you would need to review a .binlog from a build to discover the set of properties for a Debug-like configuration vs a Release-like one. No one really knows the full list as noted in the dotnet/sdk issue above.
LeoJHarris commentedon Dec 11, 2024
As of now I can do the publishing via the cmd line without any issues by explicitly specifying the config, as I'm a little snowed under other things including wrapping up our migration Ill try revisit this again later and if this becomes an issue.