mirror of
https://github.com/tahoe-lafs/tahoe-lafs.git
synced 2025-02-02 01:08:20 +00:00
Remove another future import.
This commit is contained in:
parent
a9015cdb5b
commit
09854684e6
@ -5,7 +5,6 @@ functionality.
|
|||||||
Ported to Python 3.
|
Ported to Python 3.
|
||||||
"""
|
"""
|
||||||
|
|
||||||
from future.utils import native_str_to_bytes
|
|
||||||
from six import ensure_str
|
from six import ensure_str
|
||||||
|
|
||||||
import attr
|
import attr
|
||||||
@ -87,7 +86,7 @@ class DummyStorage(object):
|
|||||||
"""
|
"""
|
||||||
items = configuration.items(self._client_section_name, [])
|
items = configuration.items(self._client_section_name, [])
|
||||||
resource = Data(
|
resource = Data(
|
||||||
native_str_to_bytes(dumps(dict(items))),
|
dumps(dict(items)).encode("utf-8"),
|
||||||
ensure_str("text/json"),
|
ensure_str("text/json"),
|
||||||
)
|
)
|
||||||
# Give it some dynamic stuff too.
|
# Give it some dynamic stuff too.
|
||||||
@ -105,7 +104,7 @@ class GetCounter(Resource, object):
|
|||||||
value = 0
|
value = 0
|
||||||
def render_GET(self, request):
|
def render_GET(self, request):
|
||||||
self.value += 1
|
self.value += 1
|
||||||
return native_str_to_bytes(dumps({"value": self.value}))
|
return dumps({"value": self.value}).encode("utf-8")
|
||||||
|
|
||||||
|
|
||||||
@implementer(RIDummy)
|
@implementer(RIDummy)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user