Commit Graph

6707 Commits

Author SHA1 Message Date
meejah
4ed2fb725a Fix call to ready() 2016-07-21 12:35:59 -07:00
Daira Hopwood
31ab5cf4ed Correct a string-type error.
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2016-07-21 12:35:59 -07:00
Daira Hopwood
e03a1e3361 WIP.
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2016-07-21 12:35:59 -07:00
Daira Hopwood
262e238a7d Magic Folder file moves.
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2016-07-21 12:35:59 -07:00
Daira Hopwood
3170cab0fc Prepare to move drop_upload.py to magic_folder.py.
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2016-07-21 12:35:59 -07:00
Daira Hopwood
76a178969d Move backupdb.py to src/allmydata.
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2016-07-21 12:35:59 -07:00
Daira Hopwood
976c89d2e4 Rename upload_ready_d to connected_enough_d.
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2016-07-21 12:35:59 -07:00
Daira Hopwood
1495d0f405 Documentation changes for Magic Folder.
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2016-07-21 12:35:59 -07:00
Daira Hopwood
5f143f7635 Enable Windows inotify support.
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2016-07-21 12:35:59 -07:00
Daira Hopwood
e7fb665e06 New code for Windows drop-upload support. refs #1431
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2016-07-21 12:35:59 -07:00
Daira Hopwood
54371547db Docs for drop-upload on Windows.
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2016-07-21 12:35:59 -07:00
Daira Hopwood
61b3a9cef2 Add magic folder db.
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2016-07-21 12:35:59 -07:00
Daira Hopwood
7b4067850f Unicode path fixes for drop-upload.
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2016-07-21 12:35:59 -07:00
Brian Warner
b6dedc6223 clean up got_static_announcement() call 2016-07-19 17:31:43 -07:00
Brian Warner
2c5f7ed425 factor out yamlutil.py
The yaml.SafeLoader.add_constructor() should probably only be done once,
and moving this all into a module gives us an opportunity to test it
directly.
2016-07-19 17:31:41 -07:00
Brian Warner
fa28ed0730 tox: add pyflakes, which was accidentally removed from CI 2016-07-19 17:30:50 -07:00
Brian Warner
9c1e22209f client.py: add missing import, fix wrong name
Without these, clients with a non-empty connections.yaml would crash as
they start up. It's safe to say we need some tests for this :-).

pyflakes catches all of these, but it got accidentally disabled
recently, so travis wasn't running it. I'll fix that in the next commit.
2016-07-19 17:30:45 -07:00
Daira Hopwood
02362ae52c github does not render :doc: links; make sure that the links work there.
Signed-off-by: Daira Hopwood <daira@jacaranda.org>
2016-07-15 15:38:52 +01:00
David Stainton
9063106f3a Change 'servers' sections of connections.yaml to support new design in #2788 2016-07-12 17:44:21 +01:00
David Stainton
a67e7c0db9 Remove old self.testing reference and conditional 2016-07-12 17:44:21 +01:00
David Stainton
e4d93a745c Load static server configuration from connections.yaml 2016-07-12 17:44:21 +01:00
Daira Hopwood
30df8667eb Merge pull request #299 from zooko/master
remove configuration which causes "python setup.py test" to run all t…
2016-07-12 17:28:37 +01:00
Zooko
f300801226 remove configuration which causes "python setup.py test" to run all the files in src/allmydata/test 2016-07-12 13:57:30 +00:00
Brian Warner
64a7c687a6 expenses: pay hosting through May-2016 2016-07-08 13:17:41 -07:00
Brian Warner
de90ae16a4 expenses: pay DNS, TLS 2016-07-08 12:48:26 -07:00
Brian Warner
4b035c17f2 donations.rst: add new expense addresses, resign
Also adds docs/expenses.rst (unsigned) to record individual expenses and
the transactions used to pay them.
2016-07-08 12:18:26 -07:00
Brian Warner
6a35cf2752 Merge branch 'pr294': split control/log to new Tubs
closes tahoe-lafs#294
2016-07-06 21:09:47 -07:00
Brian Warner
7d692d0afd Split control and log to two separate tubs, remove control knobs.
This also removes the tahoe.cfg keys that would have configured the
control-port. And it deletes the logport.furl file before asking the Tub
to re-create it, because we're now using an ephemeral Tub (so we're not
persisting the private key, so the tubid will change each time).

closes ticket:2794
2016-07-06 21:09:35 -07:00
David Stainton
e5ffbdbcdf Move control/logging to a separate Tub 2016-07-06 21:09:35 -07:00
Brian Warner
3402f75454 copy fixed allocate_tcp_port() from foolscap
The old copy had a bug which occasionally returns a port that was
actually in use, causing intermittent test failures (when large numbers
of ports were allocated). I finally figured out how to fix it in
Foolscap, so this is just a copy of the updated function.

