Sajith Sasidharan
61aef4caef
Merge pull request #690 from sajith/3247.storage-py-neovw-to-twt
...
Use twisted.web.template in web/storage.py
Fixes: ticket:3247
2020-07-06 16:18:34 -04:00
Itamar Turner-Trauring
f548593f37
Fix test_python3, and mark these two modules as being ported as well.
2020-07-06 14:18:18 -04:00
Itamar Turner-Trauring
b990334104
Add the builtins import to make Python 2 builtins match Python 3's.
2020-07-06 14:00:02 -04:00
Itamar Turner-Trauring
83b9bbf743
Switch definitely to _python3.py for listing modules, but also note if a module
...
has been ported in its docstring.
2020-07-03 13:28:36 -04:00
Itamar Turner-Trauring
140cb80ff7
Clarify comment.
2020-07-03 13:15:57 -04:00
Itamar Turner-Trauring
12691eb597
Only install module mappings once.
2020-07-02 14:31:33 -04:00
Itamar Turner-Trauring
ad7f44db99
Listed ported modules.
2020-07-02 14:27:43 -04:00
Itamar Turner-Trauring
70a029fb81
Tests pass on both Python 2 and Python 3.
2020-07-02 14:26:35 -04:00
Itamar Turner-Trauring
c207a0c932
Port test_humanreadable.py to Python 3.
2020-07-02 14:10:38 -04:00
Itamar Turner-Trauring
99b62775e9
Initial list of ported modules.
2020-07-02 13:42:30 -04:00
Itamar Turner-Trauring
b7f88b278f
Split out tests for humanreadable into their own module, so we can port just
...
humanreadable.py in isolation.
2020-07-02 13:40:40 -04:00
meejah
ffd24b9c7f
Merge pull request #728 from meejah/ticket3317-verified-fakes
...
Ticket 3317: start of verified fakes
2020-06-30 19:40:39 +00:00
meejah
80359e02e6
assert -> Exception
2020-06-30 08:17:34 -06:00
meejah
a9f4210014
streap -> stream
2020-06-30 08:15:58 -06:00
Sajith Sasidharan
88d3fa7415
Remove now-unnecessary UploadResultsPage.render_UPLOAD
2020-06-23 21:54:23 -04:00
Sajith Sasidharan
dfbb8e7743
Make UploadResultsPage a Resource
2020-06-23 21:53:39 -04:00
Sajith Sasidharan
6ab7f26faf
Make UploadStatusPage a Resource
2020-06-23 21:28:31 -04:00
meejah
aedc58ef51
unused imports
2020-06-19 17:22:42 -06:00
meejah
f0ac5a2cef
more-testtools-y asserts
2020-06-19 17:19:30 -06:00
meejah
57eb875354
testtool's asserts
2020-06-19 17:16:39 -06:00
meejah
ef71fc2bfc
Get rid of ?replace= handling entirely and more-correctly support /uri variants
2020-06-19 17:15:01 -06:00
Sajith Sasidharan
7a23c8ed6c
Merge pull request #724 from sajith/3312.webui-directory-fix
...
Fix for "the webapi does not allow empty pathname components"
Fixes: ticket:3312
2020-06-17 10:55:21 -04:00
meejah
6a37f32eef
use attr.s
2020-06-13 17:28:28 -06:00
meejah
939f60f620
embetter docstring
2020-06-13 17:22:17 -06:00
meejah
d221787541
better docstring
2020-06-13 02:03:19 -06:00
meejah
02a543515f
replciate Tahoe's behavior for replace=true/false
2020-06-13 01:55:14 -06:00
meejah
0cbdbd9ebe
symbols, not magic-numbers
2020-06-13 01:14:45 -06:00
meejah
b952ef066c
match query args
2020-06-13 00:46:55 -06:00
meejah
24899dae8e
assert -> ValueError
2020-06-13 00:41:22 -06:00
meejah
76040b53f5
assert -> raise
2020-06-13 00:39:57 -06:00
meejah
9f6fcde2f1
more docstring
2020-06-13 00:39:12 -06:00
meejah
a38188164f
comment
2020-06-12 23:08:04 -06:00
meejah
c64e78634d
docstring
2020-06-12 23:06:33 -06:00
meejah
23b17ca02e
cleanup, docstrings
2020-06-12 23:05:32 -06:00
meejah
e79534abe8
housekeeping
2020-06-12 23:01:02 -06:00
meejah
fa597e1735
use real parser
2020-06-12 22:57:38 -06:00
meejah
949b09ce27
actually returns CREATED for new data
2020-06-12 22:08:36 -06:00
meejah
776ee5f91c
use hypothesis -- which doesn't know about Deferred, so need testtools too
2020-06-12 22:04:12 -06:00
meejah
05ea0a2fe9
copyright, header
2020-06-12 22:04:03 -06:00
meejah
318dc5092d
key -> kind
2020-06-11 19:57:21 -06:00
meejah
0e5422c24b
handle more inputs in test body-producer
2020-06-11 19:57:11 -06:00
meejah
36d9bf5d09
new-style classes only
2020-06-11 15:34:47 -06:00
meejah
00e7d01a1a
unused imports
2020-06-11 15:34:40 -06:00
meejah
86a90084bb
simple test of testing/web
2020-06-11 14:14:42 -06:00
meejah
fc2203e421
simplify tahoe web fakes
2020-06-11 13:26:09 -06:00
meejah
3e973197ac
synchronous-only up/download tahoe code to keep treq.testing happy
2020-06-03 11:32:22 -06:00
Sajith Sasidharan
4fa2e6ad97
Use twisted web directives in web.operations.ReloadMixin
2020-06-02 11:56:59 -04:00
meejah
1faa81c7c4
actual usable agent
2020-06-01 09:06:46 -06:00
Sajith Sasidharan
dd14da4a55
Decode name before null check
...
Make the diff against master a tad bit smaller.
2020-05-29 21:48:04 -04:00
Sajith Sasidharan
dce73f7c2f
Make "Refresh" link work
...
This seems to be a subtle difference from nevow: with `href="."`,
rendered link target will be `/uri/`, so clicking "Refresh" will
result in an error message like so: "GET /uri requires uri=".
With `href=""`, the rendered link target will be `/uri/URI:...`, which
is what we need.
2020-05-29 21:44:10 -04:00
Sajith Sasidharan
31eba00d0f
Reject trailing empty path piece in URIs
2020-05-29 21:38:43 -04:00
Sajith Sasidharan
0633623ecc
Reject URIs that contain empty segments
2020-05-29 21:38:43 -04:00
Sajith Sasidharan
b6e00d09f9
Render self in DirectoryNodeHandler.getChild()
...
We need self.render_POST() etc. to be invoked when we have a request
such as "POST /uri/URI:DIR:..."; throwing an error here is probably
not the right thing to do.
2020-05-29 09:22:15 -04:00
Sajith Sasidharan
cf4b3ba008
Correct arguments to super()
...
This was incidentally found when looking at some test failures:
super(type, object) is the right invocation, and not the other way
around.
2020-05-29 09:20:18 -04:00
meejah
d50ca9af55
proof-of-concept verified-fake for testing
2020-05-26 18:33:04 -06:00
Sajith Sasidharan
03d529c22a
Remove unused import
2020-05-22 21:33:30 -04:00
Sajith Sasidharan
f8562530be
Make Element the superclass of UploadResultsRendererMixin
2020-05-22 21:11:42 -04:00
Sajith Sasidharan
b0e3325d03
Move time formatter tests
...
UploadResultsRendererMixin no longer has render_time(); moving tests
for render_time() as tests for abbreviate_time() to a more appropriate
place.
2020-05-22 20:49:34 -04:00
Sajith Sasidharan
91f8d939f8
Avoid use of RateAndTimeMixin in UploadResultsRendererMixin
2020-05-22 20:22:59 -04:00
Sajith Sasidharan
aecd90858a
Render abbreviated rate and time values
2020-05-22 19:39:32 -04:00
Sajith Sasidharan
7be1883910
Document UploadResultsPage parameter
2020-05-22 19:39:32 -04:00
Sajith Sasidharan
5fdd61b146
Document UploadStatusPage
2020-05-22 19:39:32 -04:00
Sajith Sasidharan
54ac2d224a
Remove unused imports
2020-05-22 19:39:32 -04:00
Sajith Sasidharan
7a82fd671f
Handle "t=upload" in UploadResultsPage POST handling
2020-05-22 19:39:32 -04:00
Sajith Sasidharan
3bfa5a5c29
Use twisted web template in UploadResultsRendererMixin
2020-05-22 19:39:32 -04:00
Sajith Sasidharan
57b1203d17
Make UploadResultsPage a MultiFormatResource
2020-05-22 19:39:32 -04:00
Sajith Sasidharan
6470718691
Use twisted template tags in upload results page template
2020-05-22 19:39:32 -04:00
Sajith Sasidharan
41300097c8
Make UploadStatusPage a MultiFormatResource
2020-05-22 19:39:32 -04:00
Sajith Sasidharan
aac8dee8a0
Use twisted template tags in upload status page template
2020-05-22 19:39:32 -04:00
Sajith Sasidharan
538503c0f8
Merge pull request #717 from sajith/3289.status-publish-nevow-to-twisted-web
...
Replace nevow with twisted.web.template in status.PublishStatusPage
Fixes: ticket:3289
2020-05-14 10:09:57 -04:00
Sajith Sasidharan
78c214b7ff
Merge pull request #716 from sajith/3290.status-retrieve-nevow-to-twisted-web
...
Replace nevow with twisted.web.template in status.RetrieveStatusPage
Fixes: ticket:3290
2020-05-13 19:39:23 -04:00
Sajith Sasidharan
79a44eac33
Correct docstring to ":param <type> <name>" format
2020-05-13 19:29:41 -04:00
Sajith Sasidharan
9d5d338993
Correct docstring to ":param <type> <name>" format
2020-05-13 19:04:10 -04:00
Sajith Sasidharan
d87dfaf5a0
Merge pull request #714 from sajith/3291.status-mapupdate-nevow-to-twisted-web
...
Replace nevow with twisted.web.template in status.MapupdatePage
Fixes: ticket:3291
2020-05-13 18:22:16 -04:00
Sajith Sasidharan
ebe80221d5
Add missing "param:" to init method docstring
2020-05-13 17:45:08 -04:00
Sajith Sasidharan
2e0e210c14
Make PublishStatusPage comment a docstring
2020-05-13 17:43:55 -04:00
Sajith Sasidharan
5aa0dd4085
Rename a variable for readability
...
Noticed in code review: `l` can be confused with `1` for many
typefaces.
2020-05-13 17:12:08 -04:00
Sajith Sasidharan
812f03934a
Add missing "param:" to docstring
2020-05-13 17:09:53 -04:00
Sajith Sasidharan
4af2e4b4df
Drop an unbalanced quote
2020-05-13 17:08:26 -04:00
Sajith Sasidharan
62760c0997
Make RetrieveStatusPage comment a docstring
2020-05-13 17:07:09 -04:00
Sajith Sasidharan
8e17d203cf
Add missing "param:" to docstring
2020-05-13 16:59:52 -04:00
Sajith Sasidharan
c18488872c
Make comment on MapupdateStatusPage a docstring
2020-05-13 16:54:39 -04:00
meejah
466369dd69
Merge pull request #669 from meejah/make-pypy-work
...
Make pypy work
2020-05-13 12:44:23 -06:00
Sajith Sasidharan
3fad9a127c
Remove web.common.RenderMixin
...
Fixes: ticket:3308
2020-05-12 07:40:22 -04:00
Sajith Sasidharan
0ae045ea16
Add comments to PublishStatusPage
2020-05-11 12:47:48 -04:00
Sajith Sasidharan
9e200fc014
Render publish problems only when there are problems
2020-05-11 11:43:04 -04:00
Sajith Sasidharan
0fba615afb
Remove RateAndTimeMixin from PublishStatusPage
2020-05-11 11:43:04 -04:00
Sajith Sasidharan
fdf6449ba8
Use MultiFormatResource to implement PublishStatusPage
2020-05-11 11:43:04 -04:00
Sajith Sasidharan
89c4210090
Use twisted tags in publish status template page
2020-05-11 11:43:01 -04:00
Sajith Sasidharan
65cd0e8ecd
Reformat publish status template page
2020-05-11 10:38:15 -04:00
Sajith Sasidharan
3aaa87d2ba
Add notes to RetrieveStatusPage
2020-05-07 13:15:05 -04:00
Sajith Sasidharan
07f14a19f8
Drop RateAndTimeMixin from RetrieveStatusElement
2020-05-07 11:37:21 -04:00
Sajith Sasidharan
a544e8a55f
Stringify tag parameters
2020-05-07 10:55:08 -04:00
Sajith Sasidharan
de41302743
Update RetrieveStatusPage to use twisted renderers
2020-05-07 09:34:42 -04:00
Sajith Sasidharan
5fa7c4c446
Update markup in retrieve status template page
2020-05-07 09:32:01 -04:00
Sajith Sasidharan
d2375e4fe2
Reformat retrieve status page template
2020-05-06 22:42:32 -04:00
meejah
2418e90bf0
CacheDirectoryManager is unused
2020-05-06 15:22:22 -06:00
meejah
1549e7eb18
simplify (for line in f.readlines() -> for line in f)
2020-05-06 15:16:34 -06:00
Sajith Sasidharan
13bbda1529
Render privkey only when there's a privkey
2020-05-06 13:21:26 -04:00
Sajith Sasidharan
008812d6c8
Render abbreviated time in map update results
2020-05-06 13:11:53 -04:00