Jean-Paul Calderone
37016f4ab5
pyflakes
2020-10-21 12:21:44 -04:00
Jean-Paul Calderone
c31300fd0d
Handle interrupted connections
2020-10-21 12:21:01 -04:00
Jean-Paul Calderone
14b9dc090d
Replace some ctx
names with req
2020-10-21 10:12:48 -04:00
Jean-Paul Calderone
03a144755d
Nevow is no longer a dependency
2020-10-21 10:02:32 -04:00
Jean-Paul Calderone
7eecf51dc5
Just talk about rendering, not Nevow
2020-10-21 10:02:22 -04:00
Jean-Paul Calderone
6500f742dc
Twisted Web handles UnsupportedMethod for us
2020-10-21 10:02:10 -04:00
Jean-Paul Calderone
816ca79d8a
Talk about os.stat and tracebacks instead of Nevow
2020-10-21 10:01:57 -04:00
Jean-Paul Calderone
2ba34a4759
Talk about Nevow as a proper noun where necessary
2020-10-21 10:01:46 -04:00
Jean-Paul Calderone
a577f1e48d
pyflakes
2020-10-21 09:49:03 -04:00
Jean-Paul Calderone
80549f5f02
Make this request a little more realistic
2020-10-21 09:46:21 -04:00
Jean-Paul Calderone
7d54af7928
re-use our other renderer
2020-10-21 09:46:14 -04:00
Jean-Paul Calderone
27c2fd80c8
re-use our other renderer
2020-10-21 09:46:00 -04:00
Jean-Paul Calderone
c8db069960
Get rid of no-longer used Nevow exception handler
2020-10-21 09:45:41 -04:00
Jean-Paul Calderone
c64a71a642
Re-arrange some of the requestReceived logic and switch to t.web Site
2020-10-21 09:45:11 -04:00
Jean-Paul Calderone
538cefed3d
Update Twisted Web-based render
to use our request
...
Also to do one other thing Twisted Web does for resources automatically -
handle UnsupportedMethod
2020-10-21 08:51:45 -04:00
Jean-Paul Calderone
637bb2e576
De-Nevow `render
`
2020-10-21 08:51:25 -04:00
Jean-Paul Calderone
304a9880e6
De-Nevow `get_root
`
2020-10-21 08:50:53 -04:00
Jean-Paul Calderone
743ead71a4
De-Nevow `get_arg
`
2020-10-21 08:50:37 -04:00
Jean-Paul Calderone
7f02128973
[wip] test form posts
2020-10-21 08:29:41 -04:00
Jean-Paul Calderone
0dcc3e13c0
Remove unused imports
2020-10-21 08:21:29 -04:00
Jean-Paul Calderone
7ca8ede88c
Merge remote-tracking branch 'origin/master' into 3428.dont-return-deferred-to-twistedweb.2
2020-10-21 07:35:10 -04:00
Jean-Paul Calderone
f602382244
Comments about __get__ calls
2020-10-21 07:34:27 -04:00
Jean-Paul Calderone
7ce2122e71
one more reference
2020-10-21 07:26:12 -04:00
Jean-Paul Calderone
e8761c98ad
A comment about what _finish
is here for
2020-10-21 07:25:48 -04:00
Jean-Paul Calderone
d8b6e36c6f
docstring for StaticResource
2020-10-21 07:23:16 -04:00
Jean-Paul Calderone
dbe2d4efd7
It isn't the root, it's wherever we actually are
2020-10-21 07:22:00 -04:00
Jean-Paul Calderone
a91dba5f5b
_finish docstring
2020-10-21 07:18:41 -04:00
Jean-Paul Calderone
1ed74604c7
Use twisted.web.server.Request instead of DummyRequest in the tests
...
Always prefer the real thing if possible
2020-10-21 07:15:36 -04:00
Jean-Paul Calderone
3192715e37
everything newstyle
2020-10-19 14:37:03 -04:00
Jean-Paul Calderone
a9e9efb336
direct tests for @render_exception
2020-10-19 14:26:12 -04:00
Jean-Paul Calderone
b68c08cff9
Yank direct support for URLPath from common.py
2020-10-19 12:33:15 -04:00
Jean-Paul Calderone
72e60f8301
Fix imports
2020-10-18 11:12:44 -04:00
Jean-Paul Calderone
e710fd883a
Add a Twisted Web-based renderer and start using it on Python 3
...
This could be the thing that eventually replaces the Nevow-based testing
renderer on Python 2 as well.
2020-10-18 11:00:57 -04:00
Jean-Paul Calderone
84acf4e50f
Accept unicode return values and encode them to UTF-8
...
Nevow accepts unicode in most places it accepts bytes and does the usual
sloppy Python 2 thing, lets one or the other get implicitly re-coded,
typically using the ascii codec.
We'll go with UTF-8 because that fails less often than ASCII. We may want to
clean up the code at some point so we're not accidentally slinging both bytes
and text around as if they were the same thing.
2020-10-18 10:58:09 -04:00
Jean-Paul Calderone
fc1f43c7a3
How does it go without the type check
...
This is for py36:
> TypeError: helper_furl must be bytes, got 'pb://kl5iekm6itcyjejirxva2upthepsasnn@bogus:1234/frekgeq7gsongibyeuvzmvqoyf4h5pcx' instead
2020-10-16 19:07:28 -04:00
Jean-Paul Calderone
a403d25146
Merge remote-tracking branch 'origin/master' into 3468.offloaded-test-coverage
2020-10-16 14:34:35 -04:00
Jean-Paul Calderone
85bb0a7834
Get rid of the original token-based authorization helper
...
It was only used by magic-folder and that's gone now. We have a different
authorization helper for other things now, allmydata.web.private.
2020-10-16 14:14:15 -04:00
Jean-Paul Calderone
292f136547
pyflakes
2020-10-16 13:21:07 -04:00
Jean-Paul Calderone
a22426011b
import and naming cleanups post-merge
2020-10-16 12:49:36 -04:00
Itamar Turner-Trauring
8e618b9383
Fix Python 2 issue.
2020-10-16 11:25:29 -04:00
Itamar Turner-Trauring
6aa96bbb8d
Port test_node.py to Python 3.
2020-10-16 11:23:38 -04:00
Itamar Turner-Trauring
f7a89f76e7
All tests pass on Python 3.
2020-10-16 11:20:10 -04:00
Itamar Turner-Trauring
51d472e221
More progress towards passing tests on Python 3.
2020-10-16 11:13:11 -04:00
Itamar Turner-Trauring
f689d59a40
More passing tests on Python 3.
2020-10-16 10:55:33 -04:00
Itamar Turner-Trauring
bcd7cdf86f
Some passing tests on Python 3.
2020-10-16 10:47:49 -04:00
Jean-Paul Calderone
32051f93b9
Merge remote-tracking branch 'origin/master' into 3428.dont-return-deferred-to-twistedweb.2
2020-10-16 10:37:54 -04:00
Itamar Turner-Trauring
c2fe5a65a6
Merge pull request #847 from tahoe-lafs/3459.test-checker-python-3
...
Port test_checker.py to Python 3
Fixes ticket:3459
2020-10-16 10:31:25 -04:00
Jean-Paul Calderone
a73a919a20
flakes
2020-10-16 10:22:42 -04:00
Jean-Paul Calderone
a1f1f00be7
Use the more feaetureful rendering helper
2020-10-16 09:53:30 -04:00
Jean-Paul Calderone
31207e4b6b
don't double-apply the renderer logic
...
since that leads to double-finishing requests too
2020-10-16 09:53:24 -04:00
Jean-Paul Calderone
0faa24d344
Add a mess of eliot logging to request handling
2020-10-16 09:53:19 -04:00
Jean-Paul Calderone
0339ba97b9
Turn getChild None and Deferred results into something Twisted Web can manage
2020-10-16 09:52:41 -04:00
Jean-Paul Calderone
fa02e46033
maybeDeferred always returns a Deferred
2020-10-16 09:52:33 -04:00
Jean-Paul Calderone
f733a244aa
Just gonna produce text instead
2020-10-16 09:52:26 -04:00
Jean-Paul Calderone
d38ae4d6dd
Stop reading server module attributes all the time
...
It jumps through a ton of deprecation machinery that is at least tedious in
the debugger, if not wasteful at runtime.
2020-10-16 09:52:18 -04:00
Jean-Paul Calderone
07246b3509
Render requests more thoroughly
2020-10-16 09:52:10 -04:00
Jean-Paul Calderone
df949868b6
Stop explicitly finishing and then returning a string
2020-10-16 09:51:50 -04:00
Jean-Paul Calderone
69c7c40510
handle Deferred from render
2020-10-16 09:51:42 -04:00
Jean-Paul Calderone
f15086d995
Merge pull request #844 from tahoe-lafs/3460.improved-got_announcement
...
Improved `_got_announcement`
Fixes: ticket:3460
2020-10-16 08:55:11 -04:00
Jean-Paul Calderone
99fe617069
Merge pull request #857 from tahoe-lafs/3470.oneshotobserverlist-immediately
...
Make OneShotObserverList immediate
Fixes: ticket:3470
2020-10-15 17:37:31 -04:00
Jean-Paul Calderone
733d393a07
Merge pull request #840 from tahoe-lafs/3454.unskip-test_python3
...
Unskip the Python 3 porting test on Python 2
Fixes: ticket:3454
2020-10-15 17:32:59 -04:00
Jean-Paul Calderone
4d56b5f4ed
Merge pull request #858 from tahoe-lafs/3471.immediate-localwrapper
...
Allow LocalWrapper to be immediate
Fixes: ticket:3471
2020-10-15 13:15:35 -04:00
Jean-Paul Calderone
2960a270ce
Declare and document what LocalWrapper is/does
2020-10-15 12:00:03 -04:00
Itamar Turner-Trauring
707ab50606
Test BytesJSONEncoder with Unicode.
2020-10-15 08:37:09 -04:00
Itamar Turner-Trauring
1c976990a1
Make comment more meaningful.
2020-10-15 08:34:56 -04:00
Itamar Turner-Trauring
e6a196c144
Get rid of hopefully unnecessary sort.
2020-10-15 08:33:51 -04:00
Itamar Turner-Trauring
b658a66e7f
Merge remote-tracking branch 'origin/master' into 3459.test-checker-python-3
2020-10-15 08:32:53 -04:00
Itamar Turner-Trauring
b094a00458
Merge pull request #860 from tahoe-lafs/3473-mutable-tests-part-1-python-3
...
Port allmydata.mutable.tests to Python 3: part 1 of N
Fixes ticket:3473
2020-10-15 08:27:45 -04:00
Itamar Turner-Trauring
fecbbb6733
Port to Python 3.
2020-10-14 16:05:02 -04:00
Itamar Turner-Trauring
7faea936df
Tests pass on Python 3.
2020-10-14 16:03:53 -04:00
Itamar Turner-Trauring
b5e54f2ed2
Port to Python 3.
2020-10-14 15:50:02 -04:00
Itamar Turner-Trauring
fa92fde04a
Port to Python 3.
2020-10-14 15:46:37 -04:00
Itamar Turner-Trauring
43f5a25ec2
Tests pass on Python 3.
2020-10-14 15:45:09 -04:00
Jean-Paul Calderone
40e0ef0fad
Directly test CHKCheckerAndUEBFetcher cases
2020-10-14 12:02:56 -04:00
Jean-Paul Calderone
b0159a898e
Parameterize the callRemote scheduling
2020-10-14 11:08:40 -04:00
Jean-Paul Calderone
5a51d98479
Add missing chk_upload, document two new attrs, and move them up
2020-10-14 10:58:50 -04:00
Jean-Paul Calderone
9a18843bb1
finish the comment
2020-10-14 10:58:50 -04:00
Jean-Paul Calderone
555b751af0
Further expand existing test coverage by reducing fake quantities
...
Helper_fake_upload is replaced by more narrowly focused CHKUploadHelper_fake
2020-10-14 10:58:50 -04:00
Jean-Paul Calderone
4e46f9ae12
expand the already-uploaded test for the helper to cover more
...
shrink the amount of fake code being used and increase the amount of real code
being used
2020-10-14 10:58:50 -04:00
Jean-Paul Calderone
ef11eeb4a2
exercise concurrent upload
2020-10-14 10:58:50 -04:00
Jean-Paul Calderone
8eb518a221
docstring for Helper._active_uploads
2020-10-14 10:58:50 -04:00
Jean-Paul Calderone
c88c2846e2
Point folks at docs for this
2020-10-14 10:58:50 -04:00
Jean-Paul Calderone
5974f5adf9
Stop using eventually
in OneShotObserverList
2020-10-14 10:56:50 -04:00
Itamar Turner-Trauring
c0f486a9f6
Work on Python 3.
2020-10-13 09:51:25 -04:00
Itamar Turner-Trauring
50925fcec1
Get rid of more no-longer-needed moves.
2020-10-13 09:49:39 -04:00
Itamar Turner-Trauring
3ea18ca3fc
As better alternative to common_py3, make common.py import on Python 3.
2020-10-13 09:45:03 -04:00
Chad Whitacre
a0963fc2da
Keep future.builtins imports consistent
...
- remove int from a stock import
- comment a non-stock import
2020-10-13 08:39:25 -04:00
Chad Whitacre
574c63d350
Port immutable.offloaded to Python 3
2020-10-12 07:25:44 -04:00
Itamar Turner-Trauring
17f0676b3f
Merge branch 'master' into 3459.test-checker-python-3
2020-10-09 10:22:17 -04:00
Ross Patterson
cc8c9c0bdf
Merge pull request #851 from tahoe-lafs/3464.cleanup-bbb-comments
...
#3455 : Address feedback, BBB comments
2020-10-08 13:49:34 -07:00
Ross Patterson
95f2d53f92
chore(refs #3455 ) Address feedback, BBB comments
...
https://github.com/tahoe-lafs/tahoe-lafs/pull/845#issuecomment-704469561
2020-10-07 12:28:41 -07:00
Itamar Turner-Trauring
d519d4b2fa
Merge branch 'master' into 3463.more-immutable-python-3
2020-10-07 13:22:04 -04:00
Itamar Turner-Trauring
72cc37bb95
Merge pull request #843 from tahoe-lafs/3458.callremote-unicode
...
Fix callRemote unicode issues on Python 2 universally, using monkeypatching
Fixes ticket:3458
2020-10-07 13:21:19 -04:00
Itamar Turner-Trauring
5b76bf7f44
Fix trailing whitespace.
2020-10-07 10:12:31 -04:00
Itamar Turner-Trauring
f2e5688723
Port to Python 3.
2020-10-07 10:06:02 -04:00
Itamar Turner-Trauring
af95769927
Merge branch '3458.callremote-unicode' into 3463.more-immutable-python-3
2020-10-07 09:53:30 -04:00
Itamar Turner-Trauring
9dc4f98987
Port to Python 3.
2020-10-07 09:29:41 -04:00
Itamar Turner-Trauring
3e87ba368e
Port to Python 3.
2020-10-06 11:32:19 -04:00
Chad Whitacre
e78afd877c
Merge pull request #846 from tahoe-lafs/3456.tweak-docstring
...
Tweak docstring on FakeCanary
2020-10-06 06:19:54 -04:00
Itamar Turner-Trauring
c680b1d971
Lint fixes.
2020-10-05 11:38:53 -04:00