Paul Sokolovsky
13b56c262a
socket: accept(): Fully decode peer address using inet_ntop().
2016-01-11 15:05:25 +02:00
Paul Sokolovsky
f1533338ea
socket: Return partially decoded peer address from .accept().
...
Full decoding requires implementing socket.inet_ntop().
2016-01-11 02:40:38 +02:00
Paul Sokolovsky
6f7bed1c53
uasyncio: test_http_server_heavy.py: Comment out mem_info() call.
2016-01-11 00:07:43 +02:00
Paul Sokolovsky
86692631c1
uasyncio: Add missing Boom HTTP testing tool support script.
2016-01-10 23:39:40 +02:00
Paul Sokolovsky
4e34fe928a
os: Release 0.4.
2015-12-24 00:36:37 +02:00
Paul Sokolovsky
f815a2a9f0
os: Proactively filter all str/bytes variants of "."/"..".
2015-12-24 00:35:57 +02:00
Paul Sokolovsky
eb0981496a
os: makedirs(): Rewrite to rely only on uos.mkdir().
2015-12-22 00:23:43 +02:00
Paul Sokolovsky
69ab21b6fc
os: Use uos.ilistdir() if available.
2015-12-20 00:44:13 +02:00
Paul Sokolovsky
217bb5fd33
os: Work if "ffi" module is not available (provide wrappers for "uos").
2015-12-19 00:12:55 +02:00
Paul Sokolovsky
d7bdde8820
os: Implement kill().
2015-12-19 00:10:55 +02:00
Paul Sokolovsky
2b616b11e3
ffilib: Don't fail if "ffi" module not present, just return None.
2015-12-18 20:21:17 +02:00
Paul Sokolovsky
120b52c132
os: Use uctypes.bytes_at() instead of ffi module.
2015-12-17 00:56:05 +02:00
Paul Sokolovsky
db1b0ef816
os: Rely on uos.errno() to manipulate errno.
...
FFI implementation is pretty hacky and not portable/scalable. So, just
have hard requirement on uos.errno().
2015-12-16 19:31:28 +02:00
Paul Sokolovsky
76efae4aaa
os: Move constants definitions to the top.
2015-12-15 00:11:05 +02:00
Paul Sokolovsky
8884dbbee5
os: Refactor ilistdir() to be compatible with builtin uos.ilistdir().
2015-12-15 00:05:49 +02:00
Paul Sokolovsky
e9648dad01
uasyncio: Release 0.9.
2015-12-13 01:55:06 +02:00
Paul Sokolovsky
8a32b1b38b
uasyncio.core: Release 0.9.
2015-12-13 01:46:53 +02:00
Paul Sokolovsky
5e10ef8adf
uasyncio: Switch to builtin uselect.poll() object.
...
This is a big step towards supporting uasyncio on baremetal builds (and
on unix builds without FFI support).
2015-12-13 01:46:05 +02:00
Paul Sokolovsky
14e945f1a3
upip: Builtin module was renamed to "uos" (consistent with stmhal, etc.)
2015-12-12 00:17:42 +02:00
Paul Sokolovsky
7eb1fbdf35
os: Builtin module was renamed to "uos" (consistent with stmhal, etc.)
2015-12-12 00:16:37 +02:00
Paul Sokolovsky
c60ff8125b
uasyncio.core: Avoid wrapping coroutines to lambdas for add_reader/writer.
...
add_reader/writer default behavior is to schedule "callback" on I/O
completion via call_soon(), there's no need to have lambda for that.
2015-12-12 00:12:19 +02:00
Paul Sokolovsky
b4b19f1dce
uasyncio: Schedule simple I/O completion callbacks directly in event loop.
...
Simple == without args. This is expected action for them, and saves creation
of lambda just for that. Actually, probably all callbacks should be handled
this way.
2015-12-11 22:53:29 +02:00
Paul Sokolovsky
7cd53c8bf8
uasyncio: IORead/IOWrite syscalls don't return anything.
...
Their semantics is "wait for I/O of given type on object passed as argument",
so return value would be the same as argument, and thus no need to bother
to store/pass it around.
2015-12-10 00:29:10 +02:00
Paul Sokolovsky
10a14f051c
itertools: Release 0.2.1.
2015-12-10 00:06:01 +02:00
Michael Buesch
5396b3010d
os.path: Add sep
...
We only support unix compatible '/'
2015-12-10 00:01:02 +02:00
pohmelie
5477729d50
itertools: Add starmap function
2015-12-09 23:59:21 +02:00
Paul Sokolovsky
460dd59b16
uasyncio.core: Don't pass any callback args to add_reader/add_writer.
...
Instead, capture all needed param in closure. Due do bug in MicroPython's
handling of default args to lambdas, helper function is used.
2015-12-09 00:40:04 +02:00
Michael Buesch
ff27e3c8ba
socket: Add socket.error
...
Older CPython versions raised socker.error (or classes derived from it)
as exceptions on errors. Various software still uses it to be compatible
with older Python versions. As it's one-line fix, allow MicroPython to
run such code too.
try:
socket...
except socker.error as e:
...
2015-12-09 00:34:48 +02:00
Paul Sokolovsky
17d96d35b5
uasyncio: Optimize reader/writer callbacks with no arguments.
...
Avoids allocating tuples.
2015-12-07 01:13:00 +02:00
Michael Buesch
18c9084a27
functools: Add very simple implementation of reduce()
...
The implementation was taken from
https://docs.python.org/3/library/functools.html
2015-12-05 22:24:08 +02:00
Paul Sokolovsky
f9eed2340d
uasyncio.core: Optimize for syscalls with single args.
...
Avoids allocating argument tuples.
2015-12-05 22:23:10 +02:00
Michael Buesch
4f36827a6c
__future__: Add dummies for all available feature descriptions
...
This will make statements such as
from __future__ import division
not fail.
2015-12-05 22:13:12 +02:00
Paul Sokolovsky
b6d9dd67d5
collections.deque: Add extend() method.
2015-12-03 00:36:07 +02:00
Paul Sokolovsky
fdcf1aad99
socket: Release 0.3.2.
2015-12-01 19:05:46 +02:00
Paul Sokolovsky
5c2e0becfc
socket: Support "" as host addr, meaning INADDR_ANY (0.0.0.0).
2015-12-01 19:05:30 +02:00
Paul Sokolovsky
9643541e6e
urllib.urequest: Release 0.1.
2015-11-21 02:25:56 +02:00
Paul Sokolovsky
de50429b1a
urllib.urequest: Add absolutely minimal urlopen() implementation.
...
Optimized for low-memory bare-metal systems.
2015-11-21 02:25:31 +02:00
Paul Sokolovsky
bba8fb1032
urllib.parse: Requires collections.defaultdict class.
2015-11-16 18:47:58 +02:00
Paul Sokolovsky
38b6f615d8
upip: Release 0.6.2.
2015-11-15 00:11:56 +02:00
Nico
cd1fea8798
upip: MaxOSX mkdir("/") returns EISDIR, and not EEXIST.
...
Unlike Linux, which return EEXIST. This MacOSX behavior is not documented
in the official documentation:
https://developer.apple.com/library/mac/documentation/Darwin/Reference/ManPages/man2/mkdir.2.html
(EISDIR isn't described as possible error for mkdir()!), but other projects
had to apply similar workarounds, e.g.:
https://github.com/janestreet/core/issues/7 . The issue appear to happen
only for root directory path, but workaround is applied conservatively
just in case.
2015-11-15 00:10:30 +02:00
Paul Sokolovsky
4b2d7e91ff
upip: Workaround _os.getenv() accepting only 1 argument.
2015-11-14 17:51:55 +02:00
Paul Sokolovsky
bd37778efb
upip: Get rid of FFI dependency, use builtin _os module instead.
...
Also, delete as many as possible other dependencies (needed functions
are just copied into codebase). This will allow to work on static
MicroPython builds (including being a first step to support bare-metal
ports).
2015-11-14 00:02:10 +02:00
Delio Brignoli
1773bc0788
contextlib: modify TestExitStack to work in uPy
2015-11-04 00:27:03 +03:00
Delio Brignoli
b9f3b49e2e
contextlib: add TestExitStack from CPython 3.4
2015-11-04 00:27:03 +03:00
Delio Brignoli
5fd99fe680
contextlib: modify ExitStack to work in uPy
2015-11-04 00:27:03 +03:00
Delio Brignoli
e41f5da1ea
contextlib: re-instate ExitStack from CPython 3.4
2015-11-01 15:41:51 +01:00
Delio Brignoli
1260289917
unittest: add assertIsNone() and assertIsNotNone() methods to TestCase
2015-11-01 17:01:58 +03:00
Paul Sokolovsky
711eba3a7e
argparse: Release 0.3.1.
2015-10-22 20:52:57 +03:00
Delio Brignoli
680364d20c
contextlib: depend on ucontextlib and fix tests
2015-10-22 20:48:43 +03:00
Delio Brignoli
de39c2417c
ucontextlib: spin off minimal module from contextlib
2015-10-22 20:47:22 +03:00