77import io
88import json
99import pickle
10+ import re
1011import types
1112import warnings
1213from collections import deque
@@ -661,7 +662,7 @@ def id_func_chart_error_example(val) -> str:
661662chart_funcs_error_message : list [tuple [Callable [..., Any ], str ]] = [
662663 (
663664 chart_error_example__invalid_y_option_value_unknown_x_option ,
664- r """Multiple errors were found.
665+ rf """Multiple errors were found.
665666
666667 Error 1: `X` has no parameter named 'unknown'
667668
@@ -676,21 +677,21 @@ def id_func_chart_error_example(val) -> str:
676677 Error 2: 'asdf' is an invalid value for `stack`. Valid values are:
677678
678679 - One of \['zero', 'center', 'normalize'\]
679- - Of type 'null' or 'boolean' $""" ,
680+ - Of type { re . escape ( "`bool | None`" ) } $""" ,
680681 ),
681682 (
682683 chart_error_example__wrong_tooltip_type_in_faceted_chart ,
683- r """'\['wrong'\]' is an invalid value for `field`. Valid values are of type 'string' or 'object' .$""" ,
684+ rf """'\['wrong'\]' is an invalid value for `field`. Valid values are of type { re . escape ( "`str | Mapping[str, Any]`" ) } .$""" ,
684685 ),
685686 (
686687 chart_error_example__wrong_tooltip_type_in_layered_chart ,
687- r """'\['wrong'\]' is an invalid value for `field`. Valid values are of type 'string' or 'object' .$""" ,
688+ rf """'\['wrong'\]' is an invalid value for `field`. Valid values are of type { re . escape ( "`str | Mapping[str, Any]`" ) } .$""" ,
688689 ),
689690 (
690691 chart_error_example__two_errors_in_layered_chart ,
691- r """Multiple errors were found.
692+ rf """Multiple errors were found.
692693
693- Error 1: '\['wrong'\]' is an invalid value for `field`. Valid values are of type 'string' or 'object' .
694+ Error 1: '\['wrong'\]' is an invalid value for `field`. Valid values are of type { re . escape ( "`str | Mapping[str, Any]`" ) } .
694695
695696 Error 2: `Color` has no parameter named 'invalidArgument'
696697
@@ -703,17 +704,17 @@ def id_func_chart_error_example(val) -> str:
703704 ),
704705 (
705706 chart_error_example__two_errors_in_complex_concat_layered_chart ,
706- r """Multiple errors were found.
707+ rf """Multiple errors were found.
707708
708- Error 1: '\['wrong'\]' is an invalid value for `field`. Valid values are of type 'string' or 'object' .
709+ Error 1: '\['wrong'\]' is an invalid value for `field`. Valid values are of type { re . escape ( "`str | Mapping[str, Any]`" ) } .
709710
710- Error 2: '4' is an invalid value for `bandPosition`. Valid values are of type 'number' .$""" ,
711+ Error 2: '4' is an invalid value for `bandPosition`. Valid values are of type `float` .$""" ,
711712 ),
712713 (
713714 chart_error_example__three_errors_in_complex_concat_layered_chart ,
714- r """Multiple errors were found.
715+ rf """Multiple errors were found.
715716
716- Error 1: '\['wrong'\]' is an invalid value for `field`. Valid values are of type 'string' or 'object' .
717+ Error 1: '\['wrong'\]' is an invalid value for `field`. Valid values are of type { re . escape ( "`str | Mapping[str, Any]`" ) } .
717718
718719 Error 2: `Color` has no parameter named 'invalidArgument'
719720
@@ -724,7 +725,7 @@ def id_func_chart_error_example(val) -> str:
724725
725726 See the help for `Color` to read the full description of these parameters
726727
727- Error 3: '4' is an invalid value for `bandPosition`. Valid values are of type 'number' .$""" ,
728+ Error 3: '4' is an invalid value for `bandPosition`. Valid values are of type `float` .$""" ,
728729 ),
729730 (
730731 chart_error_example__two_errors_with_one_in_nested_layered_chart ,
@@ -764,46 +765,46 @@ def id_func_chart_error_example(val) -> str:
764765 ),
765766 (
766767 chart_error_example__invalid_y_option_value ,
767- r """'asdf' is an invalid value for `stack`. Valid values are:
768+ rf """'asdf' is an invalid value for `stack`. Valid values are:
768769
769770 - One of \['zero', 'center', 'normalize'\]
770- - Of type 'null' or 'boolean' $""" ,
771+ - Of type { re . escape ( "`bool | None`" ) } $""" ,
771772 ),
772773 (
773774 chart_error_example__invalid_y_option_value_with_condition ,
774- r """'asdf' is an invalid value for `stack`. Valid values are:
775+ rf """'asdf' is an invalid value for `stack`. Valid values are:
775776
776777 - One of \['zero', 'center', 'normalize'\]
777- - Of type 'null' or 'boolean' $""" ,
778+ - Of type { re . escape ( "`bool | None`" ) } $""" ,
778779 ),
779780 (
780781 chart_error_example__hconcat ,
781- r """'{'text': 'Horsepower', 'align': 'right'}' is an invalid value for `title`. Valid values are of type 'string', 'array', or 'null' .$""" ,
782+ rf """'{{ 'text': 'Horsepower', 'align': 'right'}} ' is an invalid value for `title`. Valid values are of type { re . escape ( "`str | Sequence | None`" ) } .$""" ,
782783 ),
783784 (
784785 chart_error_example__invalid_timeunit_value ,
785- r """'invalid_value' is an invalid value for `timeUnit`. Valid values are:
786+ rf """'invalid_value' is an invalid value for `timeUnit`. Valid values are:
786787
787788 - One of \['year', 'quarter', 'month', 'week', 'day', 'dayofyear', 'date', 'hours', 'minutes', 'seconds', 'milliseconds'\]
788789 - One of \['utcyear', 'utcquarter', 'utcmonth', 'utcweek', 'utcday', 'utcdayofyear', 'utcdate', 'utchours', 'utcminutes', 'utcseconds', 'utcmilliseconds'\]
789790 - One of \['yearquarter', 'yearquartermonth', 'yearmonth', 'yearmonthdate', 'yearmonthdatehours', 'yearmonthdatehoursminutes', 'yearmonthdatehoursminutesseconds', 'yearweek', 'yearweekday', 'yearweekdayhours', 'yearweekdayhoursminutes', 'yearweekdayhoursminutesseconds', 'yeardayofyear', 'quartermonth', 'monthdate', 'monthdatehours', 'monthdatehoursminutes', 'monthdatehoursminutesseconds', 'weekday', 'weekdayhours', 'weekdayhoursminutes', 'weekdayhoursminutesseconds', 'dayhours', 'dayhoursminutes', 'dayhoursminutesseconds', 'hoursminutes', 'hoursminutesseconds', 'minutesseconds', 'secondsmilliseconds'\]
790791 - One of \['utcyearquarter', 'utcyearquartermonth', 'utcyearmonth', 'utcyearmonthdate', 'utcyearmonthdatehours', 'utcyearmonthdatehoursminutes', 'utcyearmonthdatehoursminutesseconds', 'utcyearweek', 'utcyearweekday', 'utcyearweekdayhours', 'utcyearweekdayhoursminutes', 'utcyearweekdayhoursminutesseconds', 'utcyeardayofyear', 'utcquartermonth', 'utcmonthdate', 'utcmonthdatehours', 'utcmonthdatehoursminutes', 'utcmonthdatehoursminutesseconds', 'utcweekday', 'utcweekdayhours', 'utcweekdayhoursminutes', 'utcweekdayhoursminutesseconds', 'utcdayhours', 'utcdayhoursminutes', 'utcdayhoursminutesseconds', 'utchoursminutes', 'utchoursminutesseconds', 'utcminutesseconds', 'utcsecondsmilliseconds'\]
791792 - One of \['binnedyear', 'binnedyearquarter', 'binnedyearquartermonth', 'binnedyearmonth', 'binnedyearmonthdate', 'binnedyearmonthdatehours', 'binnedyearmonthdatehoursminutes', 'binnedyearmonthdatehoursminutesseconds', 'binnedyearweek', 'binnedyearweekday', 'binnedyearweekdayhours', 'binnedyearweekdayhoursminutes', 'binnedyearweekdayhoursminutesseconds', 'binnedyeardayofyear'\]
792793 - One of \['binnedutcyear', 'binnedutcyearquarter', 'binnedutcyearquartermonth', 'binnedutcyearmonth', 'binnedutcyearmonthdate', 'binnedutcyearmonthdatehours', 'binnedutcyearmonthdatehoursminutes', 'binnedutcyearmonthdatehoursminutesseconds', 'binnedutcyearweek', 'binnedutcyearweekday', 'binnedutcyearweekdayhours', 'binnedutcyearweekdayhoursminutes', 'binnedutcyearweekdayhoursminutesseconds', 'binnedutcyeardayofyear'\]
793- - Of type 'object' $""" ,
794+ - Of type { re . escape ( "`Mapping[str, Any]`" ) } $""" ,
794795 ),
795796 (
796797 chart_error_example__invalid_sort_value ,
797- r """'invalid_value' is an invalid value for `sort`. Valid values are:
798+ rf """'invalid_value' is an invalid value for `sort`. Valid values are:
798799
799800 - One of \['ascending', 'descending'\]
800801 - One of \['x', 'y', 'color', 'fill', 'stroke', 'strokeWidth', 'size', 'shape', 'fillOpacity', 'strokeOpacity', 'opacity', 'text'\]
801802 - One of \['-x', '-y', '-color', '-fill', '-stroke', '-strokeWidth', '-size', '-shape', '-fillOpacity', '-strokeOpacity', '-opacity', '-text'\]
802- - Of type 'array', 'object', or 'null' $""" ,
803+ - Of type { re . escape ( "`Sequence | Mapping[str, Any] | None`" ) } $""" ,
803804 ),
804805 (
805806 chart_error_example__invalid_bandposition_value ,
806- r"""'4' is an invalid value for `bandPosition`. Valid values are of type 'number' .$""" ,
807+ r"""'4' is an invalid value for `bandPosition`. Valid values are of type `float` .$""" ,
807808 ),
808809 (
809810 chart_error_example__invalid_type ,
@@ -823,7 +824,7 @@ def id_func_chart_error_example(val) -> str:
823824 ),
824825 (
825826 chart_error_example__invalid_value_type ,
826- r """'1' is an invalid value for `value`. Valid values are of type 'object', 'string', or 'null' .$""" ,
827+ rf """'1' is an invalid value for `value`. Valid values are of type { re . escape ( "`str | Mapping[str, Any] | None`" ) } .$""" ,
827828 ),
828829 (
829830 chart_error_example__four_errors_hide_fourth ,
0 commit comments