|
|
@ -516,7 +516,7 @@ class Parser (Process):
|
|
|
|
#
|
|
|
|
#
|
|
|
|
# Handling the last claim found
|
|
|
|
# Handling the last claim found
|
|
|
|
if segment[0].startswith(section) :
|
|
|
|
if segment[0].startswith(section) :
|
|
|
|
default_claim = dict({"name":index},**DEFAULT_VALUE)
|
|
|
|
# default_claim = dict({"name":index},**DEFAULT_VALUE)
|
|
|
|
|
|
|
|
|
|
|
|
claim = self.apply(segment,_code)
|
|
|
|
claim = self.apply(segment,_code)
|
|
|
|
if claim :
|
|
|
|
if claim :
|
|
|
@ -528,10 +528,10 @@ class Parser (Process):
|
|
|
|
else:
|
|
|
|
else:
|
|
|
|
schema = {}
|
|
|
|
schema = {}
|
|
|
|
merger = jsonmerge.Merger(schema)
|
|
|
|
merger = jsonmerge.Merger(schema)
|
|
|
|
top_row_claim = self.apply(_toprows,_code)
|
|
|
|
# top_row_claim = self.apply(_toprows,_code)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
# claim = merger.merge(claim,self.apply(_toprows,_code))
|
|
|
|
|
|
|
|
|
|
|
|
claim = merger.merge(claim,self.apply(_toprows,_code))
|
|
|
|
|
|
|
|
# claims.append(dict(DEFAULT_VALUE,**claim))
|
|
|
|
|
|
|
|
claims.append(merger.merge(DEFAULT_VALUE,claim))
|
|
|
|
claims.append(merger.merge(DEFAULT_VALUE,claim))
|
|
|
|
if type(file) != list :
|
|
|
|
if type(file) != list :
|
|
|
|
file.close()
|
|
|
|
file.close()
|
|
|
|