Skip to content

Releases: TexteaInc/funix

Funix 0.3.8

20 Mar 03:37
Compare
Choose a tag to compare

0.3.8 (2023-03-20)

Highlights

  • Support a new widget password, now you can use this widget to create a password input box;
  • Support type range in parameters, now you can use this type to create a int slider;
  • Use tuple for widget configuration now, example here:
from funix import funix


@funix(
    widgets = {"box": ("code", {"langauge": "python"})}
)
def test(box: str) -> str:
    return box
  • Added some basic built-in types, import theme by from funix.widget.builtin import *, you can read examples for more information;
  • You can use new_funix_type to define your own type now, no need to use widgets anymore;
  • Support file and media uploads, and the backend receives bytes (Funix does not store files locally). Likewise, the backend can return bytes (your return type should be Image or something like that).

Breaking Changes

  • Themes should now be defined using python script, instead of yaml;
  • Widget configuration should now use tuple, instead of str;

Bug Fixes

  • if dump_frontend_config cannot update the config, then use the user config (5925608)
  • widgets with config do not work with new_funix_type (e0e4b0c)
  • add hint type check in return result (92cb08a)
  • NSInternalInconsistencyException in macOS (f705500)
  • fix list return (965e556)
  • add __args__ check, fix bool default (2be75a4)
  • handle List[range], fix invalid widgets config with range type (c145203)
  • theme example (6cee215)

Features

  • support media preview in page (e298de8)
  • support file upload (7da5753)
  • support code input box (5bee2ca)
  • add a simple example for custom types (cad07d1)
  • support custom typing in theme (b9f651c)
  • add new_funix_type to define type and widget (eaae949)
  • support build-in types (87a2442)
  • use update to support default config (c783d46)
  • widgets with parameters as tuples (#59) (5863e08)
  • add discord link (7a759a8)
  • support range type (9e7d01d)
  • better port check, use ipaddress (8e00177)
  • update examples and minor UI change (18fff2c)
  • add password widget (a0f6fb7)

Performances

Documents

Merges

Funix 0.3.7

06 Mar 05:37
Compare
Choose a tag to compare

0.3.7 (2023-03-06)

Highlights

  • funix command is now available, no need to use python -m funix, just reinstall or upgrade from PyPi or GitHub to try it;
  • Improve the backend code, at least a little better looking than in the past :);
  • In argument_config, now supports tuple configuration;
  • Adjust the layout of the frontend: remove the <AppBar />, use <Fab /> instead, and adjust the zIndex of the <Footer /> so that it does not overlap with other elements;
  • Simply support all address like 0.0.0.0, so you can just use funix [module] to start the server;
  • Allow to use set_theme in scripts to add theme using Python data, no need to provide theme file URI or path.

Breaking Changes

  • For brevity, show_source_code is now renamed to show_source;
  • rename is now unnecessary, and any functions that conflict with Funix have to be resolved by the developer; instead, title is used to change the function display name;
  • For brevity and eliminating tautology, argument_label is renamed to label in argument_config;
  • For semantic correction, set_global_theme is renamed to set_default_theme when exported;
  • You can no longer pass the backend address via http://funix_server/?backend={backend}, if you need to customize the backend, please deploy the frontend by yourself and modify the backend address via settings.

Issues

Bug Fixes

  • multiple frontend optimizations (bc4f558)
  • frontend try backend, all addresses support (3c1691e)
  • correct handling label prop and support tuple in argument_config (6a27f54)
  • correct handling widget overwrite (700b732)
  • handle the case where module_name is none (b53cba1)
  • correct handling of cell results list (9aee092)
  • various small bug fixes and UI improvments; updated examples (13a63b4)
  • use \t to split sheet (#61) (90c3d47)
  • update examples and minor UI changes (ef677f5)
  • decorator widget parameters override theme widget configuration (00cee98)
  • add lineProps to solve visual issue of code wrapping (9812ec0)
  • replace raw_function_name with function_name (fce4ad4)
  • wrong path in OutputFiles (dcdb36d)
  • wrong type casting in dict and tuple (96e81a0)

Features

  • improve frontend and theme (important) (775c080)
  • add continous run button, currently disabled (2964787)
  • update command line messages (529d3e7)
  • remove rename and add title (ced7332)
  • add command script (84bd358)

Refactors

  • refine code to improve readability (8c35897)
  • rename show_source_code to show_source (e8dee3b)
  • use plac to parse argv (2d7c6ca)

Documents

  • update examples and minor change to frontend (a7e7701)
  • clean up examples (ff4cedc)
  • reorg example code (7adeaf1)
  • minor example change (898e5f5)
  • update README, with Intro video GIF (e140ab0)
  • remove updated API design in PDF (1c44bf4)
  • update theme example with more widgets; bugs pending (07b2d50)
  • update AI examples (ac34df3)
  • update AI examples (fc6591a)
  • update readme and example (c0ea4ac)

Merges

  • remove marks added during conflict resolving (9b58451)

Contributors

Funix 0.3.6

28 Feb 20:34
Compare
Choose a tag to compare

0.3.6 (2023-03-01)

Highlights

  • If the function response is longer than 300ms, the submit button will be disabled until the response is complete;
  • Add the show_source_code parameter, which allows developers to export their Python function code to the frontend for users to read (external imports, variables, etc. cannot be parsed);
  • Add the rename parameter to modify the name of the function on the frontend, in order to solve the problem of conflict between the function export API and Funix, for special characters you also need to use the path parameter;
  • A more beautiful error display, using alert instead of displaying the raw JSON directly;
  • Add a draggable element in the middle of the input and input panels to adjust the width of the panel;
  • Frontend and backend share the same port, but you can still access other people's backend services through your frontend.

Breaking Changes

  • For the Code hint type, the content attribute name is modified to code;
  • For types based on BasicFileType such as Images: e.g. single images use the Image type, multiple images should use the typing.List[Image] type;
  • In 0.3.5 (Because of my laziness, there is no release information at 0.3.5): Python 3.9 and below are no longer supported.

Bug Fixes

  • add TypeAlias (4f5c8cc)
  • remove 2d array conversion (da604a8)
  • allow elements to be reused in if_then (a479a27)
  • use typing.List[Image] instead of Images to support multiple images (eef284f)

Features

  • change the default front-end port to 3000 (5bf9809)
  • disable the submit button while waiting for response (7c653d0)
  • change response timeout to 300ms (4ebe261)
  • add show_source_code option (c77c640)
  • handle errors returned from backend (31cfaa5)
  • support optional argument (0df97a4)
  • add footer (37622ff)
  • modify footer style, text and add icons (92847e7)
  • modify the source section to be collapsible (bac67b7)
  • change width of input and output panels (e7b03eb)
  • adjust the width setting (26ddc63)
  • use the same port for frontend and backend (#60) (84920e0)
  • add rename parameter (27fcb8f)

Refactors

  • change content to code (20c7fdd)
  • decorator: replace __args__ with getattr (a83d06b)

Documents