The CLDR database it downloaded is inconsistent and causing an exception:
The database has two parts to support internationalizing a file size: plural generator and unit formatter, we only use bytes, kilobytes, megabytes, and gigabytes
The plural generator turns a number into a plural type
In English, it turn 1 -> "one" and any other numbers -> "other" (only 2 types)
In Polish, the plural type for number could be "one", "many", "few", and "other" (4 types in total)
The unit formatter localize a number into string based on the plural type
In English, "one" -> "$1 byte", "other" -> "$1 bytes"
In Polish, "one" -> "$1 bajt", etc.
The inconsistency:
Plural generator return "one", "many", "few", "other" for Polish
Unit formatter only support "other"
This is causing the unit formatter throwing exception when the number has plural type of "one", "many", or "few"
Is it an issue related to Adaptive Cards?
Do you have any screenshots?
No response
What version of Web Chat are you using?
I am not using latest
Which distribution are you using Web Chat from?
Bundle (webchat.js)
Which hosting environment does this issue primarily affect?
Web apps
Which browsers and platforms do the issue happened?
Browser: Edge (latest), Browser: Chrome (latest), Browser: Firefox (latest), Browser: Safari (latest), Browser: IE Mode (latest), Platform: Windows, Platform: macOS, Platform: iOS/iPadOS, Platform: Android
Which area does this issue affect?
Attachment: Other rich cards
Is this an accessibility issue?
Please describe the bug
This issue repro as early as 4.8.0 (2020 March), and did not repro on 4.7.1 (2019 December).
The technical root cause is:
When the Unicode CLDR is downloaded from https://github.com/unicode-cldr/cldr-units-full/archive/36.0.0.zip, it does not contains
one
/few
/many
forshort/digital-gigabyte
,short/digital-megabyte
, andshort/digital-kilobyte
.However, the
supplemental/plurals
say Polish do have plural types ofone
/few
/many
, as shown below:When we are doing our investigation, we also look at another source of Unicode CLDR, at https://github.com/unicode-org/cldr/blob/release-36/common/main/pl.xml. In this source, we do see
short/digital-gigabyte
et al. haveone
/few
/many
.We concluded the issue is rooted from the Unicode CLDR v36 database. And it is causing
globalize
package to fail due to the missing strings.Do you see any errors in console log?
Based on 4.14.1.
How to reproduce the issue?
What is the expected and actual behavior?
Expected: the uploaded file should display properly
Actual: the uploaded file appear to be an empty box
Adaptive Card JSON
No response
Additional context
IcM ticket 332820283 and 330190903.