closes ticket:2795
2016-07-06 19:20:32 -07:00
Brian Warner
7407e7c8cf Merge branch 'pr285': add travis OS-X coverage 2016-07-06 02:08:27 -07:00
Brian Warner
5bf7fab99d travis: big cleanup, make it work on OS-X
Travis defaults to giving us an OS-X 10.9 box, which has an OpenSSL that
is too old for the current cryptography-1.4 (note that a previous
version of this branch worked, but only because the previous
cryptography-1.3.x didn't enforce the OpenSSL version).

On OS-X, this new .travis.yml does the following:

* set "osx_image: xcode7" to get us 10.10, with newer OpenSSL
* uses system python, not homebrew
* installs pip with get-pip.py, since system python doesn't have it
* adds the --user directory to $PATH, since OS-X python doesn't have it
  by default

On both linux and OS-X, this:

* installs tox and coveralls with --user, not to the system
* doesn't use sudo to run tox
* prints some extra debug info in case it's useful later

Closes #285
2016-07-06 02:05:43 -07:00
David Stainton
7e10b5d0e5 Corrections to .travis.yml from Brian's review 2016-07-06 02:00:41 -07:00
David Stainton
73c4aa727f wtf sudo tox for linux 2016-07-06 02:00:41 -07:00
David Stainton
8a374df8b1 Make travis test on osx and linux both 2016-07-06 02:00:41 -07:00
Brian Warner
a39270bd46 more v1-introducer cleanup: require sigs
This removes a little bit of code that tolerated unsigned announcements.
2016-07-05 16:41:15 -07:00
Brian Warner
78810d5851 Merge branch '2784-remove-v1-introducer'
Closes PR #289
Closes ticket:2784
2016-07-05 15:31:34 -07:00
Brian Warner
6f1e01453e remove make_index()
index is now always (service_name, key_id)
2016-06-29 23:06:40 -07:00
Brian Warner
b2e5507e09 sign_to_foolscap: require key 2016-06-29 23:06:40 -07:00
Brian Warner
ae91fa9ffe require all outbound announcements to be signed 2016-06-29 23:06:40 -07:00
Brian Warner
c64ff7b310 more v1 removal cleanup
Historical note: V2 introducers have been around for three years
now (released in 1.10.0), so it's time to drop v1. This branch removes a
lot of fallback code, and tests which exercised it. refs ticket:2784

This patch removes some now-unused code: v1-related support functions on
the client, "stub-client" handlers, and v1-tolerant remote methods on
the server. The unit tests have been cleaned up a bit too, now that
there are fewer cases to exercise.
2016-06-29 22:58:14 -07:00
David Stainton
7feee8a25e Butcher unit tests until all test_introducer tests pass 2016-06-02 17:20:31 +00:00
David Stainton
ea35563b81 Remove v1 introducer code and fix tests
Fixed many of the test_introducer tests.
Work-in-progress.
2016-06-02 16:47:58 +00:00
Brian Warner
73b08d2a54 Merge pr281: load YAML cache when connection fails
refs ticket:2788
2016-05-11 18:27:11 -07:00
Brian Warner
0ff00dff6f test loading the cache 2016-05-11 18:17:22 -07:00
Brian Warner
5bedca43e3 load-yaml-cache cleanups
* use yaml.safe_load and yaml.safe_dump
  * configure SafeLoader to return unicode consistently, not str
* log+ignore bad cache, instead of throwing error, since we're already
  in the log+ignore chain from connect_failed()
* use a local exception type, instead of one from storage_client.py
* delegate delivery to self._deliver_announcements

Using yaml.safe_dump gives us:

- ann:
    my-version: tahoe-lafs/1.11.0.post96.dev0
    nickname: node-4

instead of:

- ann:
    !!python/unicode 'my-version': !!python/unicode 'tahoe-lafs/1.11.0.post96.dev0'
    !!python/unicode 'nickname': !!python/unicode 'node-4'

We want SafeLoader to consistently return unicode instead of sometimes
plain strings (for ASCII-safe values) and sometimes unicode
(for everything else). The data we write into the cache was all unicode
to start with (it came from a JSON parser), so it seems better to get
back unicode too.
2016-05-11 18:15:50 -07:00
David Stainton
5508f751b6 Load announcement cache if failure to connect to introducer 2016-05-11 16:48:09 -07:00
Brian Warner
cfb939aa99 improve test_client_cache 2016-05-11 16:48:05 -07:00
Brian Warner
ecec58b339 test_introducer: factor out _load_cache 2016-05-11 15:03:32 -07:00
Brian Warner
1197b15106 introducer_client: split out _deliver_announcements 2016-05-11 12:54:11 -07:00