move encode/upload/download/checker.py into a new immutable/ directory. No behavior changes expected.

This commit is contained in:
Brian Warner 2008-07-16 13:14:39 -07:00
parent af0648c0f8
commit 7394607141
23 changed files with 42 additions and 27 deletions

View File

@ -12,13 +12,13 @@ from pycryptopp.publickey import rsa
import allmydata
from allmydata.storage import StorageServer
from allmydata.upload import Uploader
from allmydata.download import Downloader
from allmydata.immutable.upload import Uploader
from allmydata.immutable.download import Downloader
from allmydata.immutable.filenode import FileNode, LiteralFileNode
from allmydata.offloaded import Helper
from allmydata.control import ControlServer
from allmydata.introducer.client import IntroducerClient
from allmydata.util import hashutil, base32, testutil
from allmydata.filenode import FileNode, LiteralFileNode
from allmydata.uri import LiteralFileURI
from allmydata.dirnode import NewDirectoryNode
from allmydata.mutable.node import MutableFileNode, MutableWatcher

View File

@ -6,7 +6,7 @@ from twisted.internet import defer
from foolscap import Referenceable
from allmydata.interfaces import RIControlClient
from allmydata.util import testutil, fileutil, mathutil
from allmydata import upload, download
from allmydata.immutable import upload, download
from twisted.python import log
def get_memory_usage():

View File

View File

@ -9,8 +9,9 @@ have the share, we believe them.
from zope.interface import implements
from twisted.internet import defer
from twisted.python import log
from allmydata import storage
from allmydata.interfaces import IVerifierURI, ICheckerResults
from allmydata import download, storage
from allmydata.immutable import download
from allmydata.util import hashutil, base32
class Results:

View File

@ -11,7 +11,7 @@ from allmydata.util.assertutil import _assert
from allmydata import codec, hashtree, storage, uri
from allmydata.interfaces import IDownloadTarget, IDownloader, IFileURI, \
IDownloadStatus, IDownloadResults
from allmydata.encode import NotEnoughSharesError
from allmydata.immutable.encode import NotEnoughSharesError
from pycryptopp.cipher.aes import AES
class HaveAllPeersError(Exception):

View File

@ -3,8 +3,8 @@ from zope.interface import implements
from twisted.internet import defer
from allmydata.interfaces import IFileNode, IFileURI, IURI, ICheckable
from allmydata import uri
from allmydata.checker import SimpleCHKFileChecker, SimpleCHKFileVerifier, \
Results
from allmydata.immutable.checker import Results, \
SimpleCHKFileChecker, SimpleCHKFileVerifier
class FileNode:
implements(IFileNode, ICheckable)

View File

@ -12,7 +12,8 @@ from allmydata.util.hashutil import file_renewal_secret_hash, \
file_cancel_secret_hash, bucket_renewal_secret_hash, \
bucket_cancel_secret_hash, plaintext_hasher, \
storage_index_hash, plaintext_segment_hasher, convergence_hasher
from allmydata import encode, storage, hashtree, uri
from allmydata import storage, hashtree, uri
from allmydata.immutable import encode
from allmydata.util import base32, idlib, mathutil
from allmydata.util.assertutil import precondition
from allmydata.interfaces import IUploadable, IUploader, IUploadResults, \
@ -38,6 +39,9 @@ class TooFullError(Exception):
class UploadResults(Copyable, RemoteCopy):
implements(IUploadResults)
# note: don't change this string, it needs to match the value used on the
# helper, and it does *not* need to match the fully-qualified
# package/module/class name
typeToCopy = "allmydata.upload.UploadResults.tahoe.allmydata.com"
copytype = typeToCopy

View File

@ -10,7 +10,7 @@ from allmydata.interfaces import IMutableFileNode, IMutableFileURI, ICheckable
from allmydata.util import hashutil
from allmydata.util.assertutil import precondition
from allmydata.uri import WriteableSSKFileURI
from allmydata.encode import NotEnoughSharesError
from allmydata.immutable.encode import NotEnoughSharesError
from pycryptopp.publickey import rsa
from pycryptopp.cipher.aes import AES

View File

@ -8,7 +8,7 @@ from foolscap.eventual import eventually, fireEventually
from allmydata.interfaces import IRetrieveStatus
from allmydata.util import hashutil, idlib, log
from allmydata import hashtree, codec, storage
from allmydata.encode import NotEnoughSharesError
from allmydata.immutable.encode import NotEnoughSharesError
from pycryptopp.cipher.aes import AES
from common import DictOfSets, CorruptShareError, UncoordinatedWriteError

View File

@ -5,7 +5,8 @@ from twisted.application import service
from twisted.internet import defer
from foolscap import Referenceable
from foolscap.eventual import eventually
from allmydata import upload, interfaces, storage, uri
from allmydata import interfaces, storage, uri
from allmydata.immutable import upload
from allmydata.util import idlib, log, observer, fileutil, hashutil

View File

@ -5,7 +5,8 @@ from cStringIO import StringIO
from twisted.internet import defer, reactor, protocol, error
from twisted.application import service, internet
from twisted.web import client as tw_client
from allmydata import client, introducer, upload
from allmydata import client, introducer
from allmydata.immutable import upload
from allmydata.scripts import create_node
from allmydata.util import testutil, fileutil
import foolscap

