Skip to content
This repository has been archived by the owner on Dec 21, 2018. It is now read-only.

Adding In "Number" to AllSets.json #36

Closed
ZeldaZach opened this issue Jun 15, 2015 · 4 comments
Closed

Adding In "Number" to AllSets.json #36

ZeldaZach opened this issue Jun 15, 2015 · 4 comments

Comments

@ZeldaZach
Copy link
Member

I see how and why you don't include the number field in the AllSets, but maybe it could be possible to include it.

Seeing as how the arrays printingCodes and printings are in the same order, is it possible to add a number array that follows the same format, holding the same object type as originally designated in the docs? In this case, the values in number are Strings, as they would be in the single set files.

Fictitious Example:

Variable Value
printingCodes [ "ICE", "CHR" ]
printings [ "Ice Age", "Chronicles" ]
number ["3", "185"]

If the array idea above could work, then it could also potentially be applied to the other missing fields: artist, border, flavor, multiverseid, originalText, originalType, rarity, releaseDate, reserved, timeshifted, variations, and watermark

I'd really like to hear your opinion on this ⛵

@Sembiance
Copy link
Contributor

Well, the printingCodes and printings fields specifically help you find other printings in other sets. They don't convey information about those cards in those sets, just give you the info to go find that info in the appropriate set.

While I could add the information you mention as arrays to cards, it would be a lot of duplication of data and would only be a 'convenience' factor. I try and not include additional data fields for convenience purposes as much as I can help it. In fact I wouldn't even have both 'printings' and 'printingCodes' if I could do things over again, I would just have 'printings' but have it be codes rather than set names. But I didn't do it that way from the beginning and wanted to maintain backwards compatibility.

I feel like in situations like this, where you would like to see the data formatted a certain way, you could just run the JSON files you download through a 'preprocessing' script that changes them into the format you are looking for before consuming them.

Hope this all makes sense.

@ZeldaZach
Copy link
Member Author

I understand what you're saying completely, but the way the code is currently written it seems as if you could theoretically use the printings array as a "guide" to the number field. I do agree that it is really a convenience factor, but the way Oracle works we can only get one file at a time currently, and it wouldn't make much sense to have people download each and every file from your site.

This is for Cockatrice, and users probably don't want to be downloading tons of files when they could just download one (AllSets.json), if possible. I've recently been working on a feature for people to auto-link cards to any location they choose, and having the card number from the specific set I feel is an important addition.

I'd appreciate it if you'd potentially add this convenience array into your product, but it is your choice and I respect any decision you choose to make.

@Sembiance
Copy link
Contributor

I've decided that this is something the consumers of the data can take care of on their side. They have all the data in their hands.

@ZeldaZach
Copy link
Member Author

Fair enough, thanks for your response

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants