Array index [0] out of range, array size is [1] - TablePrinter.cfc: line 158

Description

After box 5.3 eventually started, I called outdated --system and got an error message.

{{Welcome to CommandBox!
CommandBox> outdated --system
Resolving Dependencies, please wait...

ERROR (5.3.0+00349)

Array index [0] out of range, array size is [1]

\system\util\TablePrinter.cfc: line 158
156: // Finalize median calculation
157: colData.medianWidth = colData.medianWidth.sort( (a,b)=>a>b );
158: colData.medianWidth = max( colData.medianWidth[ int( colData.medianWidth.len() / 2 ) ], 0 );
159: // This ratio represents how 'squishable' a column is as a function of the amount of whitespae and it's overall length
160: colData.medianRatio = max( ( (colData.maxWidth-colData.medianWidth)*data.len() ), 1 )*colData.maxWidth;
called from \system\util\TablePrinter.cfc: line 78
called from \system\util\TablePrinter.cfc: line 61
called from \system\wirebox\system\ioc\Provider.cfc: line 101
called from \system\util\Print.cfc: line 296
called from \system\util\PrintBuffer.cfc: line 76
called from \system\modules_app\package-commands\commands\package\outdated.cfc: line 70
called from \system\services\CommandService.cfc: line 345
called from \system\services\CommandService.cfc: line 139
called from \system\Shell.cfc: line 787
called from \system\Shell.cfc: line 607
called from \system\Bootstrap.cfm: line 154

To enable full stack trace, run config set verboseErrors=true}}

Activity

Show:
Brad Wood
May 4, 2021, 3:50 AM

This is error is because you have no dependencies and the new table printer class doesn’t work on an empty table. This has already been fixed on the bleeding edge as part of ticket

Duplicate
Your pinned fields
Click on the next to a field label to start pinning.

Assignee

Unassigned

Reporter

Bernhard Döbler