Error after update 2.7.2 - Malformed pattern

Good evening everyone.

Today I received the notification of the new version 2.7.2. After updating, the screens started showing the error below.

I reverted to version 2.7.1, and the error stopped.

To add to that, normal, simple, basic screens, integer fields and text.

IllegalArgumentException: Malformed pattern "#.##0"

java.lang.IllegalArgumentException: Malformed pattern “#.##0
at java.base/java.text.DecimalFormat.applyPattern(DecimalFormat.java:3620) ~[na:na]
at java.base/java.text.DecimalFormat.(DecimalFormat.java:497) ~[na:na]
at io.jmix.core.metamodel.datatype.impl.IntegerDatatype.format(IntegerDatatype.java:56) ~[jmix-core-2.7.2.jar:na]
at io.jmix.core.MetadataTools.format(MetadataTools.java:188) ~[jmix-core-2.7.2.jar:na]
at io.jmix.flowui.data.provider.StringPresentationValueProvider.apply(StringPresentationValueProvider.java:48) ~[jmix-flowui-2.7.2.jar:na]
at io.jmix.flowui.data.provider.StringPresentationValueProvider.apply(StringPresentationValueProvider.java:34) ~[jmix-flowui-2.7.2.jar:na]
at com.vaadin.flow.component.grid.Grid.applyValueProvider(Grid.java:2039) ~[vaadin-grid-flow-24.9.2.jar:na]
at com.vaadin.flow.component.grid.Grid.lambda$addColumn$63838bef$1(Grid.java:2027) ~[vaadin-grid-flow-24.9.2.jar:na]
at com.vaadin.flow.component.grid.ColumnPathRenderer$SingleValueProviderRendering.lambda$getDataGenerator$96b60bbc$1(ColumnPathRenderer.java:78) ~[vaadin-grid-flow-24.9.2.jar:na]
at com.vaadin.flow.data.provider.CompositeDataGenerator.lambda$generateData$0(CompositeDataGenerator.java:47) ~[flow-data-24.9.2.jar:24.9.2]
at java.base/java.lang.Iterable.forEach(Iterable.java:75) ~[na:na]
at com.vaadin.flow.data.provider.CompositeDataGenerator.generateData(CompositeDataGenerator.java:47) ~[flow-data-24.9.2.jar:24.9.2]
at com.vaadin.flow.data.provider.DataCommunicator.generateJson(DataCommunicator.java:1547) ~[flow-data-24.9.2.jar:24.9.2]
at java.base/java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:197) ~[na:na]
at java.base/java.util.stream.ReferencePipeline$3$1.accept(ReferencePipeline.java:197) ~[na:na]
at java.base/java.util.stream.IntPipeline$1$1.accept(IntPipeline.java:180) ~[na:na]
at java.base/java.util.stream.Streams$RangeIntSpliterator.forEachRemaining(Streams.java:104) ~[na:na]
at java.base/java.util.Spliterator$OfInt.forEachRemaining(Spliterator.java:712) ~[na:na]
at java.base/java.util.stream.AbstractPipeline.copyInto(AbstractPipeline.java:509) ~[na:na]
at java.base/java.util.stream.AbstractPipeline.wrapAndCopyInto(AbstractPipeline.java:499) ~[na:na]
at java.base/java.util.stream.ReduceOps$ReduceOp.evaluateSequential(ReduceOps.java:921) ~[na:na]
Blockquote

Hello, Marcos!

Could you clarify the steps to reproduce the problem or share a small demo project that shows the issue?

Good evening,

I created a simple project, with only one table,

and during testing, I discovered that the problem is with the translation to Portuguese (Brazil).

Just run the project and use the BR translation.

Open the “simple” screen.

testeVersao.zip (120.6 KB)

Thank you for the demo project! The problem in the number formats:

#Number formats
integerFormat=#.##0
doubleFormat=#.##0,###
decimalFormat=#.##0,00

# Number separators
numberDecimalSeparator=,
numberGroupingSeparator=.

The grouping and decimal separators affect only the visual representation. For other formats, it should still use a dot as the decimal separator and a comma as the grouping separator, following the standard format of java.text.DecimalFormat.

As workaround try to add to your messages_pt_BR.properties file:

integerFormat=#,##0
doubleFormat=#,##0.###
decimalFormat=#,##0.00

I created a GitHub issue: Incorrect number formats in Portuguese (Brazil) translations · Issue #4980 · jmix-framework/jmix · GitHub