You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@poi.apache.org by bu...@apache.org on 2020/04/09 14:19:03 UTC

[Bug 64327] New: SXSSFSheet returns true in isColumnTrackedForAutoSizing if you track all columns and then untrack one

https://bz.apache.org/bugzilla/show_bug.cgi?id=64327

            Bug ID: 64327
           Summary: SXSSFSheet returns true in
                    isColumnTrackedForAutoSizing if you track all columns
                    and then untrack one
           Product: POI
           Version: 4.1.2-FINAL
          Hardware: PC
                OS: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: SXSSF
          Assignee: dev@poi.apache.org
          Reporter: kortovea@gmail.com
  Target Milestone: ---

Method isColumnTrackedForAutoSizing in SXSSFSheet
https://github.com/apache/poi/blob/84ba670e27948adcb572caa5065affbf1aa3a769/src/ooxml/java/org/apache/poi/xssf/streaming/SXSSFSheet.java#L1502-L1505

returns true for untracked column if you invoked trackAllColumnsForAutoSizing()

steps:
1. Create workbook, SXSSFSheet, and row with 2 cells
2. invoke trackAllColumnsForAutoSizing() on the sheet
3. invoke untrackColumnForAutoSizing(0) on the sheet
4. invoke isColumnTrackedForAutoSizing(0) on the sheet

expected result: false
actual result: true

it's because `AutoSizeColumnTracker` checks `trackAllColumns` first

https://github.com/apache/poi/blob/84ba670e27948adcb572caa5065affbf1aa3a769/src/ooxml/java/org/apache/poi/xssf/streaming/AutoSizeColumnTracker.java#L140-L142

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org


[Bug 64327] SXSSFSheet returns true in isColumnTrackedForAutoSizing if you track all columns and then untrack one

Posted by bu...@apache.org.
https://bz.apache.org/bugzilla/show_bug.cgi?id=64327

PJ Fanning <fa...@yahoo.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
         Resolution|---                         |FIXED

--- Comment #1 from PJ Fanning <fa...@yahoo.com> ---
Thanks - applied using https://svn.apache.org/repos/asf/poi/trunk@1876336

-- 
You are receiving this mail because:
You are the assignee for the bug.
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@poi.apache.org
For additional commands, e-mail: dev-help@poi.apache.org