AzureArchitecture / threat-model-templates

Templates for the Microsoft Threat Modeling Tool
MIT License
137 stars 40 forks source link

Cannot open saved diagram using AzureTemplate.v5.tb7 #7

Closed weixian-zhang closed 2 years ago

weixian-zhang commented 2 years ago

Describe the bug Using Azure stencils from AzureTemplate.v5.tb7, when opening a saved diagram an error occurred (below screenshot) causing diagram unable to open.

To Reproduce

Expected behavior Diagram should open correctly without error

Screenshots image
image

Desktop (please complete the following information):

Smartphone (please complete the following information): Windows 11

adirao99 commented 2 years ago

@PatrickGallucci I am also facing the same problem like weixian, could you please provide us with a workaround or fix? Thank you

dmitrykarnitski commented 2 years ago

Hi,

I applied one workaround that helped me at least, maybe it will be useful for someone else.

  1. Open a diagram that is not opening using any text editor (e.g. notepad)
  2. Find '' string
  3. Replace System.String[] value with any version (e.g. 3.0)
  4. Open a downloaded template using any text editor (e.g. notepad)
  5. Find 'Manifest' node -> 'version' attribute
  6. Replace System.String[] value with any version (e.g. 3.0) <-- make sure version is aligned with the version from the diagram

If you have only downloaded a template and have not started work on a diagram, then you are lucky and you can just apply steps 4-6 and the newly created diagram that is based on the template should be opening correctly (can't promise, but at least it works for me now).

PatrickGallucci commented 2 years ago

Thanks!