Brian Warner
66e227ee61
Merge branch 'tox-nodilate'
2019-02-10 11:17:15 -08:00
Brian Warner
41129faca5
travis: run flake8less, not the full flake8
2019-02-10 11:10:39 -08:00
Brian Warner
31de77a875
travis: py37 should no longer require sudo
...
(once upon a time, sudo:true was necessary to get onto a GCE instance, which
has xenail which has py37)
2019-02-10 11:08:00 -08:00
Brian Warner
b65678e5d2
travis: mark FLAKE8 build with an env
2019-02-10 11:07:43 -08:00
Brian Warner
42d849fe52
tox/travis: improve nodilate testing
...
'tox' run locally should only exercise sensible combinations (py27-nodilate,
py34-nodilate, py35/36/37 with dilate). Travis will run exactly these by
using a different script for each version of python. Also added a separate
flake8 builder (which uses a small subset of warnings, as the default set is
currently much too noisy).
2019-02-10 11:02:15 -08:00
Brian Warner
ddba0fc840
Merge branch 'dilate-5'
...
This adds (but does not enable/expose) the low-level code for the new
Dilation protocol (refs #312 ). The spec and docs are done, the unit tests
pass (with full branch coverage).
The next step is to write some higher-level integration tests, which use a
fake/short-circuited mailbox connection (Manager.send) but real localhost TCP
sockets.
Then we need to figure out backwards compatibility with non-dilation-capable
versions. I've got a table in my notes, I'll add it to the ticket.
2018-12-24 23:23:16 -05:00
Brian Warner
803aa07f35
travis: don't test dilation on py3.4 either
2018-12-24 23:00:00 -05:00
Brian Warner
942a04952f
try to fix travis again
...
add a new tox target "no-dilate" to use on py2.7, and use "coverage"
everywhere else
2018-12-24 22:54:01 -05:00
Brian Warner
061ff98383
fix travis
...
don't run all of tox, just a single environment that uses the default
python (selected by travis)
2018-12-24 14:59:13 -05:00
Brian Warner
937a7d93e8
tox: only run coverage on py3.7
...
tox/coverage doesn't know to avoid the "dilate" extra, so it fails on py2.7
and py3.4
2018-12-24 14:49:25 -05:00
Brian Warner
b01f48ad88
tox: test dilation on py3, but not on py2
2018-12-24 14:37:19 -05:00
Brian Warner
4083beeb6c
wormhole.py: disable dilate() API until ready
...
more importantly, turn off the "we can do Dilation" advertisement for now,
since we really can't
2018-12-24 14:34:02 -05:00
Brian Warner
69bab3d814
docs/api: minor fixes
2018-12-24 14:33:41 -05:00
Brian Warner
b0db8add2a
travis: stop allowing failures on py2.7 and py3.7
...
py2.7 now works
py3.7 is now supported by travis
2018-12-24 00:19:58 -05:00
Brian Warner
96f52b931d
drop support for py33
...
current pkg_resources requires py3.4 or newer (or py27)
txtorcon appears to work on py3.4 again, so remove it from allow_failures
2018-12-24 00:16:36 -05:00
Brian Warner
29c269ac8d
get tests to work on py2.7
...
only install 'noiseprotocol' (which is necessary for dilation to work) if the
"dilate" feature is requested (e.g. `pip install magic-wormhole[dilate]`)
2018-12-24 00:07:06 -05:00
Brian Warner
a458fe9ab9
finish test coverage/fixes for connector.py
2018-12-23 15:23:27 -05:00
Brian Warner
6ad6f8f40f
test and fix half of connector.py
...
still to do:
* relay delays
* connection race
* cancellation of losing connections
* shutdown of all connections when abandoned
2018-12-23 15:23:27 -05:00
Brian Warner
e7cb1df785
factor out HKDF
2018-12-23 15:23:27 -05:00
Brian Warner
b4c90b40a2
move parse_hint/encode_hint into _hints.py, add tests
2018-12-23 15:23:27 -05:00
Brian Warner
d64c94a1dc
test_hints: finish coverage of hints.py
2018-12-23 15:23:27 -05:00
Brian Warner
1bb5634d0e
factor Hints tests out of test_transit into a new file
2018-12-23 15:23:27 -05:00
Brian Warner
7720312c8f
factor out parse_tcp_v1_hint
2018-12-23 15:23:27 -05:00
Brian Warner
2f4e4d3031
factor out describe_hint_obj and endpoint_from_hint_obj
2018-12-23 15:23:27 -05:00
Brian Warner
bd1a199f3e
start factoring Hints out to separate file
...
shared between old transit.py and new _dilation/connector.py
2018-12-23 15:23:27 -05:00
Brian Warner
3b7c9831f6
appease flake8 somewhat
2018-12-23 15:23:27 -05:00
Brian Warner
40dadfeb71
finish fixing/testing manager.py
2018-12-23 15:23:27 -05:00
Brian Warner
e55787c693
get most of Manager working and tested
...
still need to test the subchannel interfaces, and ping/pong/kcm
2018-12-23 15:23:27 -05:00
Brian Warner
e19c7d1281
typos/cleanups in docs/dilation-protocol.md
2018-12-23 15:23:27 -05:00
Brian Warner
dd8bff30f2
remove old-follower.py, flake8 still sees it
...
and doesn't like what it sees
2018-12-23 15:23:27 -05:00
Brian Warner
78358358bc
manager: hush flake8
2018-12-23 15:23:27 -05:00
Brian Warner
7084cbcb6f
test_manager: fix
2018-12-23 15:23:27 -05:00
Brian Warner
a4234cdecf
test_machines: fix for change to got_wormhole_versions
2018-12-23 15:23:27 -05:00
Brian Warner
8a1a8b1f9c
manager: factor out make_side for testing and override
2018-12-23 15:23:27 -05:00
Brian Warner
7e168b819e
manager: clean up versions, merge state machines
2018-12-23 15:23:27 -05:00
Brian Warner
d4a551c6b8
boss: remove sides from call to D.got_wormhole_versions()
2018-12-23 15:23:27 -05:00
Brian Warner
ec5df72cd3
more protocol docs updates
2018-12-23 15:23:27 -05:00
Brian Warner
74e5d9948b
move old-follower.py out of src, kept for temporary reference
2018-12-23 15:23:27 -05:00
Brian Warner
a594a85427
Revert "Boss/Receive: add 'side' to got_message"
...
This reverts commit 1fece5701c9de5e470526d2e7e9cfd7b461977e0.
2018-12-23 15:23:27 -05:00
Brian Warner
d4c9210a4e
more docs updates
2018-12-23 15:23:27 -05:00
Brian Warner
72c9683cdf
dilation-protocol.md: update for new PLEASE+PLEASE approach
2018-12-23 15:23:27 -05:00
Brian Warner
5dca0542eb
travis: tolerate py3.4 failure because of txtorcon bug
...
https://github.com/meejah/txtorcon/issues/306
2018-12-23 15:23:27 -05:00
Brian Warner
d65fcaa1a6
more flake8 fixes
2018-12-23 15:22:57 -05:00
Brian Warner
48d740406b
setup.cfg: bump flake8 max-line-length to 85
2018-12-23 15:22:57 -05:00
Brian Warner
5f61531445
more flake8 fixes, in wormhole.py and _interfaces.py
2018-12-23 15:22:57 -05:00
Brian Warner
bf0c93eddc
more flake8 fixes
2018-12-23 15:22:57 -05:00
Brian Warner
ea35e570a2
setup.cfg: bump flake8 max-line-length to 84
2018-12-23 15:22:57 -05:00
Brian Warner
05900bd08b
fix some flake8 complaints
2018-12-23 15:22:57 -05:00
Brian Warner
39666f3fed
travis: tolerate failures in py2.7, 'noiseprotocol' dep is py3-only
2018-12-23 15:22:57 -05:00
Brian Warner
34686a346a
add dilation code
...
(this compresses several months of false starts and rearchitecting)
2018-12-23 15:21:08 -05:00