Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow handling empty string value in xls formula parsing #348

Closed
wants to merge 4 commits into from

Conversation

7Towers
Copy link

@7Towers 7Towers commented Aug 21, 2023

#343
Simple fix to handle empty string values when parsing XLS formulas. Based on MS recommendations. Fixes the issue I've faced in my projects.

@dimastbk
Copy link
Contributor

Test file - issue_343.xls (put ="" in A1).

@tafia
Copy link
Owner

tafia commented Aug 22, 2023

Yes please add a test. Thanks!

@dimastbk
Copy link
Contributor

I think, 0x03 should return DataType::String("".to_string()), because empty cell != zero-lenght string cell. See for example xlrd and sheetjs.

@jqnatividad
Copy link
Contributor

Hope you don't mind @7Towers , but I went ahead and implemented an alternate PR using @dimastbk 's recommendation to return an empty string, using the test file he provided.

Hopefully, when this gets merged, the next calamine release will be published by @tafia 😉 🤞

@7Towers
Copy link
Author

7Towers commented Aug 23, 2023

Great job @jqnatividad. Your PR is better for the project.

@7Towers 7Towers closed this Aug 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants