Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

c# testdata - Power_2.log.txt vs Power_2.log.xml #16

Closed
sebastientromp opened this issue Dec 4, 2015 · 3 comments
Closed

c# testdata - Power_2.log.txt vs Power_2.log.xml #16

sebastientromp opened this issue Dec 4, 2015 · 3 comments
Labels

Comments

@sebastientromp
Copy link

In Power_2.log.txt, starting from line 558, you can see (in order):

  • ACTION_START
  • Choices
  • TAG_CHANGE
  • Choices
  • TAG_CHANGE
  • ACTION_START
  • ACTION_END
  • etc.

The XML present in the test data however doesn't nest these elements, and produces:

<Action entity="1" index="-1" type="5">
    <TagChange entity="3" tag="305" value="1"/>
    <Choices entity="1" max="3" min="0" playerID="1" source="1" type="MULLIGAN">
        <Choice entity="8" index="0"/>
        <Choice entity="16" index="1"/>
        <Choice entity="33" index="2"/>
    </Choices>
</Action>
<TagChange entity="2" tag="305" value="1"/>
<Choices entity="2" max="5" min="0" playerID="2" source="1" type="MULLIGAN">
    <Choice entity="54" index="0"/>
    <Choice entity="49" index="1"/>
    <Choice entity="55" index="2"/>
    <Choice entity="43" index="3"/>
    <Choice entity="68" index="4"/>
</Choices>

while I would expect something like

<Action entity="1" index="-1" target="0" ts="01:41:27.9112918" type="5">
    <TagChange entity="2" tag="305" value="1"/>
    <Choices entity="1" max="3" min="0" playerID="1" source="1" taskList="0" ts="01:41:27.9312929" type="1">
        <Choice entity="8" index="0"/>
        <Choice entity="16" index="1"/>
        <Choice entity="33" index="2"/>
    </Choices>
    <TagChange entity="3" tag="305" value="1"/>
    <Choices entity="2" max="5" min="0" playerID="2" source="1" taskList="0" ts="01:41:28.0212980" type="1">
        <Choice entity="54" index="0"/>
        <Choice entity="49" index="1"/>
        <Choice entity="55" index="2"/>
        <Choice entity="43" index="3"/>
        <Choice entity="68" index="4"/>
    </Choices>
    <TagChange entity="2" tag="305" value="2"/>
    <Action entity="2" index="-1" target="0" ts="01:41:47.1423917" type="5">
        <TagChange entity="25" tag="49" value="3"/>
        <TagChange entity="25" tag="263" value="1"/>
        <TagChange entity="8" tag="49" value="2"/>
        <TagChange entity="8" tag="263" value="0"/>
        <TagChange entity="28" tag="49" value="3"/>
        <TagChange entity="28" tag="263" value="2"/>
        <TagChange entity="16" tag="49" value="2"/>
        <TagChange entity="16" tag="263" value="0"/>
        <TagChange entity="2" tag="305" value="3"/>
    </Action>
        ...

Is this the intended behaviour?

Thanks!

Seb

@azeier
Copy link
Member

azeier commented Dec 4, 2015

IIRC, that xml was actually generated by the python implementaion (for comparison purposes) and is incorrect due to an issue that was fixed by now: HearthSim/hsreplay-xml@60f882b.

@sebastientromp
Copy link
Author

Good to know :)

I'm working on a Java implementation (can't use c# nor python) - would you have any example of an XML <-> Log pair that I could use for a first high level validation? I'd like to avoid generating them myself if possible as I'm not really familiar with all of this yet.

@jleclanche
Copy link
Member

Closing bugs from deprecated c# interface.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Development

No branches or pull requests

3 participants