#382 Patch for ParseGathererOracle

Bug
closed
patch (3)
4
2014-08-11
2014-08-10
Bjoern Schmidt
No

Hi,

this patch fixed a bug in ParseGathererOracle. The regular expression of expansionPattern do not work correctly. It find not the "Expansion" value but the first "All Set" value which is in most cases valid but failed if more than one sets are available and the first value is not the expansion itself.
As an example if you select all three check boxes, "Alara Reborn" as Set and "Chinese Simplified" for the update process you will see that two cards are missing (Terminate/176449 and Meddling Mage/179547) after the update. In case of Terminate/176449 it found the expansion "Planeshift" which is the first in "All Set" value and not the expansion "Alara Reborn", same for Meddling Mage/179547.

CU,
Björn

1 Attachments

Discussion

  • Bjoern Schmidt
    Bjoern Schmidt
    2014-08-11

    Please wait with this patch. I have to improve it. Sometimes there is an img tag and sometimes not. Terminate/176449 is now fixed in the gatherer but Meddling Mage/179547 is not fixed.

     
  • Make sure you featch and rebase before you submit the patch, I fixed lots of code in
    this file recently

     
  • Bjoern Schmidt
    Bjoern Schmidt
    2014-08-11

    Yes of course I did and will do whenever I start implementing or did you see that I do not? Then I have to check this.

     
  • I have not had a chance to look, just want to make sure you updating code
    regularly

     
  • Bjoern Schmidt
    Bjoern Schmidt
    2014-08-11

    OK, I think I have double checked it enough for now. If there appears an image in the "Expansion" line seams to depends on some browser settings. In my case I see an image for the german version of Terminate/196868 and not for other languages. Magic Assistant see only an image for the english version in my case.
    I attached a text file with the URLs and the HTML text that is checked for expansion. You can easly check it using this side and see what is going on with both expressions, the original one and my expression:
    http://www.regexplanet.com/advanced/java/index.html
    So, the patch is still OK and will fix a bug where updated cards are stored with wrong expansion. (Cards in test.txt will be stored in Planeshift and not in Alara Reborn)

     
    Attachments

  • Anonymous
    2014-08-11

    Yeah, lovely tests :) No, I noticed that there is ParserGathererOracleTest but do not found any for this case and don't added one. But wait a second ...

     
  • Bjoern Schmidt
    Bjoern Schmidt
    2014-08-11

    Forget to log in for the last post. Here they are.
    Let me no if something is missing or if your are not satisfied with them.
    Well testFlipCards failed for me due to missing file c:\tmp\99a.html with a FileNotFoundException. But I thinks it do not depends on my work.
    For today I go to bed. It is late on this side of the world.

     


Anonymous


Cancel   Add attachments