You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm trying quick-xml and i found a strnage behavior on my xml file (a sample attached). When i parse event Begin on tag SECURITY i get only two first attributes. But on tag RECORDS i get all attributes successfully.
My code like
Ok(Event::Start(ref e)) => {ifletb"SECURITY" = e.name(){// cycle through attrsfor el in e.attributes(){let e = el?;print!("{}, ", std::str::from_utf8(e.key)?);}println!();};[1.xml.gz](https://github.com/tafia/quick-xml/files/6868035/1.xml.gz)
Activity
tafia commentedon Aug 10, 2021
I can't get your file, are you still having some issue?
swi2012 commentedon Aug 10, 2021
Hello. Yes issue is still here.
Here is file content
tafia commentedon Aug 11, 2021
I haven't tried but your encoding is windows-1251 not utf8, could you try using unescape_and_decode ?
swi2012 commentedon Aug 11, 2021
I use feature 'encoding'. Even so with utf8 file it the same:
output:
read file 1.xml reader opened some SECURITY: SecurityId, ISIN, RECORDS: RecNo,TradeNo,TradeDate,TradeTime,BuySell,SettleCode,Decimals,Price,Quantity,Value,AccInt,Amount,Balance,TrdAccId,ClientDetails,CPFirmId,CPFirmShortName,Price2,RepoPart,ReportTime,SettleTime,ClientCode,DueDate,EarlySettleStatus,RepoRate,RateType,tafia commentedon Aug 14, 2021
Hi,
I've tried this test and it seems to work as expected. Closing for now, feel free to reopen and provide more information.
(I'll add it to the tests).
Move regression tests for tafia#94 and tafia#299 to issues.rs