Dash AG Grid - when bulking editing large amount of cells, it takes quite long time (>40s even longer). Is my setting not right?

Hi all,

I found when i am doing bulking updating/editing(>2K cells) ag grid when making the grid editable, it takes very long time and freezes. Here is my defination of the ag grid. Please help out and really appreciate it !

dag.AgGrid(
id=“demo_tb”,
dashGridOptions={
“animateRows”: False,
“animateColumns”: False,
“alwaysShowHorizontalScroll”: True,
“undoRedoCellEditing”: True,
“undoRedoCellEditingLimit”: 20,
“enableRangeSelection”: True,
“rowGroupPanelShow”: “always”,
“suppressScrollOnNewData”: True,
“sideBar”: {
“toolPanels”: [
{
“id”: “columns”,
“labelDefault”: “Pivot”,
“labelKey”: “columns”,
“iconKey”: “columns”,
“toolPanel”: “agColumnsToolPanel”,
},
{
“id”: “filters”,
“labelDefault”: “Filters”,
“labelKey”: “filters”,
“iconKey”: “filter”,
“toolPanel”: “agFiltersToolPanel”,
},
],
“position”: “right”,
“defaultToolPanel”: “filters”,
},
},
columnSize=“sizeToFit”,
columnDefs=COLUMNS, # A list of columns definations
defaultColDef={
“resizable”: True,
“sortable”: True,
“filter”: True,
“useValueFormatterForExport”: True,
},

COLUMN DEF sample:

{
“field”: demo_col,
“id”:demo_col,
“filter”: “agNumberColumnFilter”,
“cellStyle”: {“font-weight”: “600”, “color”: “orange”},
“columnGroupShow”: “open”,
“valueFormatter”: {“function”: “params.value && d3.format(‘,.1f’)(params.value)”},
“editable”: True,
“enableRowGroup”: True,
“enableValue”: True,
“enablePivot”: True,
“type”: “rightAligned”,
# “minWidth”: 90,
},

Hi @littlefishna

It’s hard to tell based on what you posted, but you can check out these AG Grid sections on performance:

This section on Row Transactions, which is the fasted way to update data

Thank you all. I found the reason. It is due to the “cellValueChanged” used in callbacks