diff --git a/.github/CONTRIBUTING.md b/.github/CONTRIBUTING.md index b34f9a1c..17259cdf 100644 --- a/.github/CONTRIBUTING.md +++ b/.github/CONTRIBUTING.md @@ -1,19 +1,23 @@ # Contributing to Magic-Spoiler # -Thank you for your interest in contributing to Magic-Spoiler! +Thank you for your interest in contributing to Magic-Spoiler!
This project is an attempt to create a central source for new Magic: the Gathering spoilers and provide data files for miscellaneous projects like [Cockatrice](https://github.com/Cockatrice/Cockatrice). -## How can I help? ## -Magic-Spoiler grabs its data from many sources, but those sources often contain errors. If you just want to improve the card data and fix errors, you can start in the [errors.yml](https://github.com/Cockatrice/Magic-Spoiler/blob/files/errors.yml) file in the [files branch](https://github.com/Cockatrice/Magic-Spoiler/tree/files) or our [issue tracker](https://github.com/Cockatrice/Magic-Spoiler/issues). -Once you've found an error, whether it be in the errors.json file or from using the data files, make sure that error hasn't already been fixed in the appropriate file on the [files branch](https://github.com/Cockatrice/Magic-Spoiler/tree/files). If it's still present, let's get it fixed! -- If the error is with one of the fields in a card, check our [cards_corrections.yml](https://github.com/Cockatrice/Magic-Spoiler/blob/master/cards_corrections.yml) file. -- If the card shouldn't exist at all, check the [cards_delete.yml](https://github.com/Cockatrice/Magic-Spoiler/blob/master/cards_delete.yml) file.
-This file is just an array of cards to delete. `card name` is case sensitive! -- If the card is a legitimate spoiler and it isn't showing up yet, you can manually add it. The file you want is [cards_manual.yml](https://github.com/Cockatrice/Magic-Spoiler/blob/master/cards_manual.yml). Make sure you link the spoiler source in your Pull Request (PR). -All PRs for card fixes should have the name of the card being fixed and the type of fix (fix/correction, delete, or manual). In the details of the PR, you **MUST INCLUDE A VALID LINK** to the page the spoiler is located at. For minor fixes, a link to the card image is OK. And of course link the issue you're fixing if there is one! +## How can I help? ## +Magic-Spoiler grabs its data from [Scryfall](https://scryfall.com/), but there can be errors of course. +If you want to improve the card data and fix errors for all users, you simply have to report them directly to Scryfall. +Once you've found a mistake in our data files, make sure that error hasn't already been fixed at the Scryfall webpage in betweeen. If it's still present there, let's get it fixed! +- If the error is with one of the fields in a card (e.g. a spelling error or missing cmc) search for that card on the Scryfall webpage. Below the card art on the left, there are some links. Choose the botton one (`Report card issue`) and provide the information in the form. Once their team check & fixes the errors, it'll show up in our spoiler files, too.
+It only takes a few days - be patient. +- If the card is a legitimate spoiler and it isn't showing up yet, you can request it by [contacting the Scryfall support](https://scryfall.com/contact) and let them know. Make sure to link the official spoiler source in your report. +- If the card shouldn't exist at all, let the Scryfall team know as well, please. + +What you should **NOT** do however, is to submit PR's to our files branch and fix the xml/json files there directly.
+You have to provide updates to Scryfall as all other changes would get overridden again. + ## Anything else? ## -If you notice errors, please file an [issue](https://github.com/Cockatrice/Magic-Spoiler/issues) +If you notice any other errors or have suggestions to the code, please [file an issue](https://github.com/Cockatrice/Magic-Spoiler/issues) in our repository.
diff --git a/.travis.yml b/.travis.yml index 046f6a46..57204c6a 100644 --- a/.travis.yml +++ b/.travis.yml @@ -11,16 +11,12 @@ env: before_install: - export CFLAGS=-O0 # considerably speed-up build time for pip packages (especially lxml), optimizations doesn't matter for ci - - pip install pyyaml install: - pip install -r requirements.txt script: bash ./.ci/deploy.sh -after_script: - - sleep 10 # helps travis finish logging - ## Builds for pull requests skip the deployment step altogether #deploy: diff --git a/README.md b/README.md index 15d8a44e..0bda03ef 100644 --- a/README.md +++ b/README.md @@ -1,7 +1,8 @@ -[![](https://img.shields.io/badge/dynamic/xml.svg?label=Currently%20included%20sets&colorB=4ac41d&url=https%3A%2F%2Fraw.githubusercontent.com%2FCockatrice%2FMagic-Spoiler%2Ffiles%2Fspoiler.xml&query=%2F%2Flongname)](https://github.com/Cockatrice/Magic-Spoiler/blob/files/spoiler.xml) +[![](https://img.shields.io/badge/dynamic/xml.svg?label=Currently%20included%20sets&colorB=lightgrey&url=https%3A%2F%2Fraw.githubusercontent.com%2FCockatrice%2FMagic-Spoiler%2Ffiles%2Fspoiler.xml&query=%2F%2Flongname)](https://github.com/Cockatrice/Magic-Spoiler/blob/files/spoiler.xml) +
-# Magic-Spoiler [![Gitter Chat](https://img.shields.io/gitter/room/Cockatrice/Magic-Spoiler.svg)](https://gitter.im/Cockatrice/Magic-Spoiler) # +# Magic-Spoiler [![Gitter Chat](https://img.shields.io/gitter/room/Cockatrice/Magic-Spoiler.svg?colorB=blue)](https://gitter.im/Cockatrice/Magic-Spoiler) # Magic-Spoiler is a Python script to scrape [Scryfall](https://scryfall.com) to compile XML files (Cockatrice formatted) and application-ready json files (mtgjson formatted) with information about spoiled cards from upcoming sets. @@ -12,12 +13,12 @@ When run by Travis, the script automatically updates the files and uploads new v Travis CI is run daily on a cron job basis. ## Errors ## -Noticed an error? Check out our [Contributing file](https://github.com/Cockatrice/Magic-Spoiler/blob/master/.github/CONTRIBUTING.md) for information on how to help! +Noticed an error in the card data? Check out our [Contributing file](https://github.com/Cockatrice/Magic-Spoiler/blob/master/.github/CONTRIBUTING.md) for information on how to help! ## Running ## ### Requirements ### - * Python 2.7 + * Python 3.6 * several Python Modules (see [requirements.txt](https://github.com/Cockatrice/Magic-Spoiler/blob/master/requirements.txt)) ``` @@ -27,19 +28,16 @@ pip install -r requirements.txt ### Usage ### ``` -$> python main.py +$> python -m magic_spoiler ``` Outputs the following files to `out/` directory:
-`spoiler.xml`, `{SETCODE}.xml`, `MPS_{SETCODE}.xml`,
-`spoiler.json`, `{SETCODE}.json`, `MPS_{SETCODE}.json` +`spoiler.xml`, `spoiler.json`
+`{SET_CODE}.xml`, `{SET_CODE}.json` > **spoiler** → files contain all currently available spoilers from different sets
> **{SETCODE}** → files contain just the spoiler available for this single set
-> **MPS_{SETCODE}** → files contain just the spoiler available for this [Masterpiece Series](http://magic.wizards.com/en/articles/archive/making-magic/masterpiece-series-2016-09-12) - -Errors are logged there as well (`errors.yml`)
-**Enable "Spoilers" in `Cockatrice → Settings → Deck Editor` to get updates automatically pushed to your client!**
-You can also [add the desired .xml file to your customsets folder manually](https://github.com/Cockatrice/Cockatrice/wiki/Custom-Cards-&-Sets#to-add-custom-sets-follow-these-steps) to make Cockatrice use it. +**Enable "Download Spoilers Automatically" in `Cockatrice → Settings → Card Sources → Spoilers` to get updates automatically pushed to your client!**
+You can also [add the desired .xml file(s) to your customsets folder manually](https://github.com/Cockatrice/Cockatrice/wiki/Custom-Cards-&-Sets#to-add-custom-sets-follow-these-steps) to make Cockatrice use it.