Releases: elixir-cldr/cldr
Cldr version 2.38.1
Bug Fixes
-
Fix warnings on Elixir 1.17. This primarily relates to charlists constants now required to use
sigil_c
to avoid warnings. As a result, tests will only work on Elixir 1.16 and later even though support for the library is for Elixir 1.11 and later. -
Make
Cldr.Config.cldr_data_dir/0
a runtime result, not a compile time result. -
Sort currency data in
Cldr.Config.territories/0
so ensure deterministic order. Closes #227.
Cldr version 2.38.0
Cldr v2.38.0
This is the changelog for Cldr v2.38.0 released on April 21st, 2024. For older changelogs please consult the release tag on GitHub
Enhancements
-
Update to CLDR 45.0 data.
-
Adds
Cldr.validate_locale!/2
. Thanks to @jarrodmoldrich for the suggestion. -
Add decimal separator and grouping separator to the currency data for each locale. In some rare cases, like the currency [CVE](https://en.wikipedia.org/wiki/Cape_Verdean_escudo#:~:text=The%20escudo%20(sign%3A%20%3B%20ISO,subdivided%20into%20one%20hundred%20centavos.) in the locale pt-CV the currency symbol is placed where decimal separator is normally placed. The same can apply for the grouping separator although it appears not locale uses this field.
-
Adjust the
Inspect
protocol implementation fort:Cldr.LanguageTag.t/0
types. When the language tag is resolved to a CLDR locale then the output is executable code. For example:
iex> MyApp.Cldr.Locale.new!("en-US")
MyApp.Cldr.Locale.new!("en-US")
-
Fix dialyzer warnings. Thanks to @Munksgaard for the PR. Closes #220. Also fixes
:underspecs
warning and the:underspecs
dialyzer flag is now configured. -
Add configuration for the new ex_cldr_person_names backend module generator.
Cldr version 2.37.5
Bug Fixes
-
Fix warnings on Elixir 1.16.
-
Fix dialyzer warnings. Thanks to @Munksgaard for the PR. Closes #220.
Cldr version 2.37.4
Bug Fixes
- Reverts a change to the format of the alias data for subdivisions which was causing an exception in
ex_cldr_territories
. The change, which normalizes subdivision codes to be upcase atoms when the subdivision has its own ISO 3166 territory code, will be be added back forex_cldr
version 2.38.0 which will align with CLDR 44. Closes #216.
Cldr version 2.37.3
Cldr version 2.37.2
Bug Fixes
- Remove checking Phoenix and Ecto json_library configurations. Ecto no longer configures its
:json_library
inconfig.exs
and checking for Phoenix configuration can cause config failures when building in Docker. Thanks to @maciej-szlosarczyk for the report. Closes #208.
Enhancements
- Improves parsing of language tag extensions. Primarily intended to improve support for tempo.
Cldr version 2.37.1
Bug Fixes
- Don't include
:und
in the list returned byCldr.known_locale_names/1
since that function is commonly used to enumerate the configured locales and ultimately used to generate UI elements.:und
is not a useful locale to select so its inclusion, which was added inex_cldr version 2.37.0
is inappropriate and now reverted.
Cldr version 2.37.0
Bug Fixes
- Fixes
Cldr.Locale.parent/1
to use:und
as the ultimate parent rather than the default locale. This brings closer conformance to the CLDR specification.
Enhancements
-
Upgrade to CLDR 43 data.
-
Locale data is now versioned. If a locale file is found but if has no version (data prior to this release) or a version that does not match, the appropriate locale file is downloaded. This ensures locale files and
ex_cldr
are kept in sync. Closes #188. -
Changes
Cldr.version/0
to return the version of CLDR data as at:Version.t/0
. This is then used to check the version of the locale data and forcing a download if the locale data is out of date for this release ofex_cldr
. -
Adds
Cldr.Locale.script_direction_from_locale/1
andMyApp.Cldr.Locale.script_direction_from_locale/1
to return:ltr
(for left-to-right scripts) or:rtl
(for right-to-left scripts). Closes #196. Thanks to @Doerge for the suggestion. -
Adds
Cldr.Validity.Script.unicode_script_to_subtag/1
as public, undocumented function. This function is required byex_cldr_person_names
and may be documented in a future release. It maps between a unicode script name (like that returned byUnicode.script/1
in theunicode
library) to the appropriate subtag used by CLDR. -
Unit data is now kept as Decimal not Ratio so
:ratio
is no longer a dependency here, or inex_cldr_units
.
Cldr version 2.36.0
Note that ex_cldr
version 2.36.0 data for interval formats is keyed differently than that of previous releases. The bug fix noted below means that this version of ex_cldr
is only compatible with ex_cldr_dates_times
version 2.13.3
and later. Only ex_cldr_dates_times
is affected, other ex_cldr
libraries are insensitive to this change.
Bug Fixes
-
Fixes the date time interval format keys. In previous releases, the locale ingestion process would treat keys like
:Hm
as being the same as:hm
and as a result only the lower case version would be saved. This means that locales that rely upon0..23
or1..24
hour formats could not be formatted correctly. -
Fixes the
mix cldr.download.iso_currency
to use theCldr.Http.get/2
function to download the data. Doing so ensures that peer verification happens and no error log message is emitted.
Cldr version 2.35.1
Bug Fixes
- Fix bug that prevented setting
:default_currency_format
that slipped into the release (tests added).