pmahend1 / PrettyXML

Pretty XML is a XML Formatter extension for Visual Studio Code
MIT License
27 stars 17 forks source link

Can not work normally #117

Closed ceh-ylhy closed 11 months ago

ceh-ylhy commented 1 year ago

Not working: image

Working: image

Hope that fixes it, thanks❤

pmahend1 commented 1 year ago

Thanks for reporting. Could you please share the XML inputs and PrettyXML logs in text format to investigate further?

ceh-ylhy commented 1 year ago

@pmahend1 To you later today, of course

ceh-ylhy commented 1 year ago

Working xml:

<effect_group tiered="false" name="Drink Tier 1">
<triggered_effect trigger="onSelfPrimaryActionEnd" action="ModifyCVar" cvar="CR01" operation="add" value="-10" />

<!--        <triggered_effect trigger="onSelfPrimaryActionEnd" action="RemoveBuff" target="self"  buff="buff1"/> -->
            </effect_group>

after format:

<effect_group tiered="false" name="Drink Tier 1">
    <triggered_effect trigger="onSelfPrimaryActionEnd" action="ModifyCVar" cvar="CR01" operation="add" value="-10" />
    <!-- <triggered_effect trigger="onSelfPrimaryActionEnd" action="RemoveBuff" target="self"  buff="buff1"/> -->
</effect_group>

Not working:

<effect_group tiered="false" name="Drink Tier 1">
<triggered_effect trigger="onSelfPrimaryActionEnd" action="ModifyCVar" cvar="CR01" operation="add" value="-10" />

<!--        <triggered_effect trigger="onSelfPrimaryActionEnd" action="RemoveBuff" target="self"  buff="buff病毒死亡倒计时"/> -->
            </effect_group>

log:

[ INFO - 19:22:45] provideDocumentFormattingEdits start
[ INFO - 19:22:45] getDocumentRange start
[ INFO - 19:22:45] getDocumentRange end
[ INFO - 19:22:45] formatXml start
[ INFO - 19:22:45] formatWithCommandLine start
[ INFO - 19:22:45] converted input to json {"xmlString":"<effect_group tiered=\"false\" name=\"Drink Tier 1\">\r\n<triggered_effect trigger=\"onSelfPrimaryActionEnd\" action=\"ModifyCVar\" cvar=\"CR01\" operation=\"add\" value=\"-10\" />\r\n\r\n<!-- \t\t<triggered_effect trigger=\"onSelfPrimaryActionEnd\" action=\"RemoveBuff\" target=\"self\"  buff=\"buff病毒死亡倒计时\"/> -->\r\n            </effect_group>","actionKind":"Format","formattingOptions":{"IndentLength":4,"UseSingleQuotes":false,"UseSelfClosingTags":true,"FormatOnSave":false,"AllowSingleQuoteInAttributeValue":true,"AddSpaceBeforeSelfClosingTag":true,"WrapCommentTextWithSpaces":true,"AllowWhiteSpaceUnicodesInAttributeValues":true,"PositionFirstAttributeOnSameLine":true,"PositionAllAttributesOnFirstLine":true,"EnableLogs":true}}
[ INFO - 19:22:45] Starting dotnet childProcess at c:\Users\Ylhy\.vscode\extensions\prateekmahendrakar.prettyxml-3.3.0\lib\XmlFormatter.CommandLine.dll 
[ WARNING - 19:22:46] childProcess errored with exitCode 3762504530
[ ERROR - 19:22:46] undefined : undefined
[ ERROR - 19:22:46] undefined : undefined
[ INFO - 19:22:46] provideDocumentFormattingEdits start
ceh-ylhy commented 1 year ago

@pmahend1 That's all the information above, I hope it can help you

pmahend1 commented 1 year ago

I did a quick check and was not able to reproduce it on my end. Please let me know what is the OS and version you are on. Also let me know .NET version installed on your machine.

Output

<effect_group tiered="false"
              name="Drink Tier 1">
    <triggered_effect trigger="onSelfPrimaryActionEnd"
                      action="ModifyCVar"
                      cvar="CR01"
                      operation="add"
                      value="-10" />
    <!-- <triggered_effect trigger="onSelfPrimaryActionEnd" action="RemoveBuff" target="self"  buff="buff病毒死亡倒计时"/> -->
</effect_group>

From your first screenshot it looks like Prettier plugin is also active. Please check by disabling that plugin too.

pmahend1 commented 1 year ago

Looking at the logs I think it has to do with .NET version not being able to handle it.

ceh-ylhy commented 1 year ago

OS: win 10 22H2 19045.3086 .NET:emmm... image

pmahend1 commented 1 year ago

To check dotnet version, please try dotnet --version on command line. You should have dotnet version 6 or higher.

ceh-ylhy commented 1 year ago

要检查 dotnet 版本,请尝试dotnet --version使用命令行。您应该拥有 dotnet 版本 6 或更高版本。

is 7.0.306

pmahend1 commented 1 year ago

Do you still have the issue?

ceh-ylhy commented 1 year ago

Do you still have the issue?

yes, So I'm temporarily using the plugin "XML Format" instead of🤔 Sorry I couldn't be more helpful

pmahend1 commented 1 year ago

Please check whether you have the fonts installed on your machine.

pmahend1 commented 11 months ago

Let me know if this is resolved now. Unfortunately I cannot do much unless I can reproduce this at my end.