Empty Grid rows | Vaadin 24.1.7

Just upgraded to Vaadin 24.1.7 from 23.2.0, my other grids work fine, but one (more complex) grid shows rows with empty content (except the left multi-select component).

These are the relevant code sections for the grid:

Grid<FileDetails> grid = new Grid<>();
                List<FileDetails> items = currentDir.getDirectoryFiles();
                grid.setItems(items);

                grid.addComponentColumn(FileDetails::getIcon).setHeader("Icon").setFlexGrow(0);
                grid.addColumn(FileDetails::getName).setHeader("Name").setAutoWidth(true);
                grid.addColumn(FileDetails::getDisplaySize).setHeader("Size").setAutoWidth(true);
                grid.addColumn(FileDetails::getDateString).setHeader("Changed").setAutoWidth(true);

                grid.setSelectionMode(Grid.SelectionMode.MULTI);
                grid.recalculateColumnWidths();
                grid.addThemeVariants(GridVariant.LUMO_WRAP_CELL_CONTENT);
                grid.addThemeVariants(GridVariant.LUMO_ROW_STRIPES);

                GridContextMenu<FileDetails> menu = grid.addContextMenu();
                menu.setTarget(grid);
MenuItemBase create = menu.addItem("Create", (ComponentEventListener<GridContextMenu.GridContextMenuItemClickEvent<FileDetails>>) event -> {
                    createFile(currentDir);
                });
 MenuItemBase paste = menu.addItem("Paste",...
MenuItemBase cut = menu.addItem("Cut", ....
...
grid.addItemClickListener((ComponentEventListener<ItemClickEvent<FileDetails>>) event -> {...
grid.asMultiSelect().addSelectionListener((MultiSelectionListener<Grid<FileDetails>, FileDetails>) event -> {...
ui.pushBatched(() -> {
                    gridContainer.removeAll();
                    gridContainer.add(grid);
...

image.png

Try removing code and see if that makes a difference? For example, these:

                grid.recalculateColumnWidths();
                grid.addThemeVariants(GridVariant.LUMO_WRAP_CELL_CONTENT);

yeah I removed both theme variants and still got the issue

Keep removing stuff. Either you will find the part that breaks the code or you will have a minimal reproducible example for a bug report.

Found the root cause. I was creating the Grid in another thread than the UI thread, which odly worked in older versions.

Nice!