Hi,
I have just released Brython version 3.2.7 and updated brython.info.
The main change in this release is performance improvement : thanks to various optimisations, the pystone test
runs 2.5 times faster than with the previous version. It is still 15
times slower than CPython, but it was hundreds of
times a few months ago, and I have a few ideas to make things better in the near future.
Another change is the implementation of list comprehensions and generator expressions, now using self-executing anonymous functions.
The complete changelog is below. Thanks to all contributors !
- Pierre
New features
============
- implement browser.select(selector) : alias for document.get(selector=...)
- implement element.closest(tagName) : return the first element with specified
tag name above element
- add and document html.SVG (dynamically create an SVG panel)
- add file package.json, so that Brython is referenced as an npm package
Implementation
==============
- change implementation of list comprehensions and generator expressions : now
translated into self-executing anonymous functions
- speed improvements :
. in argument parsing
. by reducing the calls to $B.get_class(obj)
. by cleaning the attributes .modules, .bound and .type of __BRYTHON__ after
a script is parsed
. by caching the result of method to_js()
- improvement of interaction with Javascript constructors (by caryoscelus)
- remove options passed to function brython() : CORS
- mention BrowserStack in the README file (they offer us an account)
- if a JS function returns undefined, the Brython wrapper returns None instead
of raising an exception
- add a --no-docs option to server.py to improve the developer experience (by
Kiko Correoso)
- change sys.argv to use option "args" passed to brython()
Bug fixes
=========
- raise TypeError when the object passed as a base class is not a class.
- fix bugs and change callback implementation in _ajax.js
- bug : setting function attribute __doc__
- a few names were leaking in the global Javascript namespace
- for a classmethod, the first argument is the class factory, not the class
dictionary
- bug with argument "args" of exception classes and instances
- bugs on dict implementation, detected by tests/unittests with test_dict.py
- fix some bad behaviour with webbrowser.py module (by Kiko Correoso)
- fix issue with absolute vlue of complex numbers (idem)
Issues
- #414 : Third party objects not working transparently
- #420 : Debug: Index out of range in elif reports the wrong line number
- #421 : string formatting bug
- #423 : str.islower() and str.isupper() when str does not contain alphabetic
characters
- #426 : SVG Demos not working
- #429 : JS functions cannot be used as decorators
- #433 : imaginary exponents are not handled correctly
- #434 : bug with obj[int] (get item associated with key = the built-in class
int)
Brython site
============
Demos
=====
- use DOMNode.closest() it in sort_table.html
Standard distribution
=====================
Documentation
=============
- change Ajax binding in read_file.md recipe : use req.bind("complete")
instead of req.on_complete
- fix bug in image path in read_text_from_imagemap.md recipe
- improve documentation of browser.timer.set_interval
- added extra info about options of the brython function
- fixes bug in documentation of the javascript module
- update documentation of function brython() (by Kiko Correoso)
- update docs to show the new server.py option usage (idem)
- update README.md about the use of rawgit (idem)
--
You received this message because you are subscribed to the Google Groups "brython" group.
To unsubscribe from this group and stop receiving emails from it, send an email to brython+u...@googlegroups.com.
To post to this group, send email to bry...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/brython/6096d48c-455e-46da-878c-d532f4c9ab77%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.