Screen unusable if column to collapse is out of users permission

After migrating a production project from Jmix 1.4.4 to 1.5.5 a browse screen containing columns being collapsed by default (descriptor) is unusable.

I found out, that column collapse behavior changed being moved to a post init task.

if (StringUtils.isNotEmpty(collapsed)) {
            //There is a check in Vaadin Table component if the column to collapse is related to
            //container property or is generated one (exception will be thrown if neither one nor other condition met).
            //If the column being created is generated one then it will not be related to some container property
            //and will be added to Table component as generated only after full table initialization (including
            //injection of generator methods in a view marked with @Install).
            //So we defer setting of collapsed property until the initialization is completed.
            getComponentContext().addPostInitTask((context, window) ->
                    column.setCollapsed(Boolean.parseBoolean(collapsed)));
        }

If the user does not have the permission to view a column/property to be collapsed, screen loading fails completely. This is a major issue for migrating any application to Jmix 1.5.5.

Caused by: java.lang.IllegalArgumentException: Property 'createdDate' was not found in the container
        at com.vaadin.v7.ui.Table.setColumnCollapsed(Table.java:1381) ~[vaadin-compatibility-server-8.14.3-4-jmix.jar!/:8.14.3-4-jmix]
        at io.jmix.ui.component.impl.AbstractTable$ColumnImpl.setCollapsed(AbstractTable.java:2016) ~[jmix-ui-1.5.5.jar!/:na]
        at io.jmix.ui.xml.layout.loader.AbstractTableLoader.lambda$loadColumn$0(AbstractTableLoader.java:457) ~[jmix-ui-1.5.5.jar!/:na]
        at io.jmix.ui.xml.layout.loader.ComponentLoaderContext.executePostInitTasks(ComponentLoaderContext.java:141) ~[jmix-ui-1.5.5.jar!/:na]
        at io.jmix.ui.sys.ScreensImpl.createScreen(ScreensImpl.java:228) ~[jmix-ui-1.5.5.jar!/:na]
        at io.jmix.ui.sys.ScreensImpl.create(ScreensImpl.java:145) ~[jmix-ui-1.5.5.jar!/:na]
        at io.jmix.ui.menu.MenuItemCommands$ScreenCommand.createScreen(MenuItemCommands.java:230) ~[jmix-ui-1.5.5.jar!/:na]
        at io.jmix.ui.menu.MenuItemCommands$ScreenCommand.run(MenuItemCommands.java:169) ~[jmix-ui-1.5.5.jar!/:na]
        at io.jmix.ui.menu.SideMenuBuilder$MenuCommandExecutor.accept(SideMenuBuilder.java:272) ~[jmix-ui-1.5.5.jar!/:na]
        at io.jmix.ui.menu.SideMenuBuilder$MenuCommandExecutor.accept(SideMenuBuilder.java:257) ~[jmix-ui-1.5.5.jar!/:na]
        at io.jmix.ui.component.mainwindow.impl.SideMenuImpl$MenuItemImpl.menuSelected(SideMenuImpl.java:587) ~[jmix-ui-1.5.5.jar!/:na]
        at io.jmix.ui.widget.JmixSideMenu$1.menuItemTriggered(JmixSideMenu.java:91) ~[jmix-ui-1.5.5.jar!/:na]
        ... 103 common frames omitted

Hi,

Thank you for reporting the problem, I’ve created a GitHub issue.

Gleb

1 Like

@gorelov Thank you for creating the issue.

  • Approximattly when might we expect a fix for this? I mean, is it a matter of days, weeks or months?
  • Will there be a 1.5.6 release or is that fix planned for a 1.6.x release in the future only?

If there will be no 1.5.x fix, this might become more challenging because…

  • we have to wait for 1.6.0 and
  • develop, perform and test a direct migration from 1.4.4 to 1.6.0 (including all new yet unknown issues with 1.6.x)
  • still maintain or application with 1.4.4 for ongoing development

Hi,

The issue is planned for the Jmix 1.6 release. Jmix 1.6 is planned for May.

Regards,
Gleb

@gorelov Thank you for your quick answer.

I was afraid, that waiting for 1.6 would be the only offered solution.

I thought any latest 1.x version is always in long term support, so at the moment 1.5.5 - which was the only reason for our migration attempt from 1.4.4: having a latest LTS version running.

As for now, it appears to more stable and reliable to stay on 1.4.4 and continue application development on an old release.

Refactoring dozens of screen descriptors in applications and add-ons as well plus testing it’s impact on business functionality means way too much effort.

We will consider fixing this issue in Jmix 1.5 too.

When migrating to Jmix 1.6 you won’t need to refactor your screens.

Gleb

1 Like

Thank you very much!

@gorelov What I meant with ‘refactoring’ is that, if there will be no (fix in) Jmix 1.5.6 I would have to remove all collapse-attributes in screens (up to 80 in one of our applications), and check the impact on users having the permission and now getting data displayed which they are not used to and then decide whether to remove the attribute completely from the screen descriptor. This is not a technical issue but an issue of communicating with the customer - it is effort - and I would have had to explain.

@gorelov Are there any news on that bug after 6 weeks?

I can neither find a released version 1.6 nor a 1.5.6.

I start running out of excuses to the customer for not being able to release development on running applications. Should be go back to developing on version 1.4.4 ?

Hi,

The issue is fixed for the future 1.6 release. Release it self isn’t published yet, since we need to resolve all planned issues for it.

Regards,
Gleb

@gorelov Well, why is there no fix for the current 1.5 release: 1.5.6?

Even if there will be a release of 1.6.0 soon, I really don’t want to migrate a production instance directly from 1.4.4 to 1.6.0 including new breaking changes without proper testing.

Is there a long term support for the latest 1.x version?

According to Jmix Release Versioning page, the end of free maintenance of Jmix 1.5 is 2024 Q1. That is why all bug fix issues are planned for Jmix 1.6.

Regards,
Gleb

Hi @gorelov ,

according to Versioning – Jmix the release of Jmix 1.6 was planned for Q1 2024, too. Can you give us an updated time schedule? There are still 12 issues in the backlog of this version.

I understand that it’s additional afford to release the bug fixes, but since you promised Extended Support for Version 1.x and there was no Jmix 1.5.x in 2024 and Jmix 1.6 seems not to be ready, this would be a sign of good will.

Sorry for the delay with 1.6. We are going to release it in June as soon as we prepare release candidate for 2.3. Most probably some of the open issues that you see in the backlog will be fixed in subsequent patches of 1.6.

Yes, as promised, we continue fixing bugs and add features to 1.x. Release 1.6.0 will be available in the next few weeks.

Regards,
Konstantin