View File

@ -4,10 +4,11 @@ from zope.interface import implements
from twisted.internet import defer
from twisted.python import failure
from twisted.application import service
from allmydata import uri, dirnode, checker
from allmydata import uri, dirnode
from allmydata.interfaces import IURI, IMutableFileNode, IFileNode, \
FileTooLargeError
from allmydata.encode import NotEnoughSharesError
from allmydata.immutable import checker
from allmydata.immutable.encode import NotEnoughSharesError
from allmydata.util import log
class FakeCHKFileNode:

View File

@ -2,7 +2,8 @@
import time
from zope.interface import implements
from twisted.trial import unittest
from allmydata import uri, dirnode, upload
from allmydata import uri, dirnode
from allmydata.immutable import upload
from allmydata.interfaces import IURI, IClient, IMutableFileNode, \
INewDirectoryURI, IReadonlyNewDirectoryURI, IFileNode, ExistingChildError
from allmydata.util import hashutil, testutil

View File

@ -5,7 +5,8 @@ from twisted.internet import defer, reactor
from twisted.internet.interfaces import IConsumer
from twisted.python.failure import Failure
from foolscap import eventual
from allmydata import encode, upload, download, hashtree, uri
from allmydata import hashtree, uri
from allmydata.immutable import encode, upload, download
from allmydata.util import hashutil, testutil
from allmydata.util.assertutil import _assert
from allmydata.interfaces import IStorageBucketWriter, IStorageBucketReader

View File

@ -1,6 +1,7 @@
from twisted.trial import unittest
from allmydata import filenode, uri, download
from allmydata import uri
from allmydata.immutable import filenode, download
from allmydata.mutable.node import MutableFileNode
from allmydata.util import hashutil

View File

@ -6,7 +6,8 @@ from twisted.application import service
from foolscap import Tub, eventual
from foolscap.logging import log
from allmydata import offloaded, storage, upload
from allmydata import offloaded, storage
from allmydata.immutable import upload
from allmydata.util import hashutil, fileutil, mathutil
from pycryptopp.cipher.aes import AES

View File

@ -4,12 +4,13 @@ from cStringIO import StringIO
from twisted.trial import unittest
from twisted.internet import defer, reactor
from twisted.python import failure
from allmydata import uri, download, storage
from allmydata import uri, storage
from allmydata.immutable import download
from allmydata.immutable.encode import NotEnoughSharesError
from allmydata.util import base32, testutil, idlib
from allmydata.util.idlib import shortnodeid_b2a
from allmydata.util.hashutil import tagged_hash
from allmydata.util.fileutil import make_dirs
from allmydata.encode import NotEnoughSharesError
from allmydata.interfaces import IURI, IMutableFileURI, IUploadable, \
FileTooLargeError
from foolscap.eventual import eventually, fireEventually

View File

@ -8,8 +8,8 @@ from twisted.internet import threads # CLI tests use deferToThread
from twisted.internet.error import ConnectionDone, ConnectionLost
from twisted.application import service
import allmydata
from allmydata import client, uri, download, upload, storage, offloaded, \
filenode
from allmydata import client, uri, storage, offloaded
from allmydata.immutable import download, upload, filenode
from allmydata.introducer.server import IntroducerNode
from allmydata.util import fileutil, idlib, mathutil, testutil
from allmydata.util import log, base32

View File

@ -6,7 +6,8 @@ from twisted.python import log
from twisted.internet import defer
from cStringIO import StringIO
from allmydata import upload, encode, uri
from allmydata import uri
from allmydata.immutable import upload, encode
from allmydata.interfaces import IFileURI, FileTooLargeError
from allmydata.util.assertutil import precondition
from allmydata.util.deferredutil import DeferredListShouldSucceed

View File

@ -5,7 +5,8 @@ from twisted.trial import unittest
from twisted.internet import defer, reactor
from twisted.web import client, error, http
from twisted.python import failure, log
from allmydata import interfaces, provisioning, uri, webish, upload, download
from allmydata import interfaces, provisioning, uri, webish
from allmydata.immutable import upload, download
from allmydata.web import status, common
from allmydata.util import fileutil
from allmydata.test.common import FakeDirectoryNode, FakeCHKFileNode, \

View File

@ -8,9 +8,9 @@ from twisted.internet import defer
from nevow import url, rend
from nevow.inevow import IRequest
from allmydata.upload import FileHandle
from allmydata.interfaces import IDownloadTarget, ExistingChildError
from allmydata.mutable.common import MODE_READ
from allmydata.immutable.upload import FileHandle
from allmydata.util import log
from allmydata.web.common import text_plain, WebError, IClient, RenderMixin, \

View File

@ -4,7 +4,7 @@ from twisted.web import http
from twisted.internet import defer
from nevow import rend, url, tags as T
from nevow.inevow import IRequest
from allmydata.upload import FileHandle
from allmydata.immutable.upload import FileHandle
from allmydata.web.common import IClient, getxmlfile, get_arg, boolean_of_arg
from allmydata.web import status