Closed lupoDharkael closed 1 year ago
@tari101190 is the card text updating process a parsed output from https://digimoncardgame.fandom.com ? I'd love to contribute to fixing this but I don't know if the fixes should be handled in the wiki and backported here or how is this usually managed.
The updates need to be made manually so Ideally if possible could you correct them on both the wiki and the github separately? Unfortunately I don't think there's a way to automatically both at once.
I already have an script that parses the wiki fields in order to find errors, I could modify it to scrap the contents and format a json directly from the web so we only need to change the contents in one place.
Okay wow that's great. Honestly I'm not too knowledgeable in this field, but yeah if you have a way to find errors both here and on the wiki and can fix both at once then yeah go for it. Thanks.
That would be nice, I have a script in GetDataFromWiki.py which gets the images and makes a json, but some formatting is lost and it has a problem with Illustrators atm. :)
Cool, I'll check it up. My script also used BeautifulSoup intially but I changed it to use wiketextparser instead as it is way easier to get the contents, and parsing wikitext is less error prone due to frontend changes. I'm changing the tittle of the issue so it fits the actual discussion.
I improved the script quite a bit https://github.com/TakaOtaku/Digimon-Card-App/blob/main/scripts/python/Wiki%20Script/GetDataFromWiki.py. Some things are still missing:
But it is looking pretty good so far :)
The script now gets every card, and card images :)
All the BT14 D-Brigade effects that play cards with the Digipolice/D-Brigade trait show they play "Digimon" and it should specify "card" instead.