This looks like a key-value mapping, with ISIN a key and "INE134E01011" a value. But it is not JSON, because the keys are not quoted, nor is it YAML because the plain scalar keys (i.e. strings without quotes have to be be followed by colon + space (: ).
If you break the output string in parts ¹:
test_str = (
'{ISIN:"INE134E01011",Ind:"-",'
'Audited:"Un-Audited",'
'Cumulative:"Non-cumulative",'
'Consolidated:"Non-Consolidated",'
'FilingDate:"14-Aug-2015 15:39",'
'SeqNumber:"1001577"},'
'{ISIN:"INE134E01011",' # new mapping starts
'Ind:"-",'
'Audited:"Un-Audited",'
'Cumulative:"Non-cumulative",'
'Consolidated:"Non-Consolidated",'
'FilingDate:"30-May-2015 14:37",'
'SeqNumber:"129901"},'
'{ISIN:"INE134E01011",' # new mapping starts
'Ind:"-",'
'Audited:"Un-Audited",'
'Cumulative:"Non-cumulative",'
'Consolidated:"Non-Consolidated",'
'FilingDate:"17-Feb-2015 14:57",'
'SeqNumber:"126171"}]}'
)
it test equal to your input:
test_org = '{ISIN:"INE134E01011",Ind:"-",Audited:"Un-Audited",Cumulative:"Non-cumulative",Consolidated:"Non-Consolidated",FilingDate:"14-Aug-2015 15:39",SeqNumber:"1001577"},{ISIN:"INE134E01011",Ind:"-",Audited:"Un-Audited",Cumulative:"Non-cumulative",Consolidated:"Non-Consolidated",FilingDate:"30-May-2015 14:37",SeqNumber:"129901"},{ISIN:"INE134E01011",Ind:"-",Audited:"Un-Audited",Cumulative:"Non-cumulative",Consolidated:"Non-Consolidated",FilingDate:"17-Feb-2015 14:57",SeqNumber:"126171"}]}'
assert test_str == test_org
That split up makes it clear there are actually 3 mappings and that there is a trailing ] and }. The ] indicates that there is a list, which is consistent with having the 3 mappings seperated by comma. The matching [ went missing because you after you split on ':[', you lstrip() it away.
You can easily manipulate the string so YAML can parse it, but the result is a list ²:
import ruamel.yaml
test_str = '[' + test_str.replace(':"', ': "').rstrip('}')
data = ruamel.yaml.load(test_str)
print(type(data))
prints:
<class 'list'>
And since the dicts of which this list consists have keys in common you cannot just combine those without losing information.
You can either map this list to some key (that there is a colon in your split and the output has a trailing } is indication that is in the XML) or you can take a key with unique values (SeqNumber) and promote the value to a key in a dict replacing the list:
ddata = {}
for elem in data:
k = elem.pop('SeqNumber')
ddata[k] = elem
but I don't see a reason to go from a list to a dict if your final goal is a CSV file. If you take the output from the YAML parser you can do:
import csv
with open('output.csv', 'w', newline='') as fp:
csvwriter = csv.writer(fp)
csvwriter.writerow(data[0].keys()) # header of common dict keys
for elem in data:
csvwriter.writerow(elem.values()) # values
to get a CSV file with the following content:
ISIN,Ind,Consolidated,Cumulative,Audited,FilingDate
INE134E01011,-,Non-Consolidated,Non-cumulative,Un-Audited,14-Aug-2015 15:39
INE134E01011,-,Non-Consolidated,Non-cumulative,Un-Audited,30-May-2015 14:37
INE134E01011,-,Non-Consolidated,Non-cumulative,Un-Audited,17-Feb-2015 14:57
¹ Instead of escaping the newlines with \, I use parenthesis to make the multi line definition into one string, that allows me to put comment on the lines more easily
² instead of re-adding the '[', you should of course not strip it in the first place
parseddatalook like??