commit 6bcf3dda57e58309ba7871d968f5cdcc52a4e3dd98d4268e27c65f4d05efdc0e Author: Adrian Schröter Date: Fri May 3 21:57:26 2024 +0200 Sync from SUSE:SLFO:Main python-prompt_toolkit revision aadea07811873b7dad1acd66f290dbb6 diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..9b03811 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,23 @@ +## Default LFS +*.7z filter=lfs diff=lfs merge=lfs -text +*.bsp filter=lfs diff=lfs merge=lfs -text +*.bz2 filter=lfs diff=lfs merge=lfs -text +*.gem filter=lfs diff=lfs merge=lfs -text +*.gz filter=lfs diff=lfs merge=lfs -text +*.jar filter=lfs diff=lfs merge=lfs -text +*.lz filter=lfs diff=lfs merge=lfs -text +*.lzma filter=lfs diff=lfs merge=lfs -text +*.obscpio filter=lfs diff=lfs merge=lfs -text +*.oxt filter=lfs diff=lfs merge=lfs -text +*.pdf filter=lfs diff=lfs merge=lfs -text +*.png filter=lfs diff=lfs merge=lfs -text +*.rpm filter=lfs diff=lfs merge=lfs -text +*.tbz filter=lfs diff=lfs merge=lfs -text +*.tbz2 filter=lfs diff=lfs merge=lfs -text +*.tgz filter=lfs diff=lfs merge=lfs -text +*.ttf filter=lfs diff=lfs merge=lfs -text +*.txz filter=lfs diff=lfs merge=lfs -text +*.whl filter=lfs diff=lfs merge=lfs -text +*.xz filter=lfs diff=lfs merge=lfs -text +*.zip filter=lfs diff=lfs merge=lfs -text +*.zst filter=lfs diff=lfs merge=lfs -text diff --git a/prompt_toolkit-3.0.38.tar.gz b/prompt_toolkit-3.0.38.tar.gz new file mode 100644 index 0000000..17450e1 --- /dev/null +++ b/prompt_toolkit-3.0.38.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:23ac5d50538a9a38c8bde05fecb47d0b403ecd0662857a86f886f798563d5b9b +size 422834 diff --git a/python-prompt_toolkit.changes b/python-prompt_toolkit.changes new file mode 100644 index 0000000..606cb81 --- /dev/null +++ b/python-prompt_toolkit.changes @@ -0,0 +1,657 @@ +------------------------------------------------------------------- +Fri Apr 21 12:29:53 UTC 2023 - Dirk Müller + +- add sle15_python_module_pythons (jsc#PED-68) + +------------------------------------------------------------------- +Thu Apr 13 22:43:19 UTC 2023 - Matej Cepl + +- Make calling of %{sle15modernpython} optional. + +------------------------------------------------------------------- +Tue Apr 4 20:16:51 UTC 2023 - Ben Greiner + +- Update to 3.0.38 + * Fix regression in filters. (Use of `WeakValueDictionary` caused + filters to not be cached). +- Release 3.0.37 Bug fixes: + * Fix `currentThread()` deprecation warning. + * Fix memory leak in filters. + * Make VERSION tuple numeric. + * Add `.run()` method in `TelnetServer`. (To be used instead of + `.start()/.stop()`. + ## Breaking changes: + * Subclasses of `Filter` have to call `super()` in their + `__init__`. + * Drop support for Python 3.6: + - This includes code cleanup for Python 3.6 compatibility. + - Use `get_running_loop()` instead of `get_event_loop()`. + - Use `asyncio.run()` instead of + `asyncio.run_until_complete()`. + +------------------------------------------------------------------- +Tue Dec 13 16:16:08 UTC 2022 - Yogalakshmi Arunachalam + +- Update to version 3.0.36 + * Fixes: + - Another Python 3.6 fix for a bug that was introduced in 3.0.34. + +- Update to version 3.0.35 + Fixes: + - Fix bug introduced in 3.0.34 for Python 3.6. Use asynccontextmanager + implementation from prompt_toolkit itself. + +- Update to version 3.0.34 + Fixes: + - Improve completion performance in various places. + - Improve renderer performance. + - Handle `KeyboardInterrupt` when the stacktrace of an unhandled error is + displayed. + - Use correct event loop in `Application.create_background_task()`. + - Fix `show_cursor` attribute in `ScrollablePane`. + +------------------------------------------------------------------- +Tue Dec 6 04:28:29 UTC 2022 - Yogalakshmi Arunachalam + +- Update to version 3.0.33: + Fixes: + - Improve termination of `Application`. Don't suppress `CancelledError`. This + fixes a race condition when an `Application` gets cancelled while we're + waiting for the background tasks to complete. + - Fixed typehint for `OneStyleAndTextTuple`. + - Small bugfix in `CombinedRegistry`. Fixed missing `@property`. + +------------------------------------------------------------------- +Wed Nov 9 16:32:15 UTC 2022 - Yogalakshmi Arunachalam + +- Update to version 3.0.32: + Bug fixes: + - Use `DummyInput` by default in `create_input()` if `sys.stdin` does not have + a valid file descriptor. This fixes errors when `sys.stdin` is patched in + certain situations. + - Fix control-c key binding for `ProgressBar` when the progress bar was not + created from the main thread. The current code would try to kill the main + thread when control-c was pressed. + New features: + - Accept a `cancel_callback` in `ProgressBar` to specify the cancellation + behavior for when `control-c` is pressed. + - Small performance improvement in the renderer. + +------------------------------------------------------------------- +Tue Oct 4 23:17:53 UTC 2022 - Yogalakshmi Arunachalam + +- Update to version 3.0.31: 2022-09-02 + New features: + - Pass through `name` property in `TextArea` widget to `Buffer`. + - Added a `enable_cpr` parameter to `Vt100_Output`, `TelnetServer` and + `PromptToolkitSSHServer`, to completely disable CPR support instead of + automatically detecting it. + +------------------------------------------------------------------- +Fri Jul 1 11:57:35 UTC 2022 - John Paul Adrian Glaubitz + +- Update to version 3.0.30: + New features: + - Allow zero-width-escape sequences in `print_formatted_text`. + - Add default value option for input dialog. + - Added `has_suggestion` filter. + Fixes: + - Fix rendering of control-shift-6 (or control-^). Render as '^^' + - Always wrap lines in the Label widget by default. + - Fix enter key binding in system toolbar in Vi mode. + - Improved handling of stdout objects that don't have a 'buffer' attribute. For + instance, when using `renderer_print_formatted_text` in a Jupyter Notebook. +- from version 3.0.29: + New features: + - Accept 'handle_sigint' parameter in PromptSession. + Fixes + - Fix 'variable referenced before assignment' error in vt100 mouse bindings. + - Pass `handle_sigint` from `Application.run` to `Application.run_async`. + - Fix detection of telnet client side changes. + - Fix `print_container` utility (handle `EOFError`). + Breaking changes: + - The following are now context managers: + `create_pipe_input`, `PosixPipeInput` and `Win32PipeInput`. + +------------------------------------------------------------------- +Sat Mar 26 19:24:01 UTC 2022 - Dirk Müller + +- update to 3.0.28: + - Support format specifiers for HTML and ANSI formatted text. + - Accept defaults for checkbox and radio list, and their corresponding dialogs. + - Fix resetting of cursor shape after the application terminates. + - Support for cursor shapes. The cursor shape for prompts/applications can now + be configured, either as a fixed cursor shape, or in case of Vi input mode, + according to the current input mode. + - Handle "cursor forward" command in ANSI formatted text. This makes it + possible to render many kinds of generated ANSI art. + - Accept `align` attribute in `Label` widget. + - Added `PlainTextOutput`: an output implementation that doesn't render any + ANSI escape sequences. This will be used by default when redirecting stdout + to a file. + - Added `create_app_session_from_tty`: a context manager that enforces + input/output to go to the current TTY, even if stdin/stdout are attached to + pipes. + - Added `to_plain_text` utility for converting formatted text into plain text. + - Don't automatically use `sys.stderr` for output when `sys.stdout` is not a + TTY, but `sys.stderr` is. The previous behavior was confusing, especially + when rendering formatted text to the output, and we expect it to follow + +------------------------------------------------------------------- +Sat Feb 5 18:14:18 UTC 2022 - Atri Bhattacharya + +- Update to version 3.0.26: + * No Linux relevant changes. +- Changes from version 3.0.25: + * Use `DummyOutput` when `sys.stdout` is `None` and `DummyInput` + when `sys.stdin` is `None`. + * Correctly reset `Application._is_running` flag in case of + exceptions in some situations. + * Handle SIGINT (when sent from another process) and allow + binding it to a key binding. + * Increase the event loop `slow_duration_callback` by default to + 0.5 to prevent printing warnings if rendering takes too long + on slow systems. +- Older changelogs: see + https://github.com/prompt-toolkit/python-prompt-toolkit/blob/3.0.26/CHANGELOG + +------------------------------------------------------------------- +Sun Dec 20 09:38:35 UTC 2020 - Dirk Müller + +- update to 3.0.8: + - Added `validator` parameter to `input_dialog`. + - New "placeholder" parameter added to `PromptSession`. + - Fixes + - The SSH/Telnet adaptors have been refactored and improved in several ways. + See issues #876 and PR #1150 and #1184 on GitHub. + * Handle terminal types for both telnet and SSH sessions. + * Added pipe input abstraction. (base class for `PosixPipeInput` and + `Win32PipeInput`). + * The color depth logic has been refactored and moved to the `Output` + implementations. Added `get_default_color_depth` method to `Output` + objects. + * All line feets are now preceded by a carriage return in the telnet + connection stdout. + - Introduce `REPLACE_SINGLE` input mode for Vi key bindings. + - Improvements to the checkbox implementation: + * Hide the scrollbar for a single checkbox. + * Added a "checked" setter to the checkbox. + - Expose `KeyPressEvent` in key_binding/__init__.py (often used in type + annotations). + - The renderer has been optimized so that no trailing spaces are generated + (this improves copying in some terminals). + +------------------------------------------------------------------- +Thu Jun 11 10:49:19 UTC 2020 - Marketa Calabkova + +- Update to 3.0.5 + * no notable changes + +------------------------------------------------------------------- +Wed Mar 18 15:27:06 UTC 2020 - Marketa Calabkova + +- Update to 3.0.4 + * Python 2 support has been dropped. + * Native asyncio, so some async code becomes slightly different. + * (almost) 100% type annotated. + * Added shift-based text selection (use shift+arrows to start selecting text). + * Accept an empty prompt continuation. + * Improved support for "dumb" terminals. + * `ShiftControl` has been replaced with `ControlShift` and `s-c` with `c-s` in + key bindings. Aliases for backwards-compatibility have been added. + +------------------------------------------------------------------- +Thu Oct 10 08:31:46 UTC 2019 - Tomáš Chvátal + +- Update to 2.0.10: + * minor bugfixes around + +------------------------------------------------------------------- +Sat Mar 2 05:14:33 UTC 2019 - Arun Persaud + +- specfile: + * update copyright year + +- update to version 2.0.9: + * Bug fixes: + + Fixed `Application.run_system_command` on Windows. + + Fixed bug in ANSI text formatting: correctly handle 256/true + color sequences. + + Fixed bug in WordCompleter. Provide completions when there's a + space before the cursor. + +- changes from version 2.0.8: + * Bug fixes: + + Fixes the issue where changes made to the buffer in the accept + handler were not reflected in the history. + + Fix in the application invalidate handler. This prevents a + significat slow down in some applications after some time + (especially if there is a refresh interval). + + Make `print_container` utility work if the input is not a pty. + * New features: + + Underline non breaking spaces instead of rendering as '&'. + + Added mouse support for radio list. + + Support completion styles for `READLINE_LIKE` display method. + + Accept formatted text in the display text of completions. + + Added a `FuzzyCompleter` and `FuzzyWordCompleter`. + + Improved error handling in Application (avoid displaying a + meaningless AssertionError in many cases). + +------------------------------------------------------------------- +Thu Nov 1 22:41:46 UTC 2018 - Arun Persaud + +- update to version 2.0.7: + * Bug fixes: + + Fixed assertion in PromptSession: the style_transformation check + was wrong. + + Removed 'default' attribute in PromptSession. Only ask for it in + the `prompt()` method. This fixes the issue that passing + `default` once, will store it for all consequent calls in the + `PromptSession`. + + Ensure that `__pt_formatted_text__` always returns a + `FormattedText` instance. This fixes an issue with + `print_formatted_text`. + * New features: + + Improved handling of situations where stdin or stdout are not a + terminal. (Print warning instead of failing with an assertion.) + + Added `print_container` utility. + + Sound bell when attempting to edit read-only buffer. + + Handle page-down and page-up keys in RadioList. + + Accept any `collections.abc.Sequence` for HSplit/VSplit children + (instead of lists only). + + Improved Vi key bindings: return to navigation mode when Insert + is pressed. + +------------------------------------------------------------------- +Sat Oct 13 16:03:06 UTC 2018 - Arun Persaud + +- update to version 2.0.6: + * Bug fixes: + + Don't use the predefined ANSI colors for colors that are defined + as RGB. (Terminals can assign different color schemes for ansi + colors, and we don't want use any of those for colors that are + defined like #aabbcc for instance.) + + Fix in handling of CPRs when patch_stdout is used. + * Backwards incompatible changes: + + Change to the `Buffer` class. Reset the buffer unless the + `accept_handler` returns `True` (which means: "keep_text"). This + doesn't affect applications that use `PromptSession`. + * New features: + + Added `AdjustBrightnessStyleTransformation`. This is a simple + style transformation that improves the rendering on terminals + with light or dark background. + + Improved performance (string width caching and line height + calculation). + + Improved `TextArea`: + o Exposed `focus_on_click`. + o Added attributes: `auto_suggest`, `complete_while_typing`, + `history`, `get_line_prefix`, `input_processors`. + o Made attributes writable: `lexer`, `completer`, + `complete_while_typing`, `accept_handler`, `read_only`, + `wrap_lines`. + +- changes from version 2.0.5: + * Bug fixes: + + Fix in `DynamicContainer`. Return correct result for + `get_children`. This fixes a bug related to focusing. + + Properly compute length of `start`, `end` and `sym_b` characters + of progress bar. + + CPR (cursor position request) fix. + * Backwards incompatible changes: + + Stop restoring `PromptSession` attributes when exiting prompt. + * New features: + + Added `get_line_prefix` attribute to window. This opens many + possibilities: + o Line wrapping (soft and hard) can insert whitespace in front of + the line, or insert some symbols in front. Like the Vim + "breakindent" option. + o Single line prompts also support line continuations now. + o Line continuations can have a variable width. + + For VI mode: implemented temporary normal mode (control-O in + insert mode). + + Added style transformations API. Useful for swapping between + light and dark color schemes. Added `swap_light_and_dark_colors` + parameter to `prompt()` function. + + Added `format()` method to ANSI formatted text. + + Set cursor position for Button widgets. + + Added `pre_run` argument to `PromptSession.prompt()` method. + +------------------------------------------------------------------- +Fri Sep 28 03:43:16 UTC 2018 - Todd R + +- Update to 2.0.4 + + Bug fixes: + * Fix render height for rendering full screen applications in Windows. + * Fix in `TextArea`. Set `accept_handler` to `None` if not given. + * Go to the beginning of the next line when enter is pressed in Vi navigation + mode, and the buffer doesn't have an accept handler. + * Fix the `default` argument of the `prompt` function when called multiple + times. + * Display decomposed multiwidth characters correctly. + * Accept `history` in `prompt()` function again. + + Backwards incompatible changes: + * Renamed `PipeInput` to `PosixPipeInput`. Added `Win32PipeInput` and + `create_input_pipe`. + * Pass `buffer` argument to the `accept_handler` of `TextArea`. + + New features: + * Added `accept_default` argument to `prompt()`. + * Make it easier to change the body/title of a Frame/Dialog. + * Added `DynamicContainer`. + * Added `merge_completers` for merging multiple completers together. + * Add vt100 data to key presses in Windows. + * Handle left/right key bindings in Vi block insert mode. +- Update to 2.0.3 + + Bug fixes: + * Fix in 'x' and 'X' Vi key bindings. Correctly handle line endings and args. + * Fixed off by one error in Vi line selection. + * Fixed bugs in Vi block selection. Correctly handle lines that the selection + doesn't cross. + * Python 2 bugfix. Handle str/unicode correctly. + * Handle option+left/right in iTerm. +- Update to 2.0.2 + + Bug fixes: + * Python 3.7 support: correctly handle StopIteration in asynchronous generator. + * Fixed off-by-one bug in Vi visual block mode. + * Bugfix in TabsProcessor: handle situations when the cursor is at the end of + the line. +- Update to 2.0.1 + + Changes: + * No automatic translation from \r into \n during the input processing. These + are two different keys that can be handled independently. This is a big + backward-incompatibility, because the `Enter` key is `ControlM`, not + `ControlJ`. So, now that we stopped translating \r into \n, it could be that + custom key bindings for `Enter` don't work anymore. Make sure to bind + `Keys.Enter` instead of `Keys.ControlJ` for handling the `Enter` key. + * The `CommandLineInterface` and the `Application` classes are merged. First, + `CommandLineInterface` contained all the I/O objects (like the input, output + and event loop), while the `Application` contained everything else. There was + no practical reason to keep this separation. (`CommandLineInterface` was + mostly a proxy to `Application`.) + * prompt_toolkit no longer depends on Pygments, but it can still use Pygments + for its color schemes and lexers. In many places we used Pygments "Tokens", + this has been replaced by the concept of class names, somewhat similar to + HTML and CSS. + > `PygmentsStyle` and `PygmentsLexer` adaptors are available for + plugging in Pygments styles and lexers. + > Wherever we had a list of `(Token, text)` tuples, we now have lists of + `(style_string, text)` tuples. The style string can contain both inline + styling as well as refer to a class from the style sheet. `PygmentsTokens` + is an adaptor that converts a list of Pygments tokens into a list of + `(style_string, text)` tuples. + * Changes in the `Style` classes. + > `style.from_dict` does not exist anymore. Instantiate the ``Style`` class + directory to create a new style. ``Style.from_dict`` can be used to create + a style from a dictionary, where the dictionary keys are a space separated + list of class names, and the values, style strings (like before). + > `print_tokens` was renamed to `print_formatted_text`. + > In many places in the layout, we accept a parameter named `style`. All the + styles from the layout hierarchy are combined to decide what style to be + used. + > The ANSI color names were confusing and inconsistent with common naming + conventions. This has been fixed, but aliases for the original names were + kept. + * The way focusing works is different. Before it was always a `Buffer` that + was focused, and because of that, any visible `BufferControl` that contained + this `Buffer` would be focused. Now, any user control can be focused. All + of this is handled in the `Application.layout` object. + * The `buffers` dictionary (`CommandLineInterface.buffers`) does not exist + anymore. Further, `buffers` was a `BufferMapping` that keeps track of which + buffer has the focus. This significantly reduces the freedom for creating + complex applications. We wanted to move toward a layout that can be defined + as a (hierarchical) collection of user widgets. A user widget does not need + to have a `Buffer` underneath and any widget should be focusable. + > `layout.Layout` was introduced to contain the root layout widget and keep + track of the focus. + * The key bindings were refactored. It became much more flexible to combine + sets of key bindings. + > `Registry` has been renamed to `KeyBindings`. + > The `add_binding` function has been renamed to simply `add`. + > Every `load_*` function returns one `KeyBindings` objects, instead of + populating an existing one, like before. + > `ConditionalKeyBindings` was added. This can be used to enable/disable + all the key bindings from a given `Registry`. + > A function named `merge_key_bindings` was added. This takes a list of + `KeyBindings` and merges them into one. + > `key_binding.defaults.load_key_bindings` was added to load all the key + bindings. + > `KeyBindingManager` has been removed completely. + > `input_processor` was renamed to `key_processor`. + > The `Key` class does not exist anymore. Every key is a string and it's + considered fine to use string literals in the key bindings. This is more + readable, but we still have run-time validation. The `Keys` enum still + exist (for backwards-compatibility, but also to have an overview of which + keys are supported.) + > 'enter' and 'tab' are key aliases for 'c-m' and 'c-i'. + * User controls can define key bindings, which are active when the user control + is focused. + > `UIControl` got a `get_key_bindings` (abstract) method. + * Changes in the layout engine: + > `LayoutDimension` was renamed to `Dimension`. + > `VSplit` and `HSplit` now take a `padding` argument. + > `VSplit` and `HSplit` now take an `align` argument. + (TOP/CENTER/BOTTOM/JUSTIFY) or (LEFT/CENTER/RIGHT/JUSTIFY). + > `Float` now takes `allow_cover_cursor` and `attach_to_window` arguments. + > `Window` got an `WindowAlign` argument. This can be used for the alignment + of the content. `TokenListControl` (renamed to `FormattedTextControl`) does + not have an alignment argument anymore. + > All container objects, like `Window`, got a `style` argument. The style for + parent containers propagate to child containers, but can be overriden. + This is in particular useful for setting a background color. + > `FillControl` does not exist anymore. Use the `style` and `char` arguments + of the `Window` class instead. + > `DummyControl` was added. + > The continuation function of `PromptMargin` now takes `line_number` and + `is_soft_wrap` as input. + * Changes to `BufferControl`: + > The `InputProcessor` class has been refactored. The `apply_transformation` + method should now takes a `TransformationInput` object as input. + > The text `(reverse-i-search)` is now displayed through a processor. (See + the `shortcuts` module for an example of its usage.) + * `widgets` and `dialogs` modules: + > A small collection of widgets was added. These are more complex collections + of user controls that are ready to embed in a layout. A `shortcuts.dialogs` + module was added as a high level API for displaying input, confirmation and + message dialogs. + > Every class that exposes a ``__pt_container__`` method (which is supposed + to return a ``Container`` instance) is considered a widget. The + ``to_container`` shortcut will call this method in situations where a + ``Container`` object is expected. This avoids inheritance from other + ``Container`` types, but also having to unpack the container object from + the widget, in case we would have used composition. + > Warning: The API of the widgets module is not considered stable yet, and + can change is the future, if needed. + * Changes to `Buffer`: + > A `Buffer` no longer takes an `accept_action`. Both `AcceptAction` and + `AbortAction` have been removed. Instead it takes an `accept_handler`. + * Changes regarding auto completion: + > The left and right arrows now work in the multi-column auto completion + menu. + > By default, autocompletion is synchronous. The completer needs to be + wrapped in `ThreadedCompleter` in order to get asynchronous autocompletion. + > When the completer runs in a background thread, completions will be + displayed as soon as they are generated. This means that we don't have to + wait for all the completions to be generated, before displaying the first + one. The completion menus are updated as soon as new completions arrive. + * Changes regarding input validation: + > Added the `Validator.from_callable` class method for easy creation of + new validators. + * Changes regarding the `History` classes: + > The `History` base class has a different interface. This was needed for + asynchronous loading of the history. `ThreadedHistory` was added for this. + * Changes related to `shortcuts.prompt`: + > There is now a class `PromptSession` which also has a method `prompt`. Both + the class and the method take about the same arguments. This can be used to + create a session. Every `prompt` call of the same instance will reuse all + the arguments given to the class itself. + The input history is always shared during the entire session. + Of course, it's still possible to call the global `prompt` function. This + will create a new `PromptSession` every time when it's called. + > The `prompt` function now takes a `key_bindings` argument instead of + `key_bindings_registry`. This should only contain the additional bindings. + (The default bindings are always included.) + * Changes to the event loops: + > The event loop API is now closer to how asyncio works. A prompt_toolkit + `Application` now has a `Future` object. Calling the `.run_async()` method + creates and returns that `Future`. An event loop has a `run_until_complete` + method that takes a future and runs the event loop until the Future is set. + The idea is to be able to transition easily to asyncio when Python 2 + support can be dropped in the future. + > `Application` still has a method `run()` that underneath still runs the + event loop until the `Future` is set and returns that result. + > The asyncio adaptors (like the asyncio event loop integration) now require + Python 3.5. (We use the async/await syntax internally.) + > The `Input` and `Output` classes have some changes. (Not really important.) + > `Application.run_sub_applications` has been removed. The alternative is to + call `run_coroutine_in_terminal` which returns a `Future`. + * Changes to the `filters` module: + > The `Application` is no longer passed around, so both `CLIFilter` and + `SimpleFilter` were merged into `Filter`. `to_cli_filter` and + `to_simple_filter` became `to_filter`. + > All filters have been turned into functions. For instance, `IsDone` + became `is_done` and `HasCompletions` became `has_completions`. + This was done because almost all classes were called without any arguments + in the `__init__` causing additional braces everywhere. This means that + `HasCompletions()` has to be replaced by `has_completions` (without + parenthesis). + The few filters that took arguments as input, became functions, but still + have to be called with the given arguments. + For new filters, it is recommended to use the `@Condition` decorator, + rather then inheriting from `Filter`. + * Other renames: + > `IncrementalSearchDirection` was renamed to `SearchDirection`. + > The `use_alternate_screen` parameter has been renamed to `full_screen`. + > `Buffer.initial_document` was renamed to `Buffer.document`. + > `TokenListControl` has been renamed to `FormattedTextControl`. + > `Application.set_return_value` has been renamed to `Application.set_result`. + * Other new features: + > `DummyAutoSuggest` and `DynamicAutoSuggest` were added. + > `DummyClipboard` and `DynamicClipboard` were added. + > `DummyCompleter` and `DynamicCompleter` were added. + > `DummyHistory` and `DynamicHistory` was added. + > `to_container` and `to_window` utilities were added. + +------------------------------------------------------------------- +Fri Jul 27 07:07:38 UTC 2018 - jengelh@inai.de + +- Trim filler wording from descriptions. + +------------------------------------------------------------------- +Tue Jul 24 14:51:27 UTC 2018 - mcepl@suse.com + +- Downgrade back to 1.* line, 2.* breaks too many packages (all + jupyter-ipython ones, for example) + +------------------------------------------------------------------- +Sun Jul 22 17:30:56 UTC 2018 - arun@gmx.de + +- specfile: + * remove devel from noarch + * be more specific in %files section + +- update to version 2.0.4: + * Bug fixes: + + Fix render height for rendering full screen applications in + Windows. + + Fix in `TextArea`. Set `accept_handler` to `None` if not given. + + Go to the beginning of the next line when enter is pressed in Vi + navigation mode, and the buffer doesn't have an accept handler. + + Fix the `default` argument of the `prompt` function when called + multiple times. + + Display decomposed multiwidth characters correctly. + + Accept `history` in `prompt()` function again. + * Backwards incompatible changes: + + Renamed `PipeInput` to `PosixPipeInput`. Added `Win32PipeInput` + and `create_input_pipe`. + + Pass `buffer` argument to the `accept_handler` of `TextArea`. + * New features: + + Added `accept_default` argument to `prompt()`. + + Make it easier to change the body/title of a Frame/Dialog. + + Added `DynamicContainer`. + + Added `merge_completers` for merging multiple completers + together. + + Add vt100 data to key presses in Windows. + + Handle left/right key bindings in Vi block insert mode. + +------------------------------------------------------------------- +Sat Jul 14 19:15:07 UTC 2018 - arun@gmx.de + +- specfile: + * update copyright year + +- update to version 2.0.3: + * Bug fixes: + + Fix in 'x' and 'X' Vi key bindings. Correctly handle line + endings and args. + + Fixed off by one error in Vi line selection. + + Fixed bugs in Vi block selection. Correctly handle lines that + the selection doesn't cross. + + Python 2 bugfix. Handle str/unicode correctly. + + Handle option+left/right in iTerm. + +- changes from version 2.0.2: + * Bug fixes: + + Python 3.7 support: correctly handle StopIteration in + asynchronous generator. + + Fixed off-by-one bug in Vi visual block mode. + + Bugfix in TabsProcessor: handle situations when the cursor is at + the end of the line. + +- changes from version 2.0.1 + previous: + * long list of changelog, see CHANGELOG in tar-ball for details. + +------------------------------------------------------------------- +Fri May 18 17:53:31 UTC 2018 - toddrme2178@gmail.com + +- python-six also required for tests + +------------------------------------------------------------------- +Tue Sep 19 19:54:26 UTC 2017 - toddrme2178@gmail.com + +- Update to version 1.0.15 + + Fixes: + * Don't shuffle tasks in the event loop. This fixes an issue where lines + printed from background threads were printed in a different order if + `patch_stdout=True`. + * Only consider the text before the cursor when activating history search. + * Pressing escape should accept the search, this is closer to how readline works. + * Enable autowrap again when required. + + New features: + * Add run_in_terminal option to disable cooked mode. + +------------------------------------------------------------------- +Fri May 5 21:56:34 UTC 2017 - toddrme2178@gmail.com + +- Fix Provides/Obsoletes + +------------------------------------------------------------------- +Mon Apr 24 20:40:09 UTC 2017 - toddrme2178@gmail.com + +- Implement single-spec version. + +------------------------------------------------------------------- +Mon Apr 3 14:32:58 UTC 2017 - toddrme2178@gmail.com + +- Fix source URL. + +------------------------------------------------------------------- +Sat Apr 1 20:50:45 UTC 2017 - toddrme2178@gmail.com + +- Update to version 1.0.14 + + Rename package to python-prompt_toolkit + ~ Upstream name change + + See CHANGELOG file for changes + +------------------------------------------------------------------- +Mon Jan 30 21:25:56 UTC 2017 - rjschwei@suse.com + +- Update to version 1.0.9 (bsc#1002895, FATE#321630) + + Include in SLE 12 + + Rename package to python-python-prompt-toolkit + ~ Upstream name change + + See CHANGELOG file for changes + +------------------------------------------------------------------- +Fri Aug 14 09:14:13 UTC 2015 - toddrme2178@gmail.com + +- Initial version + + Version 0.46 diff --git a/python-prompt_toolkit.spec b/python-prompt_toolkit.spec new file mode 100644 index 0000000..2a70b7a --- /dev/null +++ b/python-prompt_toolkit.spec @@ -0,0 +1,65 @@ +# +# spec file for package python-prompt_toolkit +# +# Copyright (c) 2023 SUSE LLC +# +# All modifications and additions to the file contributed by third parties +# remain the property of their copyright owners, unless otherwise agreed +# upon. The license for this file, and modifications and additions to the +# file, is the same license as for the pristine package itself (unless the +# license for the pristine package is not an Open Source License, in which +# case the license is the MIT License). An "Open Source License" is a +# license that conforms to the Open Source Definition (Version 1.9) +# published by the Open Source Initiative. + +# Please submit bugfixes or comments via https://bugs.opensuse.org/ +# + + +%define skip_python2 1 +%{?sle15_python_module_pythons} +Name: python-prompt_toolkit +Version: 3.0.38 +Release: 0 +Summary: Library for building interactive command lines in Python +License: BSD-3-Clause +URL: https://github.com/prompt-toolkit/python-prompt-toolkit +Source: https://files.pythonhosted.org/packages/source/p/prompt_toolkit/prompt_toolkit-%{version}.tar.gz +BuildRequires: %{python_module base >= 3.7} +BuildRequires: %{python_module pip} +BuildRequires: %{python_module pytest} +BuildRequires: %{python_module setuptools} +BuildRequires: %{python_module wcwidth} +BuildRequires: %{python_module wheel} +BuildRequires: fdupes +BuildRequires: python-rpm-macros +Requires: python-wcwidth +Recommends: python-Pygments +Conflicts: python-prompt_toolkit1 +BuildArch: noarch +%python_subpackages + +%description +Prompt toolkit is a library for building interactive command +lines in Python. + +%prep +%setup -q -n prompt_toolkit-%{version} + +%build +%pyproject_wheel + +%install +%pyproject_install +%python_expand %fdupes %{buildroot}%{$python_sitelib} + +%check +%pytest + +%files %{python_files} +%license LICENSE +%doc AUTHORS.rst README.rst CHANGELOG +%{python_sitelib}/prompt_toolkit +%{python_sitelib}/prompt_toolkit-%{version}.dist-info + +%changelog