TemplateStudio icon indicating copy to clipboard operation
TemplateStudio copied to clipboard

appmanifest file automatically updates without doing anything

Open touseefbsb opened this issue 3 years ago • 1 comments
trafficstars

Describe the bug

Out of nowhere when I open my uwp project which was generated by template studio a while ago, it automatically updates package.appmanifest file like so.

image

and then the build for the project just fails with following error.

image

I have tried to undo the changes to the file and build again but it just keeps on editing the file and never builds, however if I just undo the changes and quickly push the project to my azure devops build, it builds fine on azure devops. I have even tried re-cloning whole repo on my machine. Also please note that this happened previously as well a while ago but I just used to undo the file changes and then build worked fine but this time nothing is working.

To Reproduce

No response

Additional context

No response

Applies to the following platforms:

  • [ ] WinUI
  • [ ] WPF
  • [X] UWP

About your setup

  • Visual Studio Version: 2022 (17.3.3)
  • Template Studio Wizard Version: 3.5.19310.1
  • Windows Build: Windows 11

touseefbsb avatar Sep 09 '22 09:09 touseefbsb

Any more context you can provide for the repro?

mikebattista avatar Sep 13 '22 02:09 mikebattista

Based on the information available, it looks like you have both "Template Studio for UWP" (the official one) and "Matt's Template Studio for UWP" installed.

Additionally, it looks like the app was originally generated with version 3.5 of the WTS extension running on VS2019 and you've then tried to add a new item with a VS2022 version of the extension that doesn't have the same underlying framework support for the generated app and so it's tried to update the manifest with a "best guess" for the up-to-date data but has got in a muddle.

Here are my suggestions for what you can do going forward (untested but my best guess)

  • Only have one version of the extension installed that works with UWP apps.
  • Delete all metadata entries relating to the generation from the manifest file.

Additionally, the error in the screenshot relates to a different file than the file you have included a partial screenshot for.

If the issue is continuing to happen, can you please confirm that the file is being modified when you open the solution/project inside Visual Studio and do nothing else? Or is it happening when you perform a specific action with the extension?

mrlacey avatar Oct 01 '22 20:10 mrlacey

Closing out for now. Feel free to reopen if you figure out specifics of the failure or what in your environment might be causing it. You've got multiple possibly conflicting extensions installed and are working with an old Template Studio project which is unsupported at this point. My recommendation would be to only use the official extension and, if you need to, migrate the project forward to the latest templates.

mikebattista avatar Oct 12 '22 05:10 mikebattista