Closed Quicksav closed 4 years ago
@Quicksav thanks for the bug report. There might be an issue with the json-schema. It might be enough to simply rebuild the schema (src/components/pages/Expeditions/CreationDialog/ConfigImport/expeditionJsonSchema.ts)
I am not quite sure I understand your proposed solution. What do you mean by
the validation message just needs to be removed ?
Edit: Just had a quick glance over the schema. It indeed looks like Any
is missing from the cardtype
To fix this, changing the following should work:
From
CardType: {
enum: ['EMPTY', 'Gem', 'Relic', 'Spell'],
type: 'string',
},
to this
CardType: {
enum: ['EMPTY', 'Gem', 'Relic', 'Spell', 'ANY'],
type: 'string',
},
That was what I had meant, just explained it rather poorly. The schema was causing the validation error to be thrown, fixing the schema = removing the validation error (sorta). The above fix is exactly the one I used to get it working locally.
If possible I'd like to try to create a pull request for this. I know its a simple issue that you could fix locally very easily but I'm trying to get used to working with Git still. From what I understand I want to create a local branch for the bug, then push it to the remote, then create a pull request for the branch I created into dev. Is that understanding correct?
Awesome :)
Regarding the pull request:
dev
branch@Quicksav FYI: I just recently merged another feature which causes an additional error. However to actually properly fix this, I need to update our aer-types package and re-create the whole schema. It wouldn't make sense to fix this bug twice. Therefore it would probably be better if you'd just tackle one of your other proposed issues :/ Sorry for the inconvenience!
If you need any help just reach out to me :) :+1:
Closing this, because I fixed the issue with #369
Describe the bug When importing an expedition, if the expedition has a supply tile with the type 'ANY' the importer throws an error. The code to handle the 'ANY' case is already in place, the validation message just needs to be removed so that the import can succeed.
Screenshots