gazpachoking/jsonref

For Large Complex Schema Loads fails to return valid object

Closed this issue · 1 comments

Bug.zip

When an attempt is made to run jsonref on a simple schema, there is success.

However, a more complext scheam (>1500 lines) it returns a dict, not a jsonref object on load.

On print an execption is thrown.

The sample has both simple and complex case

Sample output

Loaded complex schema
data1 <class 'dict'>
data2 <class 'jsonref.JsonRef'>
 data1: {'real': [1, 2, 3, 4], 'ref': [1, 2, 3, 4]}
Traceback (most recent call last):
  File "/var/data/smontsaroff/wrk/boatnet-importer/venv/lib64/python3.6/site-packages/proxytypes.py", line 252, in __subject__
    return self.cache
  File "/var/data/smontsaroff/wrk/boatnet-importer/venv/lib64/python3.6/site-packages/proxytypes.py", line 176, in __getattribute__
    return _oga(self, attr)
AttributeError: 'JsonRef' object has no attribute 'cache'

AttributeError: 'JsonRef' object has no attribute 'cache' This error was coming up when there was actually a different error caused by a reference failing to resolve. The newer versions should no longer contain that error, and give more details on what is actually failing.