Releases: brython-dev/brython
Brython-3.9.5
This version is published mainly to fix an issue that broke the interactive interpreter (#1699).
Brython-3.9.4
Main new features in this version:
- tokenisation of Python code is now compliant with the standard CPython API, with tokens similar to those produced by CPython tokenize module. Rewriting of
py2js.js
to use these tokens, produced in new scriptpython_tokenizer.js
- improvements to module browser.ajax + support of binary mode for the built-in function
open()
- rewriting of many special methods for operations (
__add__()
etc.) on built-in types for better compliance with CPython
Brython-3.9.3
This release fixes a critical bug on iOS.
Brython-3.9.2
The main new feature is a rewriting of the re
module. The previous version used a pure-Python version of the CPython module _sre
; it took a long time to import and was slow on execution. The new module (libs/python_re.js
) loads immediately and its execution is much faster (at least 30 times), although still much slower than the CPython module.
The version also introduces a change in the implementation of strings with code points adressable with more than 2 bytes ("surrogate pairs").
Brython-3.9.1
The main new feature is the implementation of the warnings API.
Other important changes:
- many modules from the CPython standard library have been upgraded to 3.9.
- bug fixes in the
math
andcmath
modules; all the tests in Lib/test/test_cmath.py pass - rewriting of the import mechanism, more compliant with the specification (finders, loaders, module specs etc.)
- support of Unicode escapes in strings (\u0000 etc.) and of identifier names with characters represented by surrogate pairs (eg 𝔘𝔫𝔦𝔠𝔬𝔡)
The option of function brython()
to specify the scripts that should be run is now documented as ids (ipy_id is kept for compatibility).
Brython-3.9.0
Apart from a couple of bug fixes, this release is compliant with Python 3.9, published yesterday: implementation of all the PEPs that are relevant for Brython + update of the standard library.
Brython-3.8.10
The main features in this release are:
- a complete rewriting of the implementation of generators. The first versions of Brython were written at a time when Javascript didn't have generators, the implementation was difficult to maintain. This release uses the Javascript "yield" keyword. Note that asynchronous generator are not supported in old versions of Microsoft Edge (they raise a
SyntaxError
for Javascript's "async function*()") - a rewriting of the interface with Javascript objects, mostly in the script
js_objects.js
- the module
json
, previously based on a slow pure-Python package, is replaced by a much faster Javascript version
Brython-3.8.9
The main features in this version are the inclusion of a module interpreter
to open a Python interpreter, and the use of modules dialog
and menu
in package browser.widgets
in demos and documentation.
The CPython brython package can now be used by brython-cli
instead of python -m brython
.
Brython-3.8.8
The main feature in this release is the support of tracing functions, such as set with sys.settrace()
, allowing the support of the Python debugger (pdb
) and of the breakpoint()
built-in function.
Many bugs in this release were discovered when trying to run the sympy
package, which is now supported, although not really usable (it imports too many modules).
Brython-3.8.7
The main changes in this version are:
- the introduction of a Brython tutorial on the web site
- a rewriting of dict implementation to preserve insertion order
- the introduction of the trace function (with
sys.settrace()
), preliminary work to support the Python debugger