Age | Commit message (Collapse) | Author | |
---|---|---|---|
2017-08-20 | py/stream: seek: Consistently handle negative offset for SEEK_SET. | Paul Sokolovsky | |
Per POSIX, this is EINVAL, so raises OSError(EINVAL). | |||
2017-08-17 | extmod/modubinascii: Rewrite mod_binascii_a2b_base64. | Alex Robbins | |
This implementation ignores invalid characters in the input. This allows it to decode the output of b2a_base64, and also mimics the behavior of CPython. | |||
2017-08-17 | py/binary: Change internal bytearray typecode from 0 to 1. | Damien George | |
The value of 0 can't be used because otherwise mp_binary_get_size will let a null byte through as the type code (intepreted as byterray). This can lead to invalid type-specifier strings being let through without an error in the struct module, and even buffer overruns. | |||
2017-08-16 | extmod/modussl_mbedtls.c: Add ussl.getpeercert() method. | Eric Poulsen | |
Behaviour is as per CPython but only the binary form is implemented here. A test is included. | |||
2017-08-15 | py/binary.c: Fix bug when packing big-endian 'Q' values. | Bas van Sisseren | |
Without bugfix: struct.pack('>Q', 16) b'\x00\x00\x00\x10\x00\x00\x00\x00' With bugfix: struct.pack('>Q', 16) b'\x00\x00\x00\x00\x00\x00\x00\x10' | |||
2017-08-11 | py/modsys: Initial implementation of sys.getsizeof(). | Paul Sokolovsky | |
Implemented as a new MP_UNARY_OP. This patch adds support lists, dicts and instances. | |||
2017-08-09 | py/objstr: Raise an exception for wrong type on RHS of str binary op. | Damien George | |
The main case to catch is invalid types for the containment operator, of the form str.__contains__(non-str). | |||
2017-08-09 | py/objtuple: Allow to use inplace-multiplication operator on tuples. | Damien George | |
2017-07-31 | all: Use the name MicroPython consistently in comments | Alexander Steffen | |
There were several different spellings of MicroPython present in comments, when there should be only one. | |||
2017-07-25 | py: Implement raising a big-int to a negative power. | Damien George | |
Before this patch raising a big-int to a negative power would just return 0. Now it returns a floating-point number with the correct value. | |||
2017-07-21 | tests/basics/builtin_exec: Test various globals/locals args to exec(). | Tom Collins | |
2017-07-21 | tests: Rename exec1.py to builtin_exec.py. | Damien George | |
2017-07-20 | extmod/modussl_axtls: Allow to close ssl stream multiple times. | Paul Sokolovsky | |
Make sure that 2nd close has no effect and operations on closed streams are handled properly. | |||
2017-07-19 | all: Remove trailing spaces, per coding conventions. | Damien George | |
2017-07-09 | tests/cpydiff: Add case for str.ljust/rjust. | Paul Sokolovsky | |
2017-07-09 | tests/cpydiff/: Improve wording, add more workarounds. | Paul Sokolovsky | |
2017-07-09 | tests/cpydiff/core_class_supermultiple: Same cause as core_class_mro. | Paul Sokolovsky | |
2017-07-09 | tests/cpydiff/core_arguments: Move under Functions subsection. | Paul Sokolovsky | |
This is the last "orphan" case. | |||
2017-07-09 | tests/cpydiff/core_class_mro: Move under Classes, add workaround. | Paul Sokolovsky | |
2017-07-07 | py/objgenerator: Allow to hash generators and generator instances. | Damien George | |
Adds nothing to the code size, since it uses existing empty slots in the type structures. | |||
2017-07-05 | tests/cpydiff/modules_deque: Elaborate workaround. | Paul Sokolovsky | |
2017-07-05 | tests/basics: Add tests for arithmetic operators precedence. | Krzysztof Blazewicz | |
2017-07-04 | py/modmath: Check for zero division in log with 2 args. | Damien George | |
2017-07-03 | extmod/modubinascii: Add check for empty buffer passed to hexlify. | Damien George | |
Previous to this patch hexlify(b'', b':') would lead to a bad crash due to the computed length of the result being -1=0xffffffff. | |||
2017-07-01 | extmod/modure: If input string is bytes, return bytes results too. | Paul Sokolovsky | |
This applies to match.group() and split(). For ARM Thumb2, this increased code size by 12 bytes. | |||
2017-06-30 | tests/unix/extra_coverage: Add test for mp_vprintf with bad fmt spec. | Damien George | |
2017-06-29 | tests/basics/namedtuple1: Add test for creating with pos and kw args. | Damien George | |
2017-06-28 | tests/import: Update comment now that uPy raises correct exception. | Damien George | |
2017-06-28 | tests/import: Add a test for the builtin __import__ function. | Damien George | |
2017-06-26 | tests: Auto detect floating point capabilites of the target. | Damien George | |
The floating-point precision of the target is detected (0, 30, 32 or 64) and only those tests which can run on the target will be run. | |||
2017-06-23 | tests/connect_nonblock: Refactor towards real net_hosted test. | Paul Sokolovsky | |
In the future, a special runner for such tests will import each test and call test() function with an address of test server to use. | |||
2017-06-23 | tests/net_inet: Move tests which don't require full Internet to net_hosted. | Paul Sokolovsky | |
The idea is that these tests can be run with just a test server running on a test host, with device under test connecting to it, instead of requiring Internet connection for testing. Such setup is however WIP, and some tests in net_hosted/ are so far written to connect to Internet, as there're not test server written yet. This is expected to evolve over time. | |||
2017-06-22 | tests/basics: Add tests for for-else statement. | Damien George | |
2017-06-21 | tests/net_inet: Add tests for accept and connect in nonblocking mode. | Damien George | |
Some of these tests don't require an Internet connection, but here is a good place to put them for now. | |||
2017-06-21 | tests/net_inet/test_tls_sites.py: Integration test for SSL connections. | Paul Sokolovsky | |
This attempts to bootstrap network tests for MicroPython. This commits sets test/net_inet/ as place for tests which require access to wide Internet. They aren't intended to be run as part of the main testsuite, instead to be run manually on demand. test_tls_sites.py in particular check that it's possible to establish SSL/TLS connection to select sites on the Internet: few references ones, plus those for which problems were reported, and resolved. | |||
2017-06-15 | py/objint: In to_bytes(), allow length arg to be any int and check sign. | Damien George | |
2017-06-15 | py/objint: Support "big" byte-order in int.to_bytes(). | Damien George | |
2017-06-14 | py/compile: Raise SyntaxError if positional args are given after */**. | Damien George | |
In CPython 3.4 this raises a SyntaxError. In CPython 3.5+ having a positional after * is allowed but uPy has the wrong semantics and passes the arguments in the incorrect order. To prevent incorrect use of a function going unnoticed it is important to raise the SyntaxError in uPy, until the behaviour is fixed to follow CPython 3.5+. | |||
2017-06-14 | py/modthread: Raise RuntimeError in release() if lock is not acquired. | Damien George | |
2017-06-13 | py/formatfloat: Fix number of digits and exponent sign when rounding. | Damien George | |
This patch fixes 2 things when printing a floating-point number that requires rounding up of the mantissa: - retain the correct precision; eg 0.99 becomes 1.0, not 1.00 - if the exponent goes from -1 to 0 then render it as +0, not -0 | |||
2017-06-11 | tests/extmod/vfs_basic: Allow test to pass on embedded targets. | Damien George | |
2017-06-10 | tests: Convert remaining "sys.exit()" to "raise SystemExit". | Paul Sokolovsky | |
2017-06-10 | tests/basics: Convert "sys.exit()" to "raise SystemExit". | Paul Sokolovsky | |
2017-06-09 | py/objstringio: If created from immutable object, follow copy on write policy. | Paul Sokolovsky | |
Don't create copy of immutable object's contents until .write() is called on BytesIO. | |||
2017-06-08 | tests/float/builtin_float_minmax: PEP8 fixes. | Paul Sokolovsky | |
2017-06-08 | tests/float: Convert "sys.exit()" to "raise SystemExit". | Damien George | |
The latter is shorter and simpler because it doesn't require importing the sys module. | |||
2017-06-07 | extmod/vfs: Allow to statvfs the root directory. | Damien George | |
2017-06-02 | tests/basics/string_rsplit: Add tests for negative "maxsplit" argument. | Damien George | |
2017-05-29 | various: Spelling fixes | Ville Skyttä | |
2017-05-25 | tests/basics: Add more tests for unwind jumps from within a try-finally. | Damien George | |
These tests excercise cases that are fixed by the previous two commits. |