Closed 2ndDerivative closed 1 year ago
Okay fixed it. Accidently added the wrong commit to the PR. Sorry for that. We can squash all of these later
Thanks for the effort but It isn't how I'd want to handle it so I will pass on this.
For future reference keep an eye on failing tests (they are detailed in the Github Actions) and keep the commit history flat and clean.
XlsxError::SheetnameReserved => {
write!(
f,
"\"History\" is a reserved worksheet name"
)
}
"History" is a reserved name but not in all language versions of Excel. I had a similar check and exception in the Python version of the library and had to remove it because it is allowed in the Russian version of Excel. See this bug report: https://github.com/jmcnamara/XlsxWriter/issues/688
yeah I was wondering about the tests. The cargo formatter didn't work on this project because of a file name length or something?
Regarding issue #45
I added a struct
Name
in the worksheet module. it's a string wrapper that includes all the logic inset_name
, andset_name
was pointed to this struct. I took care to not change and public interface so far, and as the field "name" was crate-public, I changed it to anOption<Name>
so the validation could stay guaranteed. So far this setup passes all the tests, and any tests concering set_name were kept, so this should work as before.