Open mike-w-kelly opened 7 years ago
~Have you tried to set a DocumentPath on the schema object?~
Sorry, it looks more like a bug...
I just tried this again with the latest version. It seems that the JSON Schema is invalid:
... the "properties" must be an object/dictionary with string/schema objects but there is a property "additionalProperties" with a Boolean...
I have an even simpler example: just take the generated JSON schema from the main README.md file here in this repo, and run it through the CSharpGenerator. The output is only the Person class, and none of the other classes or enums. I have red squiggles for all the other classes, and the generated List property is of type List<Anonymous>
!
Scratch that, I can only reproduce this issue in VS for Mac. When I switched to Windows, everything was fine...
I'm trying to generate POCO's from the following JSON 4 schema, which has references to a number of other files.
http://docs.oasis-open.org/ubl/UBL-2.1-JSON/v1.0/cnprd01/json-schema/maindoc/UBL-Invoice-2.1.json
Here is my very basic code.
I'm getting the following error
{"Could not resolve the JSON path '../common/UBL-CommonExtensionComponents-2.1.json#/definitions/UBLExtensions' with the full JSON path 'http://docs.oasis-open.org/ubl/UBL-2.1-JSON/v1.0/cnprd01/json-schema/common/UBL-CommonExtensionComponents-2.1.json#/definitions/UBLExtensions'."}
The generator seems to have issue with the following $ref code, of which there are many ocurrences
Any ideas how I resolve it?