From 462ebdb022acfbdaa22309aa154465f25124190d Mon Sep 17 00:00:00 2001 From: Johann Tuffe Date: Tue, 9 Jul 2024 01:06:05 +0800 Subject: [PATCH] add warning and return an empty range if not a worksheet --- src/xlsx/cells_reader.rs | 15 +++++++++++++-- src/xlsx/mod.rs | 21 +++++++++++++++++++-- tests/issue438.xlsx | Bin 0 -> 15362 bytes tests/test.rs | 8 ++++++++ 4 files changed, 40 insertions(+), 4 deletions(-) create mode 100644 tests/issue438.xlsx diff --git a/src/xlsx/cells_reader.rs b/src/xlsx/cells_reader.rs index 3404d74..53d80a0 100644 --- a/src/xlsx/cells_reader.rs +++ b/src/xlsx/cells_reader.rs @@ -39,6 +39,7 @@ impl<'a> XlsxCellReader<'a> { ) -> Result { let mut buf = Vec::with_capacity(1024); let mut dimensions = Dimensions::default(); + let mut sh_type = None; 'xml: loop { buf.clear(); match xml.read_event_into(&mut buf).map_err(XlsxError::Xml)? { @@ -57,9 +58,19 @@ impl<'a> XlsxCellReader<'a> { return Err(XlsxError::UnexpectedNode("dimension")); } b"sheetData" => break, - _ => (), + typ => { + if sh_type.is_none() { + sh_type = Some(xml.decoder().decode(typ)?.to_string()); + } + } }, - Event::Eof => return Err(XlsxError::XmlEof("sheetData")), + Event::Eof => { + if let Some(typ) = sh_type { + return Err(XlsxError::NotAWorksheet(typ)); + } else { + return Err(XlsxError::XmlEof("worksheet")); + } + } _ => (), } } diff --git a/src/xlsx/mod.rs b/src/xlsx/mod.rs index de42bff..3ee796b 100644 --- a/src/xlsx/mod.rs +++ b/src/xlsx/mod.rs @@ -87,6 +87,8 @@ pub enum XlsxError { WorksheetNotFound(String), /// Table not found TableNotFound(String), + /// The specified sheet is not a worksheet + NotAWorksheet(String), } from_err!(std::io::Error, XlsxError, Io); @@ -136,6 +138,7 @@ impl std::fmt::Display for XlsxError { XlsxError::WorksheetNotFound(n) => write!(f, "Worksheet '{n}' not found"), XlsxError::Password => write!(f, "Workbook is password protected"), XlsxError::TableNotFound(n) => write!(f, "Table '{n}' not found"), + XlsxError::NotAWorksheet(typ) => write!(f, "Expecting a worksheet, got {typ}"), } } } @@ -854,7 +857,14 @@ impl Xlsx { &'a mut self, name: &str, ) -> Result>, XlsxError> { - let mut cell_reader = self.worksheet_cells_reader(name)?; + let mut cell_reader = match self.worksheet_cells_reader(name) { + Ok(reader) => reader, + Err(XlsxError::NotAWorksheet(typ)) => { + log::warn!("'{typ}' not a valid worksheet"); + return Ok(Range::default()); + } + Err(e) => return Err(e), + }; let len = cell_reader.dimensions().len(); let mut cells = Vec::new(); if len < 100_000 { @@ -928,7 +938,14 @@ impl Reader for Xlsx { } fn worksheet_formula(&mut self, name: &str) -> Result, XlsxError> { - let mut cell_reader = self.worksheet_cells_reader(name)?; + let mut cell_reader = match self.worksheet_cells_reader(name) { + Ok(reader) => reader, + Err(XlsxError::NotAWorksheet(typ)) => { + warn!("'{typ}' not a worksheet"); + return Ok(Range::default()); + } + Err(e) => return Err(e), + }; let len = cell_reader.dimensions().len(); let mut cells = Vec::new(); if len < 100_000 { diff --git a/tests/issue438.xlsx b/tests/issue438.xlsx new file mode 100644 index 0000000000000000000000000000000000000000..7074395de6c8124cb4b0b107ac45d8d441357d50 GIT binary patch literal 15362 zcmeHu1y@{Ivo;!nH}1jRB@lvZaCd@3aCdiy;4Z=4-QC?a1b0nv|2mVolX;oB-ygVd zuSIvW&Z(zQol~`|o~qh1;@}XdAg@4PgMfe#g3Mql=N5v3fG9(OfS`c922&TXw6HU< zu+vg-wlc8QpmQ=eBgldPqsRaO1D^li*Z<)=P!l&O)y)71I2CCT*rFEuYQy{b?RJNa zpI9su!&Oc2f#e%US64DA*w=A+6E?xsPEV)T`kZgRmW7R>11cQq^dGbOnJT6Vm!!n6 z-g}Ics|Lubkk(YoRJ|o=#!LSK-)D-LC|lDTt;l$XGbXE~4S_!9n@f*^5f*fTnfDcz z9YuaEq4gVD!kBOcV?_8X9E1}cqMi4j5UE{O-a}_Z88{yI1Sm4Cx0dAwZN<`;+zAh| z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p|~ocNeSk-ou} z2%FoA#{0l#iRU0K&e^4=p^0%$m0f3Euo2ep*z)|!?{=(%LV6?zy)4y+Y`~8T2efyVfZ!+Tl3Gko$X#Nhc0Sphn^0Pm( zvX_D{cN6>;MFY-r{W)U#KYI&a3jgOw^KVfQkWrXFgn#|;KL(s%;=G(}{f&eGY%>3O z5&xJAe2MaMpzt@!3b1(fSGM|cT=pf*%UQPHFoj5ez`UGndkOHeNB$ci8aU?&ypG=; z^OvG8Tamv-KjHooec70NiSV-b_Zxu??+=8(_{!gz%1e}&U7+76w!qB)uUq-Ip3qB# zmzBZa2$`gRNBCVQe2MUqn*T=7rTRO9-fyD*65=IW{S6Tf^u)i^`2TR%mxwP3;BUkz znm-W#y1oAk9efG+l2rW${7n0|OZ;=Izzd4?66`-I$!{nSkTg0Fkbe-Am*W4KQT|;V ukMVEff997jrT;T>|6Tf=`ESyCf5mYbaY$fd`!md=fItGn{Vwaz|NbAP{!5ks literal 0 HcmV?d00001 diff --git a/tests/test.rs b/tests/test.rs index 5cd8404..28c15f6 100644 --- a/tests/test.rs +++ b/tests/test.rs @@ -1691,6 +1691,14 @@ fn issue_420_empty_s_attribute() { ); } +#[test] +fn issue_438_charts() { + let mut excel: Xlsx<_> = wb("issue438.xlsx"); + let _range = excel + .worksheet_range("Chart1") + .expect("could not open worksheet range"); +} + #[test] fn isssue_446_formulas() { let mut excel: Xlsx<_> = wb("issue446.xlsx");