Skip to content

Conversation

@xjlin0
Copy link

@xjlin0 xjlin0 commented Apr 23, 2020

When copying the sheet in the memory, if the row is null, currently it will cause NPE. So just a null checker to protect it, similar to how it skips null columns as of now. @zmau

2020-04-23 09:49:07.390 [,myservice,,] ERROR https-jsse-nio-9420-exec-2 [dispatcherServlet] - Servlet.service() for servlet [dispatcherServlet] in context with path [] threw exception [Request processing failed; nested exception is java.lang.NullPointerException] with root cause
java.lang.NullPointerException: null
        at org.apache.poi.ss.usermodel.RangeCopier.copyRange(RangeCopier.java:89)
        at org.apache.poi.ss.usermodel.RangeCopier.copyRange(RangeCopier.java:68)

@pjfanning
Copy link
Member

Would you be able to provide a test xlsx file and a test case that reproduces the issue? We like to have regression tests.

@asfgit asfgit closed this in 979d1b4 Apr 26, 2020
@centic9
Copy link
Member

centic9 commented Apr 26, 2020

Sorry, I was too fast, I could quickly reproduce it and fix it as part of some other improvement to the tests.

@xjlin0
Copy link
Author

xjlin0 commented Apr 27, 2020

it's ok, as long as the null row can now be skipped and will be release in the next version, I will be happy.

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.

3 participants