All Versions
6
Latest Version
Avg Release Cycle
54 days
Latest Release
1244 days ago

Changelog History

  • v1.0.7 Changes

    November 29, 2020

    ๐Ÿš€ Gooey 1.0.7 Released!

    ๐Ÿš€ Lots of new stuff this release! We've got 3 new widget types, new gooey_options, as well as some quality of Life improvements for using Gooey Options.

    ๐Ÿ†• New Widgets: IntegerField, DecimalField, and Slider

    ๐Ÿš€

    Gooey now has 3 inputs specifically geared towards accepting numeric inputs. Previously, all Gooey had were text fields which you could add validators to in order to enforce only numbers were entered, but now we have top level widgets which do all of that out of the box!

    Important Usage Note: since these numeric inputs don't allow any non-numeric characters to be entered, they do not give you the ability to blank them out. Unlike a TextField which can be left empty and thus have its value not passed to your program, the numeric inputs will always send a value. Thus, you have to have sane handling in user-land.

    ๐Ÿ“„ Checkout the Options docs for more details.

    ๐Ÿ†• New Gooey Options: placeholder

    ๐Ÿš€

    Widgets with text inputs now all accept a placeholder Gooey option.

    add\_argument('--foo', widget='TextField', gooey\_options=options.TextField( placeholder='Type some text here!')# or without the options helper add\_argument('--foo', widget='TextField', gooey\_options={ 'placeholder': 'Type some text here!'})
    

    ๐Ÿ†• New Validator option: RegexValidator

    add\_argument('--foo', widget='TextField', gooey\_options=options.TextField( placeholder='Type some text here!', validator=options.RegexValidator( test='\d{4}', message='Must be exactly 4 digits long!' ) )# or without the options helper add\_argument('--foo', widget='TextField', gooey\_options={ 'placeholder': 'Type some text here!', 'validator': { 'type': 'RegexValidator', 'test': '\d{4}', 'message': 'Must be exactly 4 digits long!' } })
    

    ๐Ÿ†• New feature: Options helpers

    Gooey now has a top-level options module which can be imported. Previously, Gooey Options have been an opaque map. While great for openness / extensibility, it's pretty terrible from a discoverability / "what does this actually take again..?" perspective. The new options module aims to make using gooey_options easier and more discoverable.

    from gooey import options
    

    ๐Ÿ“„ The goal is to enable IDE's to provide better auto-completion help as well as more REPL driven usefulness via help() and docstrings.

    from gooey import optionsparser.add\_argument( '--foo', help='Some foo thing', widget='FilterableDropdown', gooey\_options=options.FilterableDropdown( placeholder='Search for a Foo', search\_strategy=options.PrefixSearchStrategy( ignore\_case=True ) ))
    

    Note that these are just helpers for generating the right data shapes. They're still generating plain data behind the scenes and thus all existing gooey_options code remains 100% compatible.

    ๐Ÿ‘ Better Docs:

    Which is to say, documentation which actually exists rather than not exist. You can inspect the docs live in the REPL or by hopping to the symbol in editors which support such things.

    >>> from gooey import options 
    >>> help(options.RadioGroup) 
    Help on function FileChooser in module __main__ :
    
    FileChooser(wildcard=None, default_dir=None, default_file=None, message=None, **layout_options)
        :param wildcard: Sets the wildcard, which can contain multiple file types, for 
                         example: "BMP files (.bmp)|.bmp|GIF files (.gif)|.gif"
        :param message: Sets the message that will be displayed on the dialog.
        :param default_dir: The default directory selected when the dialog spawns 
        :param default_file: The default filename used in the dialog
    
        Layout Options:
        ---------------
    
        Color options can be passed either as a hex string ('#ff0000') or as
        a collection of RGB values (e.g. `[255, 0, 0]` or `(255, 0, 0)`)
    
        :param label_color: The foreground color of the label text
        :param label_bg_color: The background color of the label text.
        :param help_color: The foreground color of the help text.
        :param help_bg_color: The background color of the help text.
        :param error_color: The foreground color of the error text (when visible).
        :param error_bg_color: The background color of the error text (when visible).
        :param show_label: Toggles whether or not to display the label text
        :param show_help: Toggles whether or not to display the help text
        :param visible: Hides the entire widget when False. Note: the widget
                               is still present in the UI and will still send along any
                               default values that have been provided in code. This option
                               is here for when you want to hide certain advanced / dangerous
                               inputs from your GUI users.
        :param full_width: This is a layout hint for this widget. When True the widget
                               will fill the entire available space within a given row.
                               Otherwise, it will be sized based on the column rules
                               provided elsewhere. 
    

    Ideally, and eventually, we'll be able to completely type these options to increase visibility / usability even more. However, for backwards compatibility reasons, Gooey will continue to be sans anything more than the most basic of type hinting for the time being.

    ๐Ÿ’ฅ Breaking Changes

    No breaking API changes from 1.0.6 to 1.0.7. However, the strictness of existing Gooey Options has been increased, which could result in issues when upgrading from 1.0.6. In an attempt to be helpful, Gooey now throws an exception if invalid Gooey Options are supplied. This is to catch things like invalid types or ill-formed data. If you were passing bad data in 1.0.6, it will now be flagged as such in 1.0.7.

    ๐Ÿ‘ Thank you to the current Patreon supporters!

    • Sponsors:
      • Qteal
    • Individuals:
      • Joseph Rhodes
      • Nicholas
  • v1.0.6 Changes

    November 15, 2020

    ๐Ÿš€ Gooey 1.0.6 Released!

    ๐Ÿš€ This is a minor release beefing up the new FilterableDropdown's search capabilities and performance. In the previous release, the dropdown was backed by WX's ListBox widget. 1.0.6 replaces this for a fully virtualized version which allows Gooey to operate on massive datasets without taking a hit to UI performance. Additionally, how Gooey internally filters for matches has also been updated. Choice are now backed by a trie for super fast lookup even against large data sets. Tokenization and match strategies can be customized to support just about any lookup style.

    โšก๏ธ Head over to the Examples Repo to see the updated demo which now uses a datset consisting of about 25k unique items.

    ๐Ÿ†• New Gooey Options:

    FilterableDropdown now takes a search_strategy in its gooey_options.

    from gooey import Gooey, GooeyParser, PrefixTokenizersgooey\_options={ 'label\_color': (255, 100, 100), 'placeholder': 'Start typing to view suggestions', 'search\_strategy': { 'type': 'PrefixFilter', 'choice\_tokenizer': PrefixTokenizers.ENTIRE\_PHRASE, 'input\_tokenizer': PrefixTokenizers.REGEX('\s'), 'ignore\_case': True, 'operator': 'AND', 'index\_suffix': False } })
    

    This gives control over how the choices and user input get tokenized, as well as how those tokenized matches get treated (ANDed together vs ORd). Want to match on any part of any word? Enable the index_suffix option to index all of your candidate words by their individual parts. e.g.

    Word: 'Banana' 
    Suffixes: ['Banana', 'anana', 'nana', 'ana']
    

    These all get loaded into a trie for super fast lookup. Combine this with the WORDs tokenizer, and you get really fine grained search though your options!

    ๐Ÿ‘ Thank you to the current Patreon supporters!

    • Qteal
    • Joseph Rhodes

    ๐Ÿ’ฅ Breaking Changes

    No breaking changes from 1.0.5.

  • v1.0.5 Changes

    November 08, 2020

    ๐Ÿš€ Gooey 1.0.5 Released!

    Gooey is now using WX 4.1.0!

    This change should resolve several issues in Ubuntu as well as the numerous other quirks which have been reported.

    ๐Ÿ‘ Thank you to the current Patreon supporters!

    • Qteal
    • Joseph Rhodes

    ๐Ÿ†• New widgets:

    FilterableDropdown

    Filterable Dropdown

    ๐Ÿš€ You can checkout a runnable example in the GooeyExamples repo here

    Example Code:

    add\_argument( choices=['a', 'b', 'c'], widget='FilterableDropdown', gooey\_options={ 'no\_match': 'No results found!', 'placeholder': 'Type something!'})
    

    This introduces a new language translation key: "no_matches_found" to handle the case where the user's input doesn't match any of the choices. This is used by default, but can be overridden via gooey options

    Elapsed Time / Estimated time remaining

    fbHcpCAGD8

    @JackMcKew put in a herculean effort and introduced a new feature where elapsed and estimated remaining time can be shown in addition to the standard progress bar.

    You can checkout an example here

    Example Code:

    @Gooey(timing\_options={'show\_time\_remaining':True,'hide\_time\_remaining\_on\_complete':True})
    

    ๐Ÿ’ฅ Breaking Changes

    • (documentation breaking)terminal_font_weight's public documented API allowed the strings "NORMAL" and "BOLD" while its internal implementation relied on numeric font weights (light=200, normal=300, etc..). The documentation was updated to show the correct usage and a constants file was added to the public API.

    Functionality

    • ๐Ÿ”ง @neonbunny enabled Parsers to use configuration from parents.
    • โšก๏ธ @eladeyal-intel updated RichTextConsole to allow control+scrollwheel to zoom the text

    Language Additions / Improvements

    • ๐ŸŒ @soleil0-0 - Additional Chinese translation
    • ๐ŸŒ @dancergraham - Additional French translation
    • ๐ŸŒ @ajvirSingh1313 - Hindi translation

    ๐Ÿ› Bug Fixes

    • ๐Ÿ›  Fixed bug where dynamic updates to a Dropdown would cause the selection to be lost
    • ๐Ÿ›  Fixed performance issues where dynamic updates with large items would cause Gooey to hang
    • โšก๏ธ @rotu fixed a bug in dynamic updates related to Popen usage.
    • โš  @neonbunny - resolved warning cause by missing return statement
    • ๐Ÿ›  Fixed bug where terminal font and colors were not being set correctly
    • ๐Ÿ›  Fixed mysterious RadioGroup issue where underlying WxWidgets would 'forget' the current selection under certain circumstances
  • v1.0.4 Changes

    June 21, 2020

    ๐Ÿš€ Gooey 1.0.4 Released!

    Gooey picked up some cool new widget types thanks to awesome contributions from @NathanRichard and @conradhilley.

    ๐Ÿš€ The rest of this release was focused on bug fixes and quality improvements. My commitment is to having Gooey be a stable, reliable project. This has required slowly shedding it's fast and loose hobby project past. Test coverage more than doubled between 1.0.3 and 1.0.4 and several bugs were fixed along the way as a result of this. The next few releases of Gooey will be similarly focused on bringing its codebase up to snuff so that wider changes can be made without introducing unexpected regressions.

    โฌ†๏ธ Upgrading from 1.0.3 to 1.0.4

    ๐ŸŒ Translation notice! Yes/No options in confirmation modals are now backed by the language files. Previously, they were fixed to english regardless of the selected language. If the new language options aren't configured for your language, you will now see a translation request in the button label!

    What's new

    Widgets: TimeChooser

    ๐Ÿš€

    Usage:

    parser = GooeyParser()parser.add\_argument('--time', widget='TimeChooser')
    

    ๐Ÿ‘€ @NathanRichard added this one after an excellent deep dive into the complexities of dealing with time inside of WX. See the README for notes on usage.

    Widgets: ColourChooser

    ๐Ÿš€

    Usage:

    parser = GooeyParser()parser.add\_argument('--color', widget='ColourChooser')
    

    @conradhilley brought this one to life. You can now select colors from an awesome little chooser widget.

    0๏ธโƒฃ CLI based defaults

    @jschultz added the ability to use arguments passed on the command line as defaults in Gooey. Enable this functionality by passing use_cmd_args to the Gooey decorator.

    @Gooey(use\_cmd\_args=True)def main(): parser = ArgumentParser() parser.add\_argument('--foo')
    

    0๏ธโƒฃ Now any CLI args you pass when invoking your program will show up as defaults in Gooey.

    python my_program.py --foo "hello!" 
    

    โž• Additional features

    • โž• Added option to start Gooey in full screen mode

    Language Additions / Improvements

    • ๐Ÿ“š @foben - documentation fixes
    • ๐ŸŒ @gediz - turkish translations
    • ๐ŸŒ @dsardelic - bosnian & Croatian translations
    • ๐ŸŒ @partrita - Korean translations

    ๐Ÿ› Bug Fixes

    • ๐Ÿ’ป Main README image had a typo "Command Lines Applications"
    • Truthy values
    • ๐Ÿ›  Fixed bug where nargs in textfields weren't being mapped correctly
    • ๐Ÿ›  Fixed bug where argparse's SUPPRESS flag was showing in the UI
    • ๐Ÿ›  Fixed missing i18n capabilities in modals
    • ๐Ÿ›  Fixed bug where program_description wasn't being honored
    • ๐Ÿ›  Fixed bug where gooey_options weren't being honored in the Header
    • ๐Ÿ›  Fixed bug where RadioGroup wasn't enabling it's child widget when initial_selection was set
    • ๐Ÿ›  Fixed bug where checkboxes weren't honoring visibility options
    • ๐Ÿ›  Fixed bug where gooey_options weren't being passed to footer
  • v1.0.3 Changes

    September 22, 2019

    ๐Ÿš€ title card

    ๐Ÿš€ After cooking for far too long, Gooey 1.0.3 is released!

    โœ… Grab the latest version:

    โš™ Runnable demos for all the new features can be found in the Examples repo.

    Overview:

    ๐Ÿ“š A lot of focus was put on settling Gooey down into a more stable mature project. In addition to all of the new features, a lot of time was spent writing documentation, stamping down cross platform issues / quirks, and making numerous tweaks and additions to enable a smoother experience when packaging Gooey for distribution.

    What's new

    Fancy Layout controls!

    ๐Ÿš€ advanced layout

    ๐Ÿš€ The main goal of this release was enabling more complex real-world layouts and more customization of Gooey's UI. As of 1.1.0, you now have have control over every color, font, and display status within the application. You can now brand Gooey to your organization's colors, logically group related items under a central heading, and optionally show/hide all the individual components that make up an input widget.

    Menu Bars

    Gooey now includes a simple declarative system for creating top level menu bars and items.

    ๐Ÿš€ menu bar

    ๐Ÿ‘ The menu option currently supports three flavors:

    AboutDialog

    This is an AboutDialog as rendered natively by your OS. It's a good place to show standard info like version info, descriptions, licenses, etc.. in a standard way across platforms.

    ๐Ÿ”Š MessageDialogs

    ๐Ÿ”Š Next up are general message dialogs. You can display any informational text inside of these.

    ๐Ÿ”— Link

    ๐Ÿ“š Finally, you can create fixed menu items that simply link to external resources, for instance, your site, documentation, pdfs, etc..

    Rich Text Controls

    Thanks to @NathanRichard, Gooey can now optionally honor terminal control sequences and display Rich Text in the output panel.

    ๐Ÿš€ rich text

    ๐Ÿ†• New Gooey Program Icon

    ๐Ÿ†• New icon provided by professional cool guy and crazy talented UX designer Justin Rhee.

    โž• Additional features

    • OSX now shows program Icon in Dock
    • show_error_modal option to toggle whether or not failures additionally raise alert modals.
    • BlockCheckbox widget.
    • ๐Ÿ’ป Hyperlinks written to the console appear as such and will launch a browser on click
    • clear_before_run option lets you control whether or not subsequent program runs start from a fresh terminal or preserve the previous output.
    • Conditionally show/hide restart button
    • 0๏ธโƒฃ requires_shell option - controls how Popen spawns your program. By default (and historically), this value is False.
    • โšก๏ธ Optionally silence textual progress updates when using the Progress widget (via @conradhilley)
    • Multi-Directory Choosers - these were accidentally dropped from the project. @HenrykHaniewicz added them back!
    • โž• Additional explicit wx imports to make packaging on OSX easier
    • Textfields can now be made Readonly for informational purposes
    • better custom target support via suppress_gooey_flag which prevents the --ignore-gooey flag from being injected

    ๐Ÿ’ฅ Breaking Changes

    No breaking changes between 1.0.0 and 1.1.0!

    Language Additions / Improvements

    ๐ŸŒ Completed Italian translation - @gison93

    โšก๏ธ Updated French translation - @NathanRichard

    โšก๏ธ Updated Hebrew translation - @eturkes

    ๐Ÿ› Bug Fixes

    • ๐Ÿ›  Fixed 5 year old bug(!) where an errant lambda function wasn't passing through all of its arguments which caused frustratingly opaque failures under specific conditions.
    • ๐Ÿ›  Fixed bug where external updates weren't applied to ListBox
    • ๐Ÿ›  Fix bug where tuples weren't coerced to List which causes concatenation errors
    • Fixed bug where string coercion in argparse_to_json was too broad and caused type errors
    • ๐Ÿ›  Fixed bug where wrong validator was applied to Dropdown type causing preflight checks to always fail
    • ๐Ÿ›  Fixed bug where Radio Groups would apply too much vertical spacing between components
    • ๐Ÿ›  Fixed bug where subgroups with single items were attached to the wrong UI parent
    • ๐Ÿ›  Fixed bug where legacy default groups weren't being translated
    • ๐Ÿ›  Fixed bug where certain languages would sometimes cause components to be rendered off screen
  • v1.0.3.1 Changes

    April 25, 2020

    ๐Ÿš‘ This is a temporary hotfix downgrading the wxpython used by Gooey to 4.0.7.

    ๐Ÿš€ WxPython 4.10 introduced unexpected breaking changes. These changes caused Gooey to fail when starting up.

    ๐Ÿ‘€ If you are seeing errors such as this when running Gooey

    wx._core.wxAssertionError: C++ assertion "!(flags & wxALIGN_CENTRE_HORIZONTAL)" failed at ..\..\src\common\sizer.cpp(2106) in wxBoxSizer::DoInsert(): Horizontal alignment flags are ignored in horizontal sizers
    

    ๐Ÿš€ This release will resolve them.

    Longer term solution to follow pending additional research.