Reduce icu_validation_level default to WARNING.
Discussion: https://postgr.es/m/daa9f060aa2349ebc84444515efece49e7b32c5d.camel@j-davis.com
This commit is contained in:
parent
009bd237bf
commit
6de31ce446
@ -9841,7 +9841,7 @@ SET XML OPTION { DOCUMENT | CONTENT };
|
||||
<para>
|
||||
If set to <literal>DISABLED</literal>, does not report validation
|
||||
problems at all. Otherwise reports problems at the given message
|
||||
level. The default is <literal>ERROR</literal>.
|
||||
level. The default is <literal>WARNING</literal>.
|
||||
</para>
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
@ -96,7 +96,7 @@ char *locale_monetary;
|
||||
char *locale_numeric;
|
||||
char *locale_time;
|
||||
|
||||
int icu_validation_level = ERROR;
|
||||
int icu_validation_level = WARNING;
|
||||
|
||||
/*
|
||||
* lc_time localization cache.
|
||||
|
@ -4689,7 +4689,7 @@ struct config_enum ConfigureNamesEnum[] =
|
||||
NULL
|
||||
},
|
||||
&icu_validation_level,
|
||||
ERROR, icu_validation_level_options,
|
||||
WARNING, icu_validation_level_options,
|
||||
NULL, NULL, NULL
|
||||
},
|
||||
|
||||
|
@ -734,7 +734,7 @@
|
||||
#lc_numeric = 'C' # locale for number formatting
|
||||
#lc_time = 'C' # locale for time formatting
|
||||
|
||||
#icu_validation_level = ERROR # report ICU locale validation
|
||||
#icu_validation_level = WARNING # report ICU locale validation
|
||||
# errors at the given level
|
||||
|
||||
# default configuration for text search
|
||||
|
@ -1037,18 +1037,18 @@ $$;
|
||||
RESET client_min_messages;
|
||||
CREATE COLLATION test3 (provider = icu, lc_collate = 'en_US.utf8'); -- fail, needs "locale"
|
||||
ERROR: parameter "locale" must be specified
|
||||
SET icu_validation_level = ERROR;
|
||||
CREATE COLLATION testx (provider = icu, locale = 'nonsense-nowhere'); -- fails
|
||||
ERROR: ICU locale "nonsense-nowhere" has unknown language "nonsense"
|
||||
HINT: To disable ICU locale validation, set parameter icu_validation_level to DISABLED.
|
||||
CREATE COLLATION testx (provider = icu, locale = '@colStrength=primary;nonsense=yes'); -- fails
|
||||
ERROR: could not convert locale name "@colStrength=primary;nonsense=yes" to language tag: U_ILLEGAL_ARGUMENT_ERROR
|
||||
SET icu_validation_level = WARNING;
|
||||
RESET icu_validation_level;
|
||||
CREATE COLLATION testx (provider = icu, locale = '@colStrength=primary;nonsense=yes'); DROP COLLATION testx;
|
||||
WARNING: could not convert locale name "@colStrength=primary;nonsense=yes" to language tag: U_ILLEGAL_ARGUMENT_ERROR
|
||||
CREATE COLLATION testx (provider = icu, locale = 'nonsense-nowhere'); DROP COLLATION testx;
|
||||
WARNING: ICU locale "nonsense-nowhere" has unknown language "nonsense"
|
||||
HINT: To disable ICU locale validation, set parameter icu_validation_level to DISABLED.
|
||||
RESET icu_validation_level;
|
||||
CREATE COLLATION test4 FROM nonsense;
|
||||
ERROR: collation "nonsense" for encoding "UTF8" does not exist
|
||||
CREATE COLLATION test5 FROM test0;
|
||||
|
@ -376,12 +376,12 @@ $$;
|
||||
RESET client_min_messages;
|
||||
|
||||
CREATE COLLATION test3 (provider = icu, lc_collate = 'en_US.utf8'); -- fail, needs "locale"
|
||||
SET icu_validation_level = ERROR;
|
||||
CREATE COLLATION testx (provider = icu, locale = 'nonsense-nowhere'); -- fails
|
||||
CREATE COLLATION testx (provider = icu, locale = '@colStrength=primary;nonsense=yes'); -- fails
|
||||
SET icu_validation_level = WARNING;
|
||||
RESET icu_validation_level;
|
||||
CREATE COLLATION testx (provider = icu, locale = '@colStrength=primary;nonsense=yes'); DROP COLLATION testx;
|
||||
CREATE COLLATION testx (provider = icu, locale = 'nonsense-nowhere'); DROP COLLATION testx;
|
||||
RESET icu_validation_level;
|
||||
|
||||
CREATE COLLATION test4 FROM nonsense;
|
||||
CREATE COLLATION test5 FROM test0;
|
||||
|
Loading…
x
Reference in New Issue
Block a user