Files
ServerSync/lib/questionary/prompts/__pycache__/select.cpython-314.pyc

128 lines
14 KiB
Plaintext
Raw Normal View History

2026-02-12 02:28:23 +02:00
+
9<><39>ip*<00> <00><00>^RIt^RIHt^RIHt^RIHt^RIHt^RIHt^RIHt^RI H
t
^R I H t ^R
I Ht^R IHt^R IHt^R IHt^RIHt^RIHt^RIHt^RIHt^RIHt^RIHtR]]RRRRRRRRRR3 RRlltR#)<18>N)<01>Any)<01>Dict)<01>Optional)<01>Sequence)<01>Union)<01> Application)<01> KeyBindings)<01>Keys)<01>Style)<01>utils)<01>DEFAULT_QUESTION_PREFIX)<01>DEFAULT_SELECTED_POINTER)<01>common)<01>Choice)<01>InquirerControl)<01> Separator)<01>Question)<01>merge_styles_defaultFTc"<00><><00>V^8<>dQhR\R\\\\\\\
3,3,,R\ \\\\\\
3,3,,R\R\ \,R\ \,R\R\R \R
\R \R \R \R\R\ \,R\
R\/#)<12><00>message<67>choices<65>default<6C>qmark<72>pointer<65>style<6C> use_shortcuts<74>use_arrow_keys<79> use_indicator<6F> use_jk_keys<79>use_emacs_keys<79>use_search_filter<65> show_selected<65>show_description<6F> instruction<6F>kwargs<67>return)
<EFBFBD>strrrrrrrr <00>boolr)<01>formats"<22>A/tmp/pip-target-wqrk2shd/lib/python/questionary/prompts/select.py<70> __annotate__r,s<00><00>A<06>A<06> <10>A<06> <15>e<EFBFBD>C<EFBFBD><16><14>c<EFBFBD>3<EFBFBD>h<EFBFBD><1E>7<>8<> 9<>A<06><16>e<EFBFBD>C<EFBFBD><16><14>c<EFBFBD>3<EFBFBD>h<EFBFBD><1E>7<>8<> 9<>A<06> <0F> A<06>
<16>c<EFBFBD>]<5D> A<06> <14>E<EFBFBD>?<3F> A<06><18>A<06><19>A<06><18>A<06><16>A<06><19>A<06><1C>A<06><18>A<06><1B>A<06><1A>#<23><1D>A<06> <12>!A<06>"<0E>#A<06>c <04><>aaaaa aaa<1F>S'g$S'gV 'gV
'g \R4hV 'dS 'd \R4hS'dNV 'dF\;QJdRV4F 'gK RM RM !RV44'd \R4hVe\V4^8Xd \R4hS'dc\RV44pV\\P
48<>d3\R P \\P
4V44h\V.4p\ VVVVSV V SVR
7 oVVVVVV V3R lp\P!SV3/VBp\4oSP\PRR 7SP\PRR 7R 44pS'd<>\SP 4F<>wppVP"f?VP$'g-S'g%\'RP VP(44h\+V\,4'g!VP"eVP$'dK<>VV3RlpV!VVP"4K<> V3RlpV3RlpS 'd^V3Rlp\.P0FpSPVRR 7!V4K SP\P2RR 7!V4S'dOSP\P4RR 7!V4SP\P6RR 7!V4V 'd3SPRRR 7!V4SPRRR 7!V4V
'dOSP\P8RR 7!V4SP\P:RR 7!V4SP\P<RR 7V3Rl4pSP\P>4R4p\A\CRRVRSRV/\DPF!V\BPH4B4#)u<> A list of items to select **one** option from.
The user can pick one option and confirm it (if you want to allow
the user to select multiple options, use :meth:`questionary.checkbox` instead).
Example:
>>> import questionary
>>> questionary.select(
... "What do you want to do?",
... choices=[
... "Order a pizza",
... "Make a reservation",
... "Ask for opening hours"
... ]).ask()
? What do you want to do? Order a pizza
'Order a pizza'
.. image:: ../images/select.gif
This is just a really basic example, the prompt can be customised using the
parameters.
Args:
message: Question text
choices: Items shown in the selection, this can contain :class:`Choice` or
or :class:`Separator` objects or simple items as strings. Passing
:class:`Choice` objects, allows you to configure the item more
(e.g. preselecting it or disabling it).
default: A value corresponding to a selectable item in the choices,
to initially set the pointer position to.
qmark: Question prefix displayed in front of the question.
By default this is a ``?``.
pointer: Pointer symbol in front of the currently highlighted element.
By default this is a ``»``.
Use ``None`` to disable it.
instruction: A hint on how to navigate the menu.
It's ``(Use shortcuts)`` if only ``use_shortcuts`` is set
to True, ``(Use arrow keys or shortcuts)`` if ``use_arrow_keys``
& ``use_shortcuts`` are set and ``(Use arrow keys)`` by default.
style: A custom color and style for the question parts. You can
configure colors as well as font types for different elements.
use_indicator: Flag to enable the small indicator in front of the
list highlighting the current location of the selection
cursor.
use_shortcuts: Allow the user to select items from the list using
shortcuts. The shortcuts will be displayed in front of
the list items. Arrow keys, j/k keys and shortcuts are
not mutually exclusive.
use_arrow_keys: Allow the user to select items from the list using
arrow keys. Arrow keys, j/k keys and shortcuts are not
mutually exclusive.
use_jk_keys: Allow the user to select items from the list using
`j` (down) and `k` (up) keys. Arrow keys, j/k keys and
shortcuts are not mutually exclusive.
use_emacs_keys: Allow the user to select items from the list using
`Ctrl+N` (down) and `Ctrl+P` (up) keys. Arrow keys, j/k keys,
emacs keys and shortcuts are not mutually exclusive.
use_search_filter: Flag to enable search filtering. Typing some string will
filter the choices to keep only the ones that contain the
search string.
Note that activating this option disables "vi-like"
navigation as "j" and "k" can be part of a prefix and
therefore cannot be used for navigation
show_selected: Display current selection choice at the bottom of list.
show_description: Display description of current selection if available.
Returns:
:class:`Question`: Question instance, ready to be prompted (using ``.ask()``).
z^Some option to move the selection is required. Arrow keys, j/k keys, emacs keys, or shortcuts.zSCannot use j/k keys with prefix filter search, since j/k can be part of the prefix.c3<00>B"<00>TFp\VRR4R9x<00>K R#5i)<04> shortcut_key<65>N)<02>j<>k)<01>getattr<74><02>.0<EFBFBD>cs& r+<00> <genexpr><3E>select.<locals>.<genexpr><3E>s<00><00><00>M<>W<EFBFBD><01>w<EFBFBD>q<EFBFBD>.<2E>"<22>-<2D><1A>;<3B>W<EFBFBD>s<00>TFzqA choice is trying to register j/k as a shortcut key when they are in use as arrow keys disable one or the other.z'A list of choices needs to be provided.c3<00>V"<00>TFp\V\4'dK^x<00>K! R#5i)<02>N)<02>
isinstancerr5s& r+r8r9<00>s<00><00><00>!U<>W<EFBFBD><01>J<EFBFBD>q<EFBFBD>)<29><T<>!<21>!<21>W<EFBFBD>s<00>)<01>
)z<>A list with shortcuts supports a maximum of {} choices as this is the maximum number of keyboard shortcuts that are available. You provided {} choices!)rrrr#r$r<00>initial_choicec
<00><><<07>RS3RRPS43.pSP'd<>\SP4P\
4'dSTP RRPSP4PUu.uF q^,NK up434V#VP RSP4P34V#S'dVP RS34V#S 'dS'dRS'dRMR R2pM1S 'dS'gR S'dRMR R2pMR
S'dRMR R2pVP RV34V#uupi) z class:qmarkzclass:questionz {} z class:answerr1zclass:instructionz(Use shortcuts or arrow keysz, type to filter<65>)z(Use shortcutsz(Use arrow keys)r*<00> is_answeredr<<00>get_pointed_at<61>title<6C>list<73>append<6E>join)
<EFBFBD>tokens<6E>token<65>instruction_msg<73>icr%rrrr"rs
<20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>r+<00>get_prompt_tokens<6E>!select.<locals>.get_prompt_tokens<6E>sF<00><><00> <20>%<25>(<28>+;<3B>V<EFBFBD>]<5D>]<5D>7<EFBFBD>=S<>*T<>U<><06> <0A>><3E>><3E>><3E><19>"<22>+<2B>+<2B>-<2D>3<>3<>T<EFBFBD>:<3A>:<3A><16> <0A> <0A>&<26><1A><07><07>r<EFBFBD>7H<37>7H<37>7J<37>7P<37>7P<37> Q<>7P<37>e<EFBFBD>q<EFBFBD><18><18>7P<37> Q<>R<><16><12>(<16> <0A><17> <0A> <0A>~<7E>r<EFBFBD>/@<40>/@<40>/B<>/H<>/H<>I<>J<><16> <0A><1B><16> <0A> <0A>2<>K<EFBFBD>@<40>A<><16> <0A>!<21>^<5E>(D<>[l<>EW<45>rt<72>Du<44>uv<75>&w<>O<EFBFBD>"<22>><3E>(6<>M^<5E>7I<37>df<64>6g<36>gh<67>&i<>O<EFBFBD>(7<>N_<4E>8J<38>eg<65>7h<37>hi<68>&j<>O<EFBFBD><16> <0A> <0A>2<>O<EFBFBD>D<>E<><15> <0A><>#!Rs<00> E<0E><01>eagerc<00>H<00>VPP\RR7R#)zclass:aborting)<02> exceptionrN)<03>app<70>exit<69>KeyboardInterrupt<70><01>events&r+<00>_<>select.<locals>._<>s<00><00> <0E> <09> <09><0E><0E>!2<>:J<><0E>Kr-zc{} does not have a shortcut and arrow keys for movement are disabled. This choice is not reachable.c<00>D<a<00>SPVRR7VV3Rl4pR#)TrLc<00><<02>SSnR#<00>N)<01>
pointed_at)rT<00>irIs&<26><>r+<00> select_choice<63>3select.<locals>._reg_binding.<locals>.select_choice<63>s
<00><><00>$%<25>B<EFBFBD>Mr-N)<01>add)r[<00>keysr\<00>bindingsrIsf& <20><>r+<00> _reg_binding<6E>select.<locals>._reg_binding<6E>s$<00><><00><1A><1C><1C>d<EFBFBD>$<24><1C>/<2F>&<26>0<>&r-c<00>x<<01>SP4SP4'gSP4K(R#rY)<02> select_next<78>is_selection_valid<69>rTrIs&<26>r+<00>move_cursor_down<77> select.<locals>.move_cursor_down<77>s+<00><><00>
<EFBFBD><0E><0E><18><14>'<27>'<27>)<29>)<29> <0E>N<EFBFBD>N<EFBFBD> <1C>*r-c<00>x<<01>SP4SP4'gSP4K(R#rY)<02>select_previousrerfs&<26>r+<00>move_cursor_up<75>select.<locals>.move_cursor_up<75>s/<00><><00>
<EFBFBD><1A><1A><1C><14>'<27>'<27>)<29>)<29> <0E> <1E> <1E> <20>*r-c<00>`<<01>SPVP^,P4R#)rN)<03>add_search_character<65> key_sequence<63>keyrfs&<26>r+<00> search_filter<65>select.<locals>.search_filter<65>s"<00><><00> <0E> #<23> #<23>E<EFBFBD>$6<>$6<>q<EFBFBD>$9<>$=<3D>$=<3D> >r-r2r3c<00>~<<01>RSnVPPSP4PR7R#)T)<01>resultN)r@rPrQrA<00>valuerfs&<26>r+<00>
set_answer<EFBFBD>select.<locals>.set_answer s+<00><><00><1D><02><0E> <0A> <09> <09><0E><0E>b<EFBFBD>/<2F>/<2F>1<>7<>7<><0E>8r-c<04><00>R#)zDisallow inserting other text.N<>rSs&r+<00>other<65>select.<locals>.others<00>r-<00>layout<75> key_bindingsrry)%<25>
ValueError<EFBFBD>any<6E>len<65>sumr<00> SHORTCUT_KEYSr*rr<00>create_inquirer_layoutr r^r
<00>ControlQ<6C>ControlC<6C> enumeraterr0<00>disabled<65> RuntimeErrorrBr<r<00>string<6E> printable<6C> Backspace<63>Down<77>Up<55>ControlN<6C>ControlP<6C>ControlMrrrr <00> used_kwargs<67>__init__) rrrrrrrrrr r!r"r#r$r%r&<00>real_len_of_choices<65> merged_stylerJr|rUr[r7rargrkrq<00> characterrvrzr`rIs f&&f&&ff&&&f&&f, @@r+<00>selectr<74>s<><00><><00>L <1B>m<EFBFBD>{<7B>n<EFBFBD><18>B<01>
<EFBFBD>
<EFBFBD><13>(<28><18> a<>
<EFBFBD>
<EFBFBD><15><1B> <0E>3<EFBFBD>M<>W<EFBFBD>M<>3<EFBFBD>3<EFBFBD>3<EFBFBD>M<>W<EFBFBD>M<> M<> M<><1C>,<2C><0E> <0E> <0F><EFBFBD>#<23>g<EFBFBD>,<2C>!<21>+<2B><18>B<>C<>C<><14>!<21>!U<>W<EFBFBD>!U<>U<><1B> <1E><13>_<EFBFBD>%B<>%B<>!C<> C<><1C><13><1A>6<EFBFBD>#<23>o<EFBFBD>;<3B>;<3B><<3C>>Q<>R<> <0E> <0E>(<28><15><07>0<>L<EFBFBD> <18><0F><0F><17>#<23>#<23>#<23>)<29>%<25><1E>
<06>B<EFBFBD><16><16>8<14> *<2A> *<2A>2<EFBFBD>/@<40> K<>F<EFBFBD> K<>F<EFBFBD><1A>}<7D>H<EFBFBD> <0A>\<5C>\<5C>$<24>-<2D>-<2D>t<EFBFBD>\<5C>,<2C> <0A>\<5C>\<5C>$<24>-<2D>-<2D>t<EFBFBD>\<5C>,<2C>L<01>-<2D>-<2D>L<01><15><1D>b<EFBFBD>j<EFBFBD>j<EFBFBD>)<29>D<EFBFBD>A<EFBFBD>q<EFBFBD><10>~<7E>~<7E>%<25>a<EFBFBD>j<EFBFBD>j<EFBFBD>j<EFBFBD><1E>"<22>4<>4:<3A>F<EFBFBD>1<EFBFBD>7<EFBFBD>7<EFBFBD>O<EFBFBD><12><12>
<1A>!<21>Y<EFBFBD>'<27>'<27>1<EFBFBD>><3E>><3E>+A<>Q<EFBFBD>Z<EFBFBD>Z<EFBFBD>Z<EFBFBD><18> &<26> <19><11>A<EFBFBD>N<EFBFBD>N<EFBFBD> +<2B>%*<2A>(<1D>
!<21>
<19> ?<3F> <20>)<29>)<29>I<EFBFBD> <14>L<EFBFBD>L<EFBFBD><19>$<24>L<EFBFBD> /<2F> <0A> ><3E>*<2A><10> <0C> <0C>T<EFBFBD>^<5E>^<5E>4<EFBFBD> <0C>0<><1D>?<3F><15><10> <0C> <0C>T<EFBFBD>Y<EFBFBD>Y<EFBFBD>d<EFBFBD> <0C>+<2B>,<<3C>=<3D><10> <0C> <0C>T<EFBFBD>W<EFBFBD>W<EFBFBD>D<EFBFBD> <0C>)<29>.<2E>9<><12><10> <0C> <0C>S<EFBFBD><04> <0C>%<25>&6<>7<><10> <0C> <0C>S<EFBFBD><04> <0C>%<25>n<EFBFBD>5<><15><10> <0C> <0C>T<EFBFBD>]<5D>]<5D>$<24> <0C>/<2F>0@<40>A<><10> <0C> <0C>T<EFBFBD>]<5D>]<5D>$<24> <0C>/<2F><0E>?<3F> <0A>\<5C>\<5C>$<24>-<2D>-<2D>t<EFBFBD>\<5C>,<2C>9<>-<2D>9<><0E>\<5C>\<5C>$<24>(<28>(<28><1B>-<2D><1C>-<2D> <14><13>
<EFBFBD><19>
<EFBFBD>!<21>
<EFBFBD><1F>
<EFBFBD><14><1F><1F><06> <0B>(<<3C>(<<3C>=<3D> 
<EFBFBD> <06>r-)r<><00>typingrrrrr<00>prompt_toolkit.applicationr<00>prompt_toolkit.key_bindingr <00>prompt_toolkit.keysr
<00>prompt_toolkit.stylesr <00> questionaryr <00>questionary.constantsr r<00>questionary.promptsr<00>questionary.prompts.commonrrr<00>questionary.questionr<00>questionary.stylesrr<>ryr-r+<00><module>r<>sv<00><01><0E><16><17><1B><1B><18>2<>2<>$<24>'<27><1D>9<>:<3A>&<26>-<2D>6<>0<>)<29>3<> =A<01>(<28>5<>!<21><1F><1F><1F><1C><1F>#<23><1F>!<21>!%<25>A<06>Ar-