Merge lp:~nataliabidart/magicicada-server/fix-ubuntuone-paths into lp:magicicada-server

Proposed by Natalia Bidart
Status: Merged
Approved by: Natalia Bidart
Approved revision: 73
Merged at revision: 63
Proposed branch: lp:~nataliabidart/magicicada-server/fix-ubuntuone-paths
Merge into: lp:magicicada-server
Diff against target: 2053 lines (+309/-345)
94 files modified
.bzrignore (+1/-1)
Makefile (+2/-10)
dev-scripts/deploy_api_server.py (+1/-1)
dev-scripts/supervisor-dev.conf.tpl (+6/-6)
dev-scripts/supervisor_templates.py (+2/-2)
dev-scripts/user-mgr.py (+1/-1)
lib/ubuntuone/storage/__init__.py (+0/-17)
lib/ubuntuone/supervisor/heartbeat_listener.py (+1/-1)
lib/utilities/load_sample_data.py (+1/-1)
magicicada/filesync/admin.py (+3/-3)
magicicada/filesync/downloadservices.py (+4/-4)
magicicada/filesync/errors.py (+2/-1)
magicicada/filesync/management/commands/user_mgr.py (+1/-1)
magicicada/filesync/managers.py (+1/-1)
magicicada/filesync/migrations/0001_initial.py (+7/-7)
magicicada/filesync/models.py (+4/-4)
magicicada/filesync/notifier/notifier.py (+1/-1)
magicicada/filesync/notifier/testing/testcase.py (+1/-1)
magicicada/filesync/notifier/tests/test_notifier.py (+5/-5)
magicicada/filesync/resthelper.py (+4/-4)
magicicada/filesync/services.py (+4/-4)
magicicada/filesync/tests/test_admin.py (+2/-2)
magicicada/filesync/tests/test_dao.py (+3/-3)
magicicada/filesync/tests/test_downloadservices.py (+3/-3)
magicicada/filesync/tests/test_gateway.py (+21/-21)
magicicada/filesync/tests/test_models.py (+4/-4)
magicicada/filesync/tests/test_resthelper.py (+5/-5)
magicicada/filesync/tests/test_services.py (+4/-4)
magicicada/filesync/tests/test_utils.py (+2/-2)
magicicada/filesync/utilities/harness.py (+3/-3)
magicicada/filesync/utilities/make_abundant_files.py (+3/-2)
magicicada/filesync/utilities/make_test_storage_users.py (+1/-1)
magicicada/metrics/__init__.py (+1/-1)
magicicada/monitoring/reactor.py (+1/-1)
magicicada/monitoring/tests/test_dump.py (+1/-1)
magicicada/monitoring/tests/test_reactor.py (+3/-3)
magicicada/rpcdb/backend.py (+2/-2)
magicicada/rpcdb/inthread.py (+2/-2)
magicicada/rpcdb/tests/test_backend.py (+4/-4)
magicicada/server/auth.py (+2/-2)
magicicada/server/content.py (+4/-4)
magicicada/server/integration/integtests_basic.py (+1/-1)
magicicada/server/integration/integtests_udf.py (+2/-2)
magicicada/server/integration/run_integtests.py (+3/-3)
magicicada/server/integtests/test_action_queue.py (+2/-1)
magicicada/server/integtests/test_aq_cancel.py (+4/-4)
magicicada/server/integtests/test_capabilities.py (+4/-4)
magicicada/server/integtests/test_cleanup.py (+3/-2)
magicicada/server/integtests/test_server_scan.py (+3/-2)
magicicada/server/integtests/test_share_sync.py (+3/-3)
magicicada/server/integtests/test_sync.py (+6/-8)
magicicada/server/integtests/test_udf_sync.py (+2/-2)
magicicada/server/server.py (+9/-9)
magicicada/server/server.tac (+2/-2)
magicicada/server/ssl_proxy.py (+3/-3)
magicicada/server/ssl_proxy.tac (+2/-1)
magicicada/server/stats.py (+2/-1)
magicicada/server/testing/aq_helpers.py (+6/-6)
magicicada/server/testing/caps_helpers.py (+2/-1)
magicicada/server/testing/testcase.py (+8/-9)
magicicada/server/tests/test_account.py (+4/-4)
magicicada/server/tests/test_auth.py (+5/-6)
magicicada/server/tests/test_basic.py (+3/-2)
magicicada/server/tests/test_capabilities.py (+2/-2)
magicicada/server/tests/test_content.py (+10/-10)
magicicada/server/tests/test_diskstorage.py (+1/-1)
magicicada/server/tests/test_fileops.py (+4/-4)
magicicada/server/tests/test_generations.py (+4/-4)
magicicada/server/tests/test_make.py (+3/-3)
magicicada/server/tests/test_notify_delivery.py (+11/-12)
magicicada/server/tests/test_oops.py (+4/-4)
magicicada/server/tests/test_server.py (+7/-7)
magicicada/server/tests/test_sharing.py (+5/-6)
magicicada/server/tests/test_shutdown.py (+5/-5)
magicicada/server/tests/test_ssl_proxy.py (+4/-3)
magicicada/server/tests/test_stats.py (+2/-2)
magicicada/server/tests/test_throttling.py (+4/-4)
magicicada/server/tests/test_udfs.py (+5/-4)
magicicada/server/tests/test_upload.py (+5/-5)
magicicada/server/tests/test_validation.py (+2/-1)
magicicada/server/tests/test_volumes.py (+4/-4)
magicicada/server/upload.py (+3/-3)
magicicada/settings/__init__.py (+3/-4)
magicicada/testing/factory.py (+2/-2)
magicicada/testing/testcase.py (+2/-2)
magicicada/txlog/models.py (+2/-2)
magicicada/txlog/tests/test_models.py (+4/-4)
magicicada/txlog/tests/test_utils.py (+3/-3)
magicicada/txlog/utils.py (+1/-1)
magicicada/txutils/__init__.py (+1/-1)
magicicada/txutils/tests/test_retry.py (+2/-1)
magicicada/utils.py (+1/-1)
src/backends/__init__.py (+0/-17)
test (+1/-1)
To merge this branch: bzr merge lp:~nataliabidart/magicicada-server/fix-ubuntuone-paths
Reviewer Review Type Date Requested Status
Facundo Batista Approve
Review via email: mp+296006@code.launchpad.net

Commit message

- Renamed src/ folder to magicicada/, and fixed all import paths accordingly.

Description of the change

All tests passing!

This is an initial branch to cleanup dependencies and symlinks in lib/. The plan is to end up with env-only deps and thus removing the need to have the lib/ folder.

To post a comment you must log in.
70. By Natalia Bidart

Fixed import paths for txutils.

71. By Natalia Bidart

Merged trunk in.

72. By Natalia Bidart

Proper import ordering.

73. By Natalia Bidart

Fixed import in new file.

Revision history for this message
Facundo Batista (facundo) wrote :

Great!

review: Approve

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file '.bzrignore'
2--- .bzrignore 2015-09-17 19:37:18 +0000
3+++ .bzrignore 2016-06-03 20:58:39 +0000
4@@ -3,4 +3,4 @@
5 tmp/*
6 twistd.pid
7 .sourcecode/*
8-src/magicicada/settings/local.py
9+magicicada/settings/local.py
10
11=== modified file 'Makefile'
12--- Makefile 2016-05-31 22:59:18 +0000
13+++ Makefile 2016-06-03 20:58:39 +0000
14@@ -19,7 +19,7 @@
15 DJANGO_SETTINGS_MODULE ?= magicicada.settings
16 FLAKE8 = flake8
17 PYTHON = python
18-SRC_DIR = $(CURDIR)/src
19+SRC_DIR = $(CURDIR)/magicicada
20 LIB_DIR = $(CURDIR)/lib
21 ENV = $(CURDIR)/env
22 PYTHONPATH := $(SRC_DIR):$(LIB_DIR):$(CURDIR):$(PYTHONPATH)
23@@ -122,17 +122,9 @@
24 lint:
25 virtualenv $(ENV)
26 $(ENV)/bin/pip install flake8 rst2html5
27- $(ENV)/bin/flake8 --filename='*.py' --exclude='migrations' src
28+ $(ENV)/bin/flake8 --filename='*.py' --exclude='migrations' $(SRC_DIR)
29 dev-scripts/check_readme.sh
30
31-etags: sourcedeps
32- # Generate tags for emacs
33- ctags-exuberant -e -R --language-force=python -f tags lib src
34-
35-tags: sourcedeps
36- # Generate tags for vim
37- ctags-exuberant -R --language-force=python -f tags lib src
38-
39 version:
40 bzr version-info --format=python > lib/versioninfo.py || true
41
42
43=== modified file 'dev-scripts/deploy_api_server.py'
44--- dev-scripts/deploy_api_server.py 2015-09-26 13:02:01 +0000
45+++ dev-scripts/deploy_api_server.py 2016-06-03 20:58:39 +0000
46@@ -35,7 +35,7 @@
47 import _pythonpath # NOQA
48
49 from magicicada import settings
50-from ubuntuone.storage.server import server
51+from magicicada.server import server
52 from utilities import utils
53
54 tmp_dir = os.path.join(utils.get_rootdir(), 'tmp')
55
56=== modified file 'dev-scripts/supervisor-dev.conf.tpl'
57--- dev-scripts/supervisor-dev.conf.tpl 2016-05-31 03:44:10 +0000
58+++ dev-scripts/supervisor-dev.conf.tpl 2016-06-03 20:58:39 +0000
59@@ -25,20 +25,20 @@
60
61 [eventlistener:heartbeat]
62 command=python %(basepath)s/lib/ubuntuone/supervisor/heartbeat_listener.py --interval=10 --timeout=20 --log_level=DEBUG --log_file=%(tmp_dir)s/heartbeat.log --groups=filesync-dummy,filesync-oauth
63-environment=PYTHONPATH="%(basepath)s/lib"
64+environment=PYTHONPATH="%(basepath)s:%(basepath)s/lib"
65 events=PROCESS_COMMUNICATION,TICK_5
66 buffer_size=42
67
68 [program:filesync]
69-command=/usr/bin/twistd --pidfile %(tmp_dir)s/filesync.pid -n -y %(basepath)s/lib/ubuntuone/storage/server/server.tac --reactor=epoll
70-environment=PYTHONPATH="%(basepath)s/lib",DJANGO_SETTINGS_MODULE="magicicada.settings",PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=cpp
71+command=/usr/bin/twistd --pidfile %(tmp_dir)s/filesync.pid -n -y %(basepath)s/magicicada/server/server.tac --reactor=epoll
72+environment=PYTHONPATH="%(basepath)s:%(basepath)s/lib",DJANGO_SETTINGS_MODULE="magicicada.settings",PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=cpp
73 stdout_capture_maxbytes=16384
74 autostart=false
75 stopsignal=INT
76
77 [program:filesync-dummy-auth]
78 command=python %(basepath)s/dev-scripts/deploy_api_server.py
79-environment=PYTHONPATH="%(basepath)s/lib",DJANGO_SETTINGS_MODULE="magicicada.settings",PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=cpp
80+environment=PYTHONPATH="%(basepath)s:%(basepath)s/lib",DJANGO_SETTINGS_MODULE="magicicada.settings",PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=cpp
81 stdout_capture_maxbytes=16384
82 autostart=false
83 redirect_stderr=true ; send stderr to the log file
84@@ -46,8 +46,8 @@
85 stdout_logfile_maxbytes=0
86
87 [program:ssl-proxy]
88-command=/usr/bin/twistd --pidfile %(tmp_dir)s/ssl-proxy.pid -n -y %(basepath)s/lib/ubuntuone/storage/server/ssl_proxy.tac --reactor=epoll
89-environment=PYTHONPATH="%(basepath)s/lib",DJANGO_SETTINGS_MODULE="magicicada.settings"
90+command=/usr/bin/twistd --pidfile %(tmp_dir)s/ssl-proxy.pid -n -y %(basepath)s/magicicada/server/ssl_proxy.tac --reactor=epoll
91+environment=PYTHONPATH="%(basepath)s:%(basepath)s/lib",DJANGO_SETTINGS_MODULE="magicicada.settings"
92 stdout_capture_maxbytes=16384
93 autostart=false
94 stopsignal=INT
95
96=== modified file 'dev-scripts/supervisor_templates.py'
97--- dev-scripts/supervisor_templates.py 2015-09-17 20:29:43 +0000
98+++ dev-scripts/supervisor_templates.py 2016-06-03 20:58:39 +0000
99@@ -23,7 +23,7 @@
100 'command=%(basepath)s/dev-scripts/set_rlimits.sh -d %(fs_memory_limit)s '
101 '-m %(fs_memory_limit)s -v %(fs_memory_limit)s -n %(open_fds)s '
102 '/usr/bin/twistd --pidfile %(pid_folder)s/fsync_slave_%(instance)s.pid '
103- '-n -y %(basepath)s/lib/ubuntuone/storage/server/server.tac '
104+ '-n -y %(basepath)s/magicicada/server/server.tac '
105 '--reactor=epoll\n'
106 'environment=DJANGO_SETTINGS_MODULE="magicicada.settings",'
107 'PYTHONPATH="%(basepath)s/lib",'
108@@ -40,7 +40,7 @@
109 '-m %(ssl_memory_limit)s -v %(ssl_memory_limit)s -n %(open_fds)s '
110 '/usr/bin/twistd '
111 '--pidfile %(pid_folder)s/ssl-proxy-%(instance)s.pid '
112- '-n -y %(basepath)s/lib/ubuntuone/storage/server/ssl_proxy.tac '
113+ '-n -y %(basepath)s/magicicada/server/ssl_proxy.tac '
114 '--reactor=epoll\n'
115 'environment=DJANGO_SETTINGS_MODULE="magicicada.settings",'
116 'PYTHONPATH="%(basepath)s/lib",'
117
118=== modified file 'dev-scripts/user-mgr.py'
119--- dev-scripts/user-mgr.py 2015-09-27 23:50:09 +0000
120+++ dev-scripts/user-mgr.py 2016-06-03 20:58:39 +0000
121@@ -30,7 +30,7 @@
122
123 from django.contrib.auth.models import User
124
125-from backends.filesync import services
126+from magicicada.filesync import services
127
128
129 def create(args):
130
131=== removed symlink 'lib/backends'
132=== target was u'../src/backends/'
133=== removed symlink 'lib/magicicada'
134=== target was u'../src/magicicada/'
135=== added symlink 'lib/metrics'
136=== target is u'../magicicada/metrics/'
137=== removed symlink 'lib/metrics'
138=== target was u'../src/metrics/'
139=== removed symlink 'lib/ubuntuone/monitoring'
140=== target was u'../../src/monitoring/'
141=== removed directory 'lib/ubuntuone/storage'
142=== removed file 'lib/ubuntuone/storage/__init__.py'
143--- lib/ubuntuone/storage/__init__.py 2015-09-17 19:40:36 +0000
144+++ lib/ubuntuone/storage/__init__.py 1970-01-01 00:00:00 +0000
145@@ -1,17 +0,0 @@
146-# Copyright 2008-2015 Canonical
147-# Copyright 2015 Chicharreros (https://launchpad.net/~chicharreros)
148-#
149-# This program is free software: you can redistribute it and/or modify
150-# it under the terms of the GNU Affero General Public License as
151-# published by the Free Software Foundation, either version 3 of the
152-# License, or (at your option) any later version.
153-#
154-# This program is distributed in the hope that it will be useful,
155-# but WITHOUT ANY WARRANTY; without even the implied warranty of
156-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
157-# GNU Affero General Public License for more details.
158-#
159-# You should have received a copy of the GNU Affero General Public License
160-# along with this program. If not, see <http://www.gnu.org/licenses/>.
161-#
162-# For further info, check http://launchpad.net/magicicada-server
163
164=== removed symlink 'lib/ubuntuone/storage/rpcdb'
165=== target was u'../../../src/rpcdb/'
166=== removed symlink 'lib/ubuntuone/storage/server'
167=== target was u'../../../src/server/'
168=== modified file 'lib/ubuntuone/supervisor/heartbeat_listener.py'
169--- lib/ubuntuone/supervisor/heartbeat_listener.py 2015-09-17 19:40:36 +0000
170+++ lib/ubuntuone/supervisor/heartbeat_listener.py 2016-06-03 20:58:39 +0000
171@@ -35,7 +35,7 @@
172 from supervisor import childutils, states
173 from supervisor.events import EventTypes, getEventNameByType
174
175-from ubuntuone.storage.server.logger import configure_logger
176+from magicicada.server.logger import configure_logger
177
178
179 PROCESS_COMMUNICATION_STDOUT = \
180
181=== removed symlink 'lib/ubuntuone/txutils'
182=== target was u'../../src/txutils/'
183=== removed symlink 'lib/utilities'
184=== target was u'../src/utilities/'
185=== renamed directory 'src/utilities' => 'lib/utilities'
186=== modified file 'lib/utilities/load_sample_data.py'
187--- src/utilities/load_sample_data.py 2016-03-08 00:32:28 +0000
188+++ lib/utilities/load_sample_data.py 2016-06-03 20:58:39 +0000
189@@ -50,7 +50,7 @@
190
191 def main():
192 """Preload the website with some data."""
193- from backends.filesync import services
194+ from magicicada.filesync import services
195 # clear out existing data
196 delete_all_data()
197 for user_data in SAMPLE_USERS:
198
199=== renamed directory 'src' => 'magicicada'
200=== renamed file 'src/magicicada/__init__.py' => 'magicicada/__init__.py'
201=== renamed directory 'src/backends/filesync' => 'magicicada/filesync'
202=== modified file 'magicicada/filesync/admin.py'
203--- src/backends/filesync/admin.py 2016-03-10 23:12:30 +0000
204+++ magicicada/filesync/admin.py 2016-06-03 20:58:39 +0000
205@@ -22,9 +22,9 @@
206
207 from django.contrib import admin
208
209-from backends.filesync import services
210-from backends.filesync.dbmanager import fsync_readonly
211-from backends.filesync.models import StorageUser
212+from magicicada.filesync import services
213+from magicicada.filesync.dbmanager import fsync_readonly
214+from magicicada.filesync.models import StorageUser
215
216
217 class StorageUserFinder(object):
218
219=== modified file 'magicicada/filesync/downloadservices.py'
220--- src/backends/filesync/downloadservices.py 2016-03-07 19:01:17 +0000
221+++ magicicada/filesync/downloadservices.py 2016-06-03 20:58:39 +0000
222@@ -20,14 +20,14 @@
223
224 from __future__ import unicode_literals
225
226-from backends.filesync import errors
227-from backends.filesync.services import SystemGateway
228-from backends.filesync.dbmanager import (
229+from magicicada.filesync import errors
230+from magicicada.filesync.dbmanager import (
231 retryable_transaction,
232 fsync_commit,
233 fsync_readonly,
234 )
235-from backends.filesync.models import Download
236+from magicicada.filesync.models import Download
237+from magicicada.filesync.services import SystemGateway
238
239 # states
240 UNKNOWN = "Unknown"
241
242=== modified file 'magicicada/filesync/errors.py'
243--- src/backends/filesync/errors.py 2016-05-22 00:52:53 +0000
244+++ magicicada/filesync/errors.py 2016-06-03 20:58:39 +0000
245@@ -21,7 +21,8 @@
246 from __future__ import unicode_literals
247
248 from django.db import IntegrityError # noqa
249-from backends.filesync.dbmanager import RetryLimitReached # noqa
250+
251+from magicicada.filesync.dbmanager import RetryLimitReached # noqa
252
253
254 class StorageError(Exception):
255
256=== modified file 'magicicada/filesync/management/commands/user_mgr.py'
257--- src/backends/filesync/management/commands/user_mgr.py 2016-02-27 21:33:06 +0000
258+++ magicicada/filesync/management/commands/user_mgr.py 2016-06-03 20:58:39 +0000
259@@ -25,7 +25,7 @@
260 from django.contrib.auth import get_user_model
261 from django.core.management.base import BaseCommand, CommandError
262
263-from backends.filesync import services
264+from magicicada.filesync import services
265
266
267 User = get_user_model()
268
269=== modified file 'magicicada/filesync/managers.py'
270--- src/backends/filesync/managers.py 2016-03-09 22:47:59 +0000
271+++ magicicada/filesync/managers.py 2016-06-03 20:58:39 +0000
272@@ -28,7 +28,7 @@
273 from django.db import models
274 from django.core.exceptions import ValidationError
275
276-from backends.filesync.errors import (
277+from magicicada.filesync.errors import (
278 InvalidFilename,
279 InvalidVolumePath,
280 LockedUserError,
281
282=== modified file 'magicicada/filesync/migrations/0001_initial.py'
283--- src/backends/filesync/migrations/0001_initial.py 2016-05-20 23:23:28 +0000
284+++ magicicada/filesync/migrations/0001_initial.py 2016-06-03 20:58:39 +0000
285@@ -2,7 +2,7 @@
286 # Generated by Django 1.9 on 2016-05-02 00:13
287 from __future__ import unicode_literals
288
289-import backends.filesync.managers
290+import magicicada.filesync.managers
291 from django.conf import settings
292 import django.core.validators
293 from django.db import migrations, models
294@@ -24,7 +24,7 @@
295 name='ShareVolumeDelta',
296 fields=[
297 ('id', models.UUIDField(default=uuid.uuid4, primary_key=True, serialize=False)),
298- ('name', models.TextField(validators=[backends.filesync.managers.validate_name])),
299+ ('name', models.TextField(validators=[magicicada.filesync.managers.validate_name])),
300 ('kind', models.CharField(choices=[('File', 'File'), ('Directory', 'Directory'), ('Symlink', 'Symlink')], max_length=128)),
301 ('when_created', models.DateTimeField(default=django.utils.timezone.now)),
302 ('when_last_modified', models.DateTimeField(default=django.utils.timezone.now)),
303@@ -70,7 +70,7 @@
304 'verbose_name_plural': 'users',
305 },
306 managers=[
307- ('objects', backends.filesync.managers.StorageUserManager()),
308+ ('objects', magicicada.filesync.managers.StorageUserManager()),
309 ],
310 ),
311 migrations.CreateModel(
312@@ -103,7 +103,7 @@
313 name='MoveFromShare',
314 fields=[
315 ('id', models.UUIDField(default=uuid.uuid4, primary_key=True, serialize=False)),
316- ('name', models.TextField(validators=[backends.filesync.managers.validate_name])),
317+ ('name', models.TextField(validators=[magicicada.filesync.managers.validate_name])),
318 ('kind', models.CharField(choices=[('File', 'File'), ('Directory', 'Directory'), ('Symlink', 'Symlink')], max_length=128)),
319 ('when_created', models.DateTimeField(default=django.utils.timezone.now)),
320 ('when_last_modified', models.DateTimeField(default=django.utils.timezone.now)),
321@@ -141,7 +141,7 @@
322 fields=[
323 ('id', models.UUIDField(default=uuid.uuid4, primary_key=True, serialize=False)),
324 ('email', models.TextField(blank=True)),
325- ('name', models.TextField(validators=[backends.filesync.managers.validate_name])),
326+ ('name', models.TextField(validators=[magicicada.filesync.managers.validate_name])),
327 ('accepted', models.BooleanField(default=False)),
328 ('access', models.CharField(choices=[('View', 'View'), ('Modify', 'Modify')], max_length=128)),
329 ('when_shared', models.DateTimeField(default=django.utils.timezone.now)),
330@@ -155,7 +155,7 @@
331 name='StorageObject',
332 fields=[
333 ('id', models.UUIDField(default=uuid.uuid4, primary_key=True, serialize=False)),
334- ('name', models.TextField(validators=[backends.filesync.managers.validate_name])),
335+ ('name', models.TextField(validators=[magicicada.filesync.managers.validate_name])),
336 ('kind', models.CharField(choices=[('File', 'File'), ('Directory', 'Directory'), ('Symlink', 'Symlink')], max_length=128)),
337 ('when_created', models.DateTimeField(default=django.utils.timezone.now)),
338 ('when_last_modified', models.DateTimeField(default=django.utils.timezone.now)),
339@@ -191,7 +191,7 @@
340 name='UserVolume',
341 fields=[
342 ('id', models.UUIDField(default=uuid.uuid4, primary_key=True, serialize=False)),
343- ('path', models.TextField(validators=[backends.filesync.managers.validate_volume_path])),
344+ ('path', models.TextField(validators=[magicicada.filesync.managers.validate_volume_path])),
345 ('when_created', models.DateTimeField(default=django.utils.timezone.now)),
346 ('status', models.CharField(choices=[('Dead', 'Dead'), ('Live', 'Live')], default='Live', max_length=128)),
347 ('generation', models.BigIntegerField(default=0)),
348
349=== modified file 'magicicada/filesync/models.py'
350--- src/backends/filesync/models.py 2016-05-22 17:11:03 +0000
351+++ magicicada/filesync/models.py 2016-06-03 20:58:39 +0000
352@@ -34,8 +34,8 @@
353 from django.dispatch import receiver
354 from django.utils.timezone import now
355
356-from backends.filesync import utils
357-from backends.filesync.errors import (
358+from magicicada.filesync import utils
359+from magicicada.filesync.errors import (
360 DirectoriesHaveNoContent,
361 InvalidFilename,
362 NoPermission,
363@@ -43,7 +43,7 @@
364 NotEmpty,
365 QuotaExceeded,
366 )
367-from backends.filesync.managers import (
368+from magicicada.filesync.managers import (
369 ROOT_NAME,
370 ROOT_PARENT,
371 STATUS_LIVE,
372@@ -57,7 +57,7 @@
373 validate_name,
374 validate_volume_path,
375 )
376-from backends.filesync.signals import (
377+from magicicada.filesync.signals import (
378 content_changed,
379 node_moved,
380 post_kill,
381
382=== modified file 'magicicada/filesync/notifier/notifier.py'
383--- src/backends/filesync/notifier/notifier.py 2016-05-20 23:22:16 +0000
384+++ magicicada/filesync/notifier/notifier.py 2016-06-03 20:58:39 +0000
385@@ -27,7 +27,7 @@
386 from django.db import transaction
387 from twisted.internet import reactor
388
389-from backends.filesync.dbmanager import on_rollback
390+from magicicada.filesync.dbmanager import on_rollback
391
392
393 class EventTypeDescriptor(object):
394
395=== modified file 'magicicada/filesync/notifier/testing/testcase.py'
396--- src/backends/filesync/notifier/testing/testcase.py 2015-09-17 22:40:00 +0000
397+++ magicicada/filesync/notifier/testing/testcase.py 2016-06-03 20:58:39 +0000
398@@ -23,7 +23,7 @@
399
400 from __future__ import unicode_literals
401
402-from backends.filesync.notifier.notifier import event_classes
403+from magicicada.filesync.notifier.notifier import event_classes
404
405
406 class FakeNotifier(object):
407
408=== modified file 'magicicada/filesync/notifier/tests/test_notifier.py'
409--- src/backends/filesync/notifier/tests/test_notifier.py 2016-05-20 23:22:16 +0000
410+++ magicicada/filesync/notifier/tests/test_notifier.py 2016-06-03 20:58:39 +0000
411@@ -23,10 +23,10 @@
412 import unittest
413 import uuid
414
415-from backends.filesync.dbmanager import fsync_commit
416-from backends.filesync.models import Share
417-from backends.filesync.notifier import notifier
418-from backends.filesync.notifier.notifier import (
419+from magicicada.filesync.dbmanager import fsync_commit
420+from magicicada.filesync.models import Share
421+from magicicada.filesync.notifier import notifier
422+from magicicada.filesync.notifier.notifier import (
423 EventNotifier,
424 PendingNotifications,
425 ShareAccepted,
426@@ -37,7 +37,7 @@
427 UDFDelete,
428 VolumeNewGeneration,
429 )
430-from backends.testing.testcase import BaseTestCase
431+from magicicada.testing.testcase import BaseTestCase
432
433
434 class FakeNode(object):
435
436=== modified file 'magicicada/filesync/resthelper.py'
437--- src/backends/filesync/resthelper.py 2016-02-27 21:32:32 +0000
438+++ magicicada/filesync/resthelper.py 2016-06-03 20:58:39 +0000
439@@ -24,10 +24,10 @@
440
441 from django.conf import settings
442
443-from backends.filesync import errors
444-from backends.filesync.logging import log_dal_function
445-from backends.filesync.models import STATUS_LIVE, StorageObject
446-from backends.filesync.services import VolumeProxy
447+from magicicada.filesync import errors
448+from magicicada.filesync.logging import log_dal_function
449+from magicicada.filesync.models import STATUS_LIVE, StorageObject
450+from magicicada.filesync.services import VolumeProxy
451
452
453 def date_formatter(dt):
454
455=== modified file 'magicicada/filesync/services.py'
456--- src/backends/filesync/services.py 2016-05-31 22:59:18 +0000
457+++ magicicada/filesync/services.py 2016-06-03 20:58:39 +0000
458@@ -40,15 +40,15 @@
459 from django.db import connection, models
460 from django.utils.timezone import now
461
462-from backends.filesync import errors, utils
463-from backends.filesync.dbmanager import (
464+from magicicada.filesync import errors, utils
465+from magicicada.filesync.dbmanager import (
466 fsync_readonly,
467 fsync_readonly_slave,
468 fsync_commit,
469 get_object_or_none,
470 retryable_transaction,
471 )
472-from backends.filesync.models import (
473+from magicicada.filesync.models import (
474 DEFAULT_QUOTA_BYTES,
475 ROOT_PARENT,
476 STATUS_LIVE,
477@@ -63,7 +63,7 @@
478 UploadJob,
479 UserVolume,
480 )
481-from backends.filesync.notifier.notifier import get_notifier
482+from magicicada.filesync.notifier.notifier import get_notifier
483
484
485 # original dao.py starts here
486
487=== modified file 'magicicada/filesync/tests/test_admin.py'
488--- src/backends/filesync/tests/test_admin.py 2016-02-27 21:32:32 +0000
489+++ magicicada/filesync/tests/test_admin.py 2016-06-03 20:58:39 +0000
490@@ -20,8 +20,8 @@
491
492 from __future__ import unicode_literals
493
494-from backends.filesync import admin, services
495-from backends.testing.testcase import BaseTestCase
496+from magicicada.filesync import admin, services
497+from magicicada.testing.testcase import BaseTestCase
498
499
500 class AdminServicesTestCase(BaseTestCase):
501
502=== modified file 'magicicada/filesync/tests/test_dao.py'
503--- src/backends/filesync/tests/test_dao.py 2016-03-10 23:36:33 +0000
504+++ magicicada/filesync/tests/test_dao.py 2016-06-03 20:58:39 +0000
505@@ -27,14 +27,14 @@
506 from django.conf import settings
507 from mocker import Mocker, expect
508
509-from backends.filesync import errors, services, utils
510-from backends.filesync.models import (
511+from magicicada.filesync import errors, services, utils
512+from magicicada.filesync.models import (
513 STATUS_LIVE,
514 STATUS_DEAD,
515 ContentBlob,
516 StorageObject,
517 )
518-from backends.testing.testcase import BaseTestCase
519+from magicicada.testing.testcase import BaseTestCase
520
521
522 class StorageDALTestCase(BaseTestCase):
523
524=== modified file 'magicicada/filesync/tests/test_downloadservices.py'
525--- src/backends/filesync/tests/test_downloadservices.py 2016-02-27 21:32:32 +0000
526+++ magicicada/filesync/tests/test_downloadservices.py 2016-06-03 20:58:39 +0000
527@@ -22,9 +22,9 @@
528
529 import uuid
530
531-from backends.filesync import downloadservices, services
532-from backends.filesync.models import Download
533-from backends.testing.testcase import BaseTestCase
534+from magicicada.filesync import downloadservices, services
535+from magicicada.filesync.models import Download
536+from magicicada.testing.testcase import BaseTestCase
537
538
539 class DownloadServicesTestCase(BaseTestCase):
540
541=== modified file 'magicicada/filesync/tests/test_gateway.py'
542--- src/backends/filesync/tests/test_gateway.py 2016-05-20 23:23:28 +0000
543+++ magicicada/filesync/tests/test_gateway.py 2016-06-03 20:58:39 +0000
544@@ -32,25 +32,9 @@
545 from django.db import IntegrityError
546 from django.utils.timezone import now
547
548-from backends.filesync.dbmanager import fsync_commit
549-from backends.filesync.services import (
550- DAODownload,
551- DAOStorageUser,
552- DAOUserVolume,
553- DirectoryNode,
554- FileNode,
555- GatewayBase,
556- ReadWriteVolumeGateway,
557- SharedDirectory,
558- StorageUserGateway,
559- SystemGateway,
560- fix_all_udfs_with_generation_out_of_sync,
561- fix_udfs_with_generation_out_of_sync,
562- make_storage_user,
563- timing_metric,
564-)
565-from backends.filesync import errors, utils
566-from backends.filesync.models import (
567+from magicicada.filesync import errors, utils
568+from magicicada.filesync.dbmanager import fsync_commit
569+from magicicada.filesync.models import (
570 STATUS_DEAD,
571 STATUS_LIVE,
572 ContentBlob,
573@@ -61,7 +45,7 @@
574 StorageUser,
575 UploadJob,
576 )
577-from backends.filesync.notifier.notifier import (
578+from magicicada.filesync.notifier.notifier import (
579 EventNotifier,
580 ShareAccepted,
581 ShareCreated,
582@@ -71,7 +55,23 @@
583 UDFDelete,
584 VolumeNewGeneration,
585 )
586-from backends.testing.testcase import BaseTestCase
587+from magicicada.filesync.services import (
588+ DAODownload,
589+ DAOStorageUser,
590+ DAOUserVolume,
591+ DirectoryNode,
592+ FileNode,
593+ GatewayBase,
594+ ReadWriteVolumeGateway,
595+ SharedDirectory,
596+ StorageUserGateway,
597+ SystemGateway,
598+ fix_all_udfs_with_generation_out_of_sync,
599+ fix_udfs_with_generation_out_of_sync,
600+ make_storage_user,
601+ timing_metric,
602+)
603+from magicicada.testing.testcase import BaseTestCase
604
605
606 class FakeShare(object):
607
608=== modified file 'magicicada/filesync/tests/test_models.py'
609--- src/backends/filesync/tests/test_models.py 2016-03-10 22:54:38 +0000
610+++ magicicada/filesync/tests/test_models.py 2016-06-03 20:58:39 +0000
611@@ -37,8 +37,8 @@
612 from django.test import TransactionTestCase
613 from django.utils.timezone import now
614
615-from backends.filesync import errors
616-from backends.filesync.models import (
617+from magicicada.filesync import errors
618+from magicicada.filesync.models import (
619 ROOT_NAME,
620 STATUS_LIVE,
621 STATUS_DEAD,
622@@ -53,8 +53,8 @@
623 UserVolume,
624 validate_name,
625 )
626-from backends.testing.factory import Factory
627-from backends.testing.testcase import BaseTestCase
628+from magicicada.testing.factory import Factory
629+from magicicada.testing.testcase import BaseTestCase
630
631
632 class SelectForUpdateTestCase(TransactionTestCase):
633
634=== modified file 'magicicada/filesync/tests/test_resthelper.py'
635--- src/backends/filesync/tests/test_resthelper.py 2016-03-07 19:01:17 +0000
636+++ magicicada/filesync/tests/test_resthelper.py 2016-06-03 20:58:39 +0000
637@@ -30,10 +30,9 @@
638 from django.utils.timezone import now
639
640 from metrics.tests import FakeMetrics
641-from backends.filesync import errors
642-from backends.filesync.models import STATUS_LIVE, StorageObject
643-from backends.testing.testcase import BaseTestCase
644-from backends.filesync.resthelper import (
645+from magicicada.filesync import errors
646+from magicicada.filesync.models import STATUS_LIVE, StorageObject
647+from magicicada.filesync.resthelper import (
648 CannotPublishDirectory,
649 FileNodeHasNoChildren,
650 InvalidKind,
651@@ -41,7 +40,8 @@
652 RestHelper,
653 date_formatter,
654 )
655-from backends.filesync.services import make_storage_user
656+from magicicada.filesync.services import make_storage_user
657+from magicicada.testing.testcase import BaseTestCase
658 from ubuntuone.devtools.handlers import MementoHandler
659
660
661
662=== modified file 'magicicada/filesync/tests/test_services.py'
663--- src/backends/filesync/tests/test_services.py 2016-03-07 19:01:17 +0000
664+++ magicicada/filesync/tests/test_services.py 2016-06-03 20:58:39 +0000
665@@ -24,9 +24,9 @@
666
667 from django.utils.timezone import now
668
669-from backends.filesync import errors
670-from backends.filesync.models import StorageUser
671-from backends.filesync.services import (
672+from magicicada.filesync import errors
673+from magicicada.filesync.models import StorageUser
674+from magicicada.filesync.services import (
675 DAOStorageUser,
676 get_abandoned_uploadjobs,
677 get_node,
678@@ -35,7 +35,7 @@
679 get_storage_user,
680 make_storage_user,
681 )
682-from backends.testing.testcase import BaseTestCase
683+from magicicada.testing.testcase import BaseTestCase
684
685
686 MAX_STORAGE_BYTES = 10 * 23
687
688=== modified file 'magicicada/filesync/tests/test_utils.py'
689--- src/backends/filesync/tests/test_utils.py 2016-03-07 19:01:17 +0000
690+++ magicicada/filesync/tests/test_utils.py 2016-06-03 20:58:39 +0000
691@@ -16,7 +16,7 @@
692 #
693 # For further info, check http://launchpad.net/magicicada-server
694
695-"""Tests for backends.filesync.utils."""
696+"""Tests for filesync utils."""
697
698 from __future__ import unicode_literals
699
700@@ -25,7 +25,7 @@
701
702 from django.conf import settings
703
704-from backends.filesync.utils import (
705+from magicicada.filesync.utils import (
706 decode_base62,
707 decode_uuid,
708 encode_base62,
709
710=== modified file 'magicicada/filesync/utilities/harness.py'
711--- src/backends/filesync/utilities/harness.py 2016-02-27 21:32:32 +0000
712+++ magicicada/filesync/utilities/harness.py 2016-06-03 20:58:39 +0000
713@@ -22,9 +22,9 @@
714
715 from __future__ import unicode_literals
716
717-from backends.filesync.notifier.notifier import register_notifier_for_bus
718-from backends.filesync.notifier.testing.testcase import AccumulatingNotifyBus
719-from backends.filesync import services # NOQA
720+from magicicada.filesync import services # NOQA
721+from magicicada.filesync.notifier.notifier import register_notifier_for_bus
722+from magicicada.filesync.notifier.testing.testcase import AccumulatingNotifyBus
723
724 nb = AccumulatingNotifyBus()
725 register_notifier_for_bus(nb)
726
727=== modified file 'magicicada/filesync/utilities/make_abundant_files.py'
728--- src/backends/filesync/utilities/make_abundant_files.py 2016-02-20 17:03:19 +0000
729+++ magicicada/filesync/utilities/make_abundant_files.py 2016-06-03 20:58:39 +0000
730@@ -29,8 +29,9 @@
731 import _pythonpath # NOQA
732
733 from twisted.python.util import makeStatBar
734-from backends.filesync.services import get_storage_user
735-from backends.filesync.tests.testcase import Factory
736+
737+from magicicada.filesync.services import get_storage_user
738+from magicicada.filesync.tests.testcase import Factory
739
740
741 def utf2unicode(s):
742
743=== modified file 'magicicada/filesync/utilities/make_test_storage_users.py'
744--- src/backends/filesync/utilities/make_test_storage_users.py 2016-02-27 21:32:32 +0000
745+++ magicicada/filesync/utilities/make_test_storage_users.py 2016-06-03 20:58:39 +0000
746@@ -36,7 +36,7 @@
747
748 from utilities import userutils
749 import uuid
750- from backends.filesync.services import make_storage_user
751+ from magicicada.filesync.services import make_storage_user
752
753 token_data = {}
754 for i in range(int(options.count)):
755
756=== modified file 'magicicada/metrics/__init__.py'
757--- src/metrics/__init__.py 2016-05-31 22:59:18 +0000
758+++ magicicada/metrics/__init__.py 2016-06-03 20:58:39 +0000
759@@ -27,7 +27,7 @@
760
761 from django.conf import settings
762
763-from ubuntuone.storage.server.logger import configure_logger
764+from magicicada.server.logger import configure_logger
765
766
767 class FileBasedMeter(object):
768
769=== modified file 'magicicada/monitoring/reactor.py'
770--- src/monitoring/reactor.py 2016-05-31 22:59:18 +0000
771+++ magicicada/monitoring/reactor.py 2016-06-03 20:58:39 +0000
772@@ -29,7 +29,7 @@
773
774 import metrics
775
776-from ubuntuone.storage.server.logger import TRACE
777+from magicicada.server.logger import TRACE
778
779
780 class ReactorInspector(threading.Thread):
781
782=== modified file 'magicicada/monitoring/tests/test_dump.py'
783--- src/monitoring/tests/test_dump.py 2016-03-07 19:01:17 +0000
784+++ magicicada/monitoring/tests/test_dump.py 2016-06-03 20:58:39 +0000
785@@ -27,7 +27,7 @@
786 from django.conf import settings
787 from mocker import MockerTestCase, ANY
788
789-from ubuntuone.monitoring.dump import gc_dump, meliae_dump
790+from magicicada.monitoring.dump import gc_dump, meliae_dump
791
792
793 class TestDump(MockerTestCase):
794
795=== modified file 'magicicada/monitoring/tests/test_reactor.py'
796--- src/monitoring/tests/test_reactor.py 2016-05-31 22:59:18 +0000
797+++ magicicada/monitoring/tests/test_reactor.py 2016-06-03 20:58:39 +0000
798@@ -26,12 +26,12 @@
799
800 from twisted.trial.unittest import TestCase as TwistedTestCase
801 from twisted.internet import reactor, defer
802+from ubuntuone.devtools.handlers import MementoHandler
803
804 import metrics
805
806-from ubuntuone.storage.server.logger import TRACE
807-from ubuntuone.devtools.handlers import MementoHandler
808-from ubuntuone.monitoring.reactor import ReactorInspector
809+from magicicada.monitoring.reactor import ReactorInspector
810+from magicicada.server.logger import TRACE
811
812
813 class ReactorInspectorTestCase(TwistedTestCase):
814
815=== modified file 'magicicada/rpcdb/backend.py'
816--- src/rpcdb/backend.py 2016-05-20 23:22:56 +0000
817+++ magicicada/rpcdb/backend.py 2016-06-03 20:58:39 +0000
818@@ -24,8 +24,8 @@
819
820 from django.contrib.auth import authenticate
821
822-from backends.filesync import services, errors
823-from backends.filesync.models import STATUS_LIVE, StorageObject
824+from magicicada.filesync import services, errors
825+from magicicada.filesync.models import STATUS_LIVE, StorageObject
826
827
828 class FailedAuthentication(Exception):
829
830=== modified file 'magicicada/rpcdb/inthread.py'
831--- src/rpcdb/inthread.py 2016-05-21 19:58:46 +0000
832+++ magicicada/rpcdb/inthread.py 2016-06-03 20:58:39 +0000
833@@ -26,7 +26,7 @@
834
835 from twisted.internet import defer, threads
836
837-from ubuntuone.storage.rpcdb import backend
838+from magicicada.rpcdb import backend
839
840
841 # log setup
842@@ -39,7 +39,7 @@
843 def __init__(self):
844 super(ThreadedNonRPC, self).__init__()
845 self.backend = backend.DAL()
846- if int(os.getenv('MAGICICADA_DEBUG')):
847+ if int(os.getenv('MAGICICADA_DEBUG', '0')):
848 self.defer = defer.maybeDeferred
849 else:
850 self.defer = threads.deferToThread
851
852=== modified file 'magicicada/rpcdb/tests/test_backend.py'
853--- src/rpcdb/tests/test_backend.py 2016-05-20 23:22:56 +0000
854+++ magicicada/rpcdb/tests/test_backend.py 2016-06-03 20:58:39 +0000
855@@ -25,14 +25,14 @@
856 from twisted.internet import defer
857 from mocker import Mocker, expect, KWARGS
858
859-from backends.filesync import errors
860-from backends.filesync.models import (
861+from magicicada.filesync import errors
862+from magicicada.filesync.models import (
863 STATUS_LIVE,
864 STATUS_DEAD,
865 StorageObject,
866 )
867-from backends.testing.testcase import BaseTestCase
868-from ubuntuone.storage.rpcdb import backend
869+from magicicada.rpcdb import backend
870+from magicicada.testing.testcase import BaseTestCase
871
872
873 class DALTestCase(BaseTestCase):
874
875=== modified file 'magicicada/server/auth.py'
876--- src/server/auth.py 2016-05-20 23:29:29 +0000
877+++ magicicada/server/auth.py 2016-06-03 20:58:39 +0000
878@@ -22,8 +22,8 @@
879
880 from twisted.internet import defer
881
882-from backends.filesync.errors import DoesNotExist
883-from ubuntuone.storage.rpcdb import backend
884+from magicicada.filesync.errors import DoesNotExist
885+from magicicada.rpcdb import backend
886
887
888 logger = logging.getLogger("storage.server")
889
890=== modified file 'magicicada/server/content.py'
891--- src/server/content.py 2016-05-20 23:29:29 +0000
892+++ magicicada/server/content.py 2016-06-03 20:58:39 +0000
893@@ -32,12 +32,12 @@
894 import twisted.web.error
895
896 from twisted.internet import defer
897+from ubuntuone.storageprotocol import protocol_pb2
898
899-from backends.filesync import errors as dataerrors
900-from backends.filesync.models import Share
901 from magicicada import settings
902-from ubuntuone.storage.server import errors, upload
903-from ubuntuone.storageprotocol import protocol_pb2
904+from magicicada.filesync import errors as dataerrors
905+from magicicada.filesync.models import Share
906+from magicicada.server import errors, upload
907
908 ZERO_LENGTH_CONTENT_KEY = ""
909
910
911=== modified file 'magicicada/server/integration/integtests_basic.py'
912--- src/server/integration/integtests_basic.py 2015-09-20 20:59:14 +0000
913+++ magicicada/server/integration/integtests_basic.py 2016-06-03 20:58:39 +0000
914@@ -26,7 +26,7 @@
915
916 from twisted.internet import defer
917
918-from ubuntuone.storage.server.integration.helpers import (
919+from magicicada.server.integration.helpers import (
920 create_file_and_add_content,
921 debug,
922 walk_and_list_dir,
923
924=== modified file 'magicicada/server/integration/integtests_udf.py'
925--- src/server/integration/integtests_udf.py 2015-09-27 17:01:04 +0000
926+++ magicicada/server/integration/integtests_udf.py 2016-06-03 20:58:39 +0000
927@@ -28,8 +28,8 @@
928 from ubuntuone.platform.linux import tools
929 from twisted.internet import defer
930
931-from backends.filesync.models import Share
932-from ubuntuone.storage.server.integration.helpers import (
933+from magicicada.filesync.models import Share
934+from magicicada.server.integration.helpers import (
935 create_file_and_add_content,
936 debug,
937 walk_and_list_dir,
938
939=== modified file 'magicicada/server/integration/run_integtests.py'
940--- src/server/integration/run_integtests.py 2016-02-27 21:32:32 +0000
941+++ magicicada/server/integration/run_integtests.py 2016-06-03 20:58:39 +0000
942@@ -39,10 +39,10 @@
943 from django.conf import settings
944 from utilities import utils, dev_launcher
945 from twisted.internet import reactor, defer
946-
947-from backends.filesync import services
948 from ubuntuone.platform.linux import tools
949-from ubuntuone.storage.server.integration.helpers import debug, retryable
950+
951+from magicicada.filesync import services
952+from magicicada.server.integration.helpers import debug, retryable
953
954 # to make dbus work
955 dbus.mainloop.glib.DBusGMainLoop(set_as_default=True)
956
957=== modified file 'magicicada/server/integtests/test_action_queue.py'
958--- src/server/integtests/test_action_queue.py 2016-03-09 20:55:02 +0000
959+++ magicicada/server/integtests/test_action_queue.py 2016-06-03 20:58:39 +0000
960@@ -39,7 +39,8 @@
961 dns_client,
962 )
963 from ubuntuone.syncdaemon.marker import MDMarker as Marker
964-from ubuntuone.storage.server.testing.aq_helpers import (
965+
966+from magicicada.server.testing.aq_helpers import (
967 FakeFailure,
968 FakeResolver,
969 NO_CONTENT_HASH,
970
971=== modified file 'magicicada/server/integtests/test_aq_cancel.py'
972--- src/server/integtests/test_aq_cancel.py 2015-09-18 23:36:43 +0000
973+++ magicicada/server/integtests/test_aq_cancel.py 2016-06-03 20:58:39 +0000
974@@ -23,9 +23,11 @@
975 from cStringIO import StringIO
976
977 from twisted.internet import defer, error
978-
979 from ubuntuone.storageprotocol import request
980-from ubuntuone.storage.server.testing.aq_helpers import (
981+from ubuntuone.storageprotocol.content_hash import content_hash_factory, crc32
982+from ubuntuone.syncdaemon.marker import MDMarker as Marker
983+
984+from magicicada.server.testing.aq_helpers import (
985 FakeGetContent,
986 NO_CONTENT_HASH,
987 TestContentBase,
988@@ -33,8 +35,6 @@
989 anEmptyShareList,
990 anUUID,
991 )
992-from ubuntuone.storageprotocol.content_hash import content_hash_factory, crc32
993-from ubuntuone.syncdaemon.marker import MDMarker as Marker
994
995
996 class AQCancelTestBase(TestContentBase):
997
998=== modified file 'magicicada/server/integtests/test_capabilities.py'
999--- src/server/integtests/test_capabilities.py 2016-03-09 18:57:35 +0000
1000+++ magicicada/server/integtests/test_capabilities.py 2016-06-03 20:58:39 +0000
1001@@ -23,14 +23,14 @@
1002 from twisted.trial.unittest import TestCase
1003 from twisted.trial.reporter import TestResult
1004 from twisted.internet import defer
1005+from ubuntuone import syncdaemon
1006
1007-from ubuntuone.storage.server.testing.caps_helpers import required_caps
1008-from ubuntuone.storage.server.testing.aq_helpers import (
1009+from magicicada.server import server as server_module
1010+from magicicada.server.testing.caps_helpers import required_caps
1011+from magicicada.server.testing.aq_helpers import (
1012 TestWithDatabase,
1013 failure_expected,
1014 )
1015-from ubuntuone.storage.server import server as server_module
1016-from ubuntuone import syncdaemon
1017
1018
1019 class RequiredCapsDecoratorTests(TestCase):
1020
1021=== modified file 'magicicada/server/integtests/test_cleanup.py'
1022--- src/server/integtests/test_cleanup.py 2015-09-18 23:36:43 +0000
1023+++ magicicada/server/integtests/test_cleanup.py 2016-06-03 20:58:39 +0000
1024@@ -21,7 +21,9 @@
1025 import os
1026
1027 from twisted.internet import reactor, defer
1028-from ubuntuone.storage.server.testing.aq_helpers import (
1029+from ubuntuone.storageprotocol import request
1030+
1031+from magicicada.server.testing.aq_helpers import (
1032 NO_CONTENT_HASH,
1033 NoCloseStringIO,
1034 TestContentBase,
1035@@ -29,7 +31,6 @@
1036 anUUID,
1037 failure_ignore,
1038 )
1039-from ubuntuone.storageprotocol import request
1040
1041 defer.setDebugging(True)
1042
1043
1044=== modified file 'magicicada/server/integtests/test_server_scan.py'
1045--- src/server/integtests/test_server_scan.py 2015-09-18 23:36:43 +0000
1046+++ magicicada/server/integtests/test_server_scan.py 2016-06-03 20:58:39 +0000
1047@@ -26,11 +26,12 @@
1048 from twisted.internet import defer
1049
1050 from ubuntuone.storageprotocol import request
1051-from test_sync import TestServerBase
1052 from ubuntuone.storageprotocol.content_hash import content_hash_factory, crc32
1053-from ubuntuone.storage.server.testing.aq_helpers import NO_CONTENT_HASH
1054 from ubuntuone.devtools.handlers import MementoHandler
1055
1056+from magicicada.server.integtests.test_sync import TestServerBase
1057+from magicicada.server.testing.aq_helpers import NO_CONTENT_HASH
1058+
1059
1060 class TestServerScan(TestServerBase):
1061 """Basic tests of the server rescan."""
1062
1063=== modified file 'magicicada/server/integtests/test_share_sync.py'
1064--- src/server/integtests/test_share_sync.py 2016-02-26 20:23:27 +0000
1065+++ magicicada/server/integtests/test_share_sync.py 2016-06-03 20:58:39 +0000
1066@@ -25,12 +25,12 @@
1067
1068 from twisted.internet import reactor, defer
1069 from twisted.python.failure import Failure
1070-
1071-from ubuntuone.storage.server.integtests import test_sync
1072-from ubuntuone.storage.server.testing.aq_helpers import NO_CONTENT_HASH
1073 from ubuntuone.storageprotocol import request
1074 from ubuntuone.syncdaemon import states
1075
1076+from magicicada.server.integtests import test_sync
1077+from magicicada.server.testing.aq_helpers import NO_CONTENT_HASH
1078+
1079
1080 class TestSharesSync(test_sync.TestSync):
1081 """Base class for shares tests."""
1082
1083=== modified file 'magicicada/server/integtests/test_sync.py'
1084--- src/server/integtests/test_sync.py 2016-03-09 20:55:02 +0000
1085+++ magicicada/server/integtests/test_sync.py 2016-06-03 20:58:39 +0000
1086@@ -38,7 +38,7 @@
1087 import u1sync.client
1088
1089 from u1sync.main import do_diff, do_init, do_sync
1090-from ubuntuone.storage.server import server
1091+from ubuntuone.platform import tools
1092 from ubuntuone.storageprotocol import client as protocol_client
1093 from ubuntuone.storageprotocol import request
1094 from ubuntuone.storageprotocol.client import (
1095@@ -47,19 +47,17 @@
1096 )
1097 from ubuntuone.storageprotocol.content_hash import content_hash_factory, crc32
1098 from ubuntuone.storageprotocol import protocol_pb2
1099-from ubuntuone.platform import tools
1100-from ubuntuone.syncdaemon import REQUIRED_CAPS
1101+from ubuntuone.syncdaemon import REQUIRED_CAPS, hash_queue
1102+from ubuntuone.syncdaemon.main import Main
1103
1104-from ubuntuone.storage.server.testing.aq_helpers import show_time # NOQA
1105-from ubuntuone.storage.server.testing.aq_helpers import (
1106+from magicicada.server import server
1107+from magicicada.server.testing.aq_helpers import (
1108 TestWithDatabase,
1109 NukeAQClient,
1110 MethodInterferer,
1111 FakeGetContent,
1112 )
1113-from ubuntuone.storage.server.testing.caps_helpers import required_caps
1114-from ubuntuone.syncdaemon import hash_queue
1115-from ubuntuone.syncdaemon.main import Main
1116+from magicicada.server.testing.caps_helpers import required_caps
1117
1118 U1SYNC_QUIET = True
1119 NO_CONTENT_HASH = ""
1120
1121=== modified file 'magicicada/server/integtests/test_udf_sync.py'
1122--- src/server/integtests/test_udf_sync.py 2016-03-07 22:21:09 +0000
1123+++ magicicada/server/integtests/test_udf_sync.py 2016-06-03 20:58:39 +0000
1124@@ -26,8 +26,8 @@
1125 from twisted.internet import reactor, defer
1126 from twisted.python.failure import Failure
1127
1128-from ubuntuone.storage.server.integtests import test_sync
1129-from ubuntuone.storage.server.testing.aq_helpers import NO_CONTENT_HASH
1130+from magicicada.server.integtests import test_sync
1131+from magicicada.server.testing.aq_helpers import NO_CONTENT_HASH
1132
1133
1134 class TestUDFSync(test_sync.TestSync):
1135
1136=== modified file 'magicicada/server/server.py'
1137--- src/server/server.py 2016-05-31 22:59:18 +0000
1138+++ magicicada/server/server.py 2016-06-03 20:58:39 +0000
1139@@ -52,18 +52,18 @@
1140 from twisted.internet.protocol import Factory
1141 from twisted.internet import defer, reactor, error, task, stdio
1142 from twisted.python.failure import Failure
1143-
1144-from backends.filesync import errors as dataerror
1145-from backends.filesync.notifier import notifier
1146-from magicicada import settings
1147-from ubuntuone.storage.server.logger import configure_logger, TRACE
1148-from ubuntuone.storage.server.diskstorage import DiskStorage
1149-from ubuntuone.monitoring.reactor import ReactorInspector
1150-from ubuntuone.storage.rpcdb import inthread
1151-from ubuntuone.storage.server import auth, content, errors, stats
1152 from ubuntuone.storageprotocol import protocol_pb2, request, sharersp
1153 from ubuntuone.supervisor import utils as supervisor_utils
1154
1155+from magicicada import settings
1156+from magicicada.filesync import errors as dataerror
1157+from magicicada.filesync.notifier import notifier
1158+from magicicada.monitoring.reactor import ReactorInspector
1159+from magicicada.rpcdb import inthread
1160+from magicicada.server import auth, content, errors, stats
1161+from magicicada.server.diskstorage import DiskStorage
1162+from magicicada.server.logger import configure_logger, TRACE
1163+
1164 try:
1165 from versioninfo import version_info
1166 except ImportError:
1167
1168=== modified file 'magicicada/server/server.tac'
1169--- src/server/server.tac 2015-09-26 13:02:01 +0000
1170+++ magicicada/server/server.tac 2016-06-03 20:58:39 +0000
1171@@ -20,13 +20,13 @@
1172
1173 import os
1174
1175-from magicicada import settings
1176 from twisted.application import service
1177 from twisted.internet import reactor
1178
1179 import oops_timeline
1180
1181-from ubuntuone.storage.server import server, auth
1182+from magicicada import settings
1183+from magicicada.server import server, auth
1184
1185 oops_config = server.configure_oops()
1186 # Should probably be an option to configure_oops?
1187
1188=== modified file 'magicicada/server/ssl_proxy.py'
1189--- src/server/ssl_proxy.py 2016-05-31 22:59:18 +0000
1190+++ magicicada/server/ssl_proxy.py 2016-06-03 20:58:39 +0000
1191@@ -34,9 +34,9 @@
1192 import metrics
1193
1194 from magicicada import settings
1195-from ubuntuone.storage.server.logger import configure_logger
1196-from ubuntuone.storage.server.server import get_service_port
1197-from ubuntuone.storage.server.ssl import disable_ssl_compression
1198+from magicicada.server.logger import configure_logger
1199+from magicicada.server.server import get_service_port
1200+from magicicada.server.ssl import disable_ssl_compression
1201 from ubuntuone.supervisor import utils as supervisor_utils
1202
1203 logger = logging.getLogger('ssl_proxy')
1204
1205=== modified file 'magicicada/server/ssl_proxy.tac'
1206--- src/server/ssl_proxy.tac 2015-09-18 23:36:43 +0000
1207+++ magicicada/server/ssl_proxy.tac 2016-06-03 20:58:39 +0000
1208@@ -19,7 +19,8 @@
1209 # For further info, check http://launchpad.net/magicicada-server
1210
1211 from twisted.application import service
1212-from ubuntuone.storage.server import ssl_proxy
1213+
1214+from magicicada.server import ssl_proxy
1215
1216 ssl_server = ssl_proxy.create_service()
1217 application = service.Application('SSLProxy')
1218
1219=== modified file 'magicicada/server/stats.py'
1220--- src/server/stats.py 2016-05-31 22:59:18 +0000
1221+++ magicicada/server/stats.py 2016-06-03 20:58:39 +0000
1222@@ -29,7 +29,8 @@
1223
1224 import metrics
1225
1226-from ubuntuone.monitoring import dump
1227+from magicicada.monitoring import dump
1228+
1229
1230 logger = logging.getLogger("storage.server.stat")
1231 status_log = logging.getLogger("storage.server.status")
1232
1233=== modified file 'magicicada/server/testing/aq_helpers.py'
1234--- src/server/testing/aq_helpers.py 2016-03-10 20:28:04 +0000
1235+++ magicicada/server/testing/aq_helpers.py 2016-06-03 20:58:39 +0000
1236@@ -35,13 +35,7 @@
1237 from twisted.names import dns
1238 from twisted.names.common import ResolverBase
1239 from twisted.python.failure import Failure
1240-
1241-from backends.testing.testcase import BaseTestCase
1242-from magicicada import settings
1243 from ubuntuone import platform
1244-from ubuntuone.storage.server import ssl_proxy
1245-from ubuntuone.storage.server.auth import SimpleAuthProvider
1246-from ubuntuone.storage.server.testing.testcase import BaseProtocolTestCase
1247 from ubuntuone.storageprotocol import request, sharersp, client
1248 from ubuntuone.storageprotocol.content_hash import content_hash_factory, crc32
1249 from ubuntuone.syncdaemon.action_queue import ActionQueue, ActionQueueCommand
1250@@ -51,6 +45,12 @@
1251 from ubuntuone.syncdaemon.sync import Sync
1252 from ubuntuone.syncdaemon.marker import MDMarker
1253
1254+from magicicada import settings
1255+from magicicada.server import ssl_proxy
1256+from magicicada.server.auth import SimpleAuthProvider
1257+from magicicada.server.testing.testcase import BaseProtocolTestCase
1258+from magicicada.testing.testcase import BaseTestCase
1259+
1260 ROOT_DIR = os.getcwd()
1261 SD_CONFIG_DIR = ROOT_DIR + "/.sourcecode/ubuntuone-client/data"
1262 SD_CONFIGS = [os.path.join(SD_CONFIG_DIR, 'syncdaemon.conf'),
1263
1264=== modified file 'magicicada/server/testing/caps_helpers.py'
1265--- src/server/testing/caps_helpers.py 2015-09-18 23:36:43 +0000
1266+++ magicicada/server/testing/caps_helpers.py 2016-06-03 20:58:39 +0000
1267@@ -23,7 +23,8 @@
1268 import functools
1269
1270 from ubuntuone import syncdaemon
1271-from ubuntuone.storage.server import server
1272+
1273+from magicicada.server import server
1274
1275
1276 def required_caps(*args, **kwargs):
1277
1278=== modified file 'magicicada/server/testing/testcase.py'
1279--- src/server/testing/testcase.py 2016-05-31 22:59:18 +0000
1280+++ magicicada/server/testing/testcase.py 2016-06-03 20:58:39 +0000
1281@@ -36,21 +36,20 @@
1282 from twisted.internet.protocol import connectionDone
1283 from twisted.python.failure import Failure
1284 from twisted.trial.unittest import TestCase as TwistedTestCase
1285+from ubuntuone.storageprotocol import client, request, protocol_pb2
1286+from ubuntuone.storageprotocol.client import (
1287+ StorageClientFactory, StorageClient)
1288
1289-from backends.filesync import services
1290-from backends.testing.testcase import BaseTestCase
1291 from magicicada import settings
1292-from ubuntuone.storage.server.auth import DummyAuthProvider
1293-from ubuntuone.storage.server.server import (
1294+from magicicada.filesync import services
1295+from magicicada.server.auth import DummyAuthProvider
1296+from magicicada.server.logger import configure_logger, TRACE
1297+from magicicada.server.server import (
1298 PREFERRED_CAP,
1299 StorageServerService,
1300 configure_oops,
1301 )
1302-from ubuntuone.storage.server.logger import configure_logger, TRACE
1303-from ubuntuone.storageprotocol import client
1304-from ubuntuone.storageprotocol.client import (
1305- StorageClientFactory, StorageClient)
1306-from ubuntuone.storageprotocol import request, protocol_pb2
1307+from magicicada.testing.testcase import BaseTestCase
1308
1309 server_key = settings.api_server.KEY
1310 server_crt = settings.api_server.CRT
1311
1312=== modified file 'magicicada/server/tests/test_account.py'
1313--- src/server/tests/test_account.py 2016-03-09 20:55:02 +0000
1314+++ magicicada/server/tests/test_account.py 2016-06-03 20:58:39 +0000
1315@@ -19,11 +19,11 @@
1316 """Account info tests."""
1317
1318 from twisted.internet import defer
1319-
1320 from ubuntuone.storageprotocol import request
1321-from ubuntuone.storage.server.testing.testcase import TestWithDatabase
1322-from backends.filesync import services
1323-from backends.filesync.models import StorageUser
1324+
1325+from magicicada.filesync import services
1326+from magicicada.filesync.models import StorageUser
1327+from magicicada.server.testing.testcase import TestWithDatabase
1328
1329
1330 class QuotaTest(TestWithDatabase):
1331
1332=== modified file 'magicicada/server/tests/test_auth.py'
1333--- src/server/tests/test_auth.py 2016-02-27 21:32:32 +0000
1334+++ magicicada/server/tests/test_auth.py 2016-06-03 20:58:39 +0000
1335@@ -23,16 +23,15 @@
1336 from twisted.internet import defer
1337
1338 from ubuntuone.devtools.handlers import MementoHandler
1339+from ubuntuone.storageprotocol import errors as protocol_errors, request
1340
1341-from backends.filesync.errors import DoesNotExist
1342-from backends.filesync.models import StorageUser
1343-from ubuntuone.storage.server.auth import (
1344+from magicicada.filesync.errors import DoesNotExist
1345+from magicicada.filesync.models import StorageUser
1346+from magicicada.server.auth import (
1347 DummyAuthProvider,
1348 SimpleAuthProvider,
1349 )
1350-from ubuntuone.storage.server.testing.testcase import TestWithDatabase
1351-from ubuntuone.storageprotocol import errors as protocol_errors
1352-from ubuntuone.storageprotocol import request
1353+from magicicada.server.testing.testcase import TestWithDatabase
1354
1355
1356 class AuthenticationBaseTestCase(TestWithDatabase):
1357
1358=== modified file 'magicicada/server/tests/test_basic.py'
1359--- src/server/tests/test_basic.py 2016-05-31 22:59:18 +0000
1360+++ magicicada/server/tests/test_basic.py 2016-06-03 20:58:39 +0000
1361@@ -37,9 +37,10 @@
1362 import metrics.services
1363 from ubuntuone.devtools.handlers import MementoHandler
1364 from ubuntuone.storageprotocol import request
1365-from ubuntuone.storage.server.testing.testcase import TestWithDatabase
1366 from ubuntuone.supervisor import utils as supervisor_utils
1367-from backends.filesync.models import StorageUser
1368+
1369+from magicicada.filesync.models import StorageUser
1370+from magicicada.server.testing.testcase import TestWithDatabase
1371
1372
1373 class TestBasic(TestWithDatabase):
1374
1375=== modified file 'magicicada/server/tests/test_capabilities.py'
1376--- src/server/tests/test_capabilities.py 2015-09-18 23:36:43 +0000
1377+++ magicicada/server/tests/test_capabilities.py 2016-06-03 20:58:39 +0000
1378@@ -20,8 +20,8 @@
1379
1380 from twisted.internet import defer
1381
1382-from ubuntuone.storage.server.testing.testcase import TestWithDatabase
1383-from ubuntuone.storage.server import server as server_module
1384+from magicicada.server import server as server_module
1385+from magicicada.server.testing.testcase import TestWithDatabase
1386
1387
1388 class QuerySetHelper(TestWithDatabase):
1389
1390=== modified file 'magicicada/server/tests/test_content.py'
1391--- src/server/tests/test_content.py 2016-05-31 22:59:18 +0000
1392+++ magicicada/server/tests/test_content.py 2016-06-03 20:58:39 +0000
1393@@ -30,17 +30,7 @@
1394 from twisted.internet import defer, reactor, threads, task, address
1395 from twisted.trial.unittest import TestCase
1396 from twisted.test.proto_helpers import StringTransport
1397-
1398-from backends.filesync import errors
1399-from backends.filesync.models import StorageObject, StorageUser
1400-from magicicada import settings
1401 from ubuntuone.devtools.handlers import MementoHandler
1402-from ubuntuone.storage.server import server, content, diskstorage
1403-from ubuntuone.storage.server.testing.testcase import (
1404- TestWithDatabase,
1405- BufferedConsumer,
1406- FactoryHelper,
1407-)
1408 from ubuntuone.storageprotocol import (
1409 request,
1410 client as sp_client,
1411@@ -53,6 +43,16 @@
1412 magic_hash_factory,
1413 )
1414
1415+from magicicada import settings
1416+from magicicada.filesync import errors
1417+from magicicada.filesync.models import StorageObject, StorageUser
1418+from magicicada.server import server, content, diskstorage
1419+from magicicada.server.testing.testcase import (
1420+ TestWithDatabase,
1421+ BufferedConsumer,
1422+ FactoryHelper,
1423+)
1424+
1425
1426 NO_CONTENT_HASH = ""
1427 EMPTY_HASH = content_hash_factory().content_hash()
1428
1429=== modified file 'magicicada/server/tests/test_diskstorage.py'
1430--- src/server/tests/test_diskstorage.py 2016-01-04 11:27:52 +0000
1431+++ magicicada/server/tests/test_diskstorage.py 2016-06-03 20:58:39 +0000
1432@@ -26,7 +26,7 @@
1433 from twisted.internet import defer
1434 from twisted.trial.unittest import TestCase as TwistedTestCase
1435
1436-from ubuntuone.storage.server.diskstorage import DiskStorage, DIRS_LEVELS
1437+from magicicada.server.diskstorage import DiskStorage, DIRS_LEVELS
1438
1439
1440 class BaseTestCase(TwistedTestCase):
1441
1442=== modified file 'magicicada/server/tests/test_fileops.py'
1443--- src/server/tests/test_fileops.py 2016-02-27 21:32:32 +0000
1444+++ magicicada/server/tests/test_fileops.py 2016-06-03 20:58:39 +0000
1445@@ -21,13 +21,13 @@
1446 from StringIO import StringIO
1447
1448 from twisted.internet import threads, defer
1449-
1450-from backends.filesync import errors
1451-from backends.filesync.models import STATUS_LIVE, STATUS_DEAD
1452 from ubuntuone.storageprotocol import request
1453 from ubuntuone.storageprotocol import errors as protocol_errors
1454 from ubuntuone.storageprotocol.content_hash import content_hash_factory, crc32
1455-from ubuntuone.storage.server.testing.testcase import TestWithDatabase
1456+
1457+from magicicada.filesync import errors
1458+from magicicada.filesync.models import STATUS_LIVE, STATUS_DEAD
1459+from magicicada.server.testing.testcase import TestWithDatabase
1460
1461
1462 class TestMove(TestWithDatabase):
1463
1464=== modified file 'magicicada/server/tests/test_generations.py'
1465--- src/server/tests/test_generations.py 2016-02-27 21:32:32 +0000
1466+++ magicicada/server/tests/test_generations.py 2016-06-03 20:58:39 +0000
1467@@ -23,11 +23,11 @@
1468 import calendar
1469
1470 from twisted.internet import defer
1471-
1472-from backends.filesync.models import StorageObject
1473 from ubuntuone.storageprotocol import request, delta as protodelta
1474-from ubuntuone.storage.server.testing.testcase import TestWithDatabase
1475-from ubuntuone.storage.server import server
1476+
1477+from magicicada.filesync.models import StorageObject
1478+from magicicada.server import server
1479+from magicicada.server.testing.testcase import TestWithDatabase
1480
1481
1482 class GenerationsTestCase(TestWithDatabase):
1483
1484=== modified file 'magicicada/server/tests/test_make.py'
1485--- src/server/tests/test_make.py 2016-02-27 21:32:32 +0000
1486+++ magicicada/server/tests/test_make.py 2016-06-03 20:58:39 +0000
1487@@ -26,12 +26,12 @@
1488 from StringIO import StringIO
1489
1490 from twisted.internet import defer
1491-
1492-from backends.filesync import errors
1493 from ubuntuone.storageprotocol import request, volumes
1494-from ubuntuone.storage.server.testing.testcase import TestWithDatabase
1495 from ubuntuone.storageprotocol.content_hash import content_hash_factory, crc32
1496
1497+from magicicada.filesync import errors
1498+from magicicada.server.testing.testcase import TestWithDatabase
1499+
1500 NO_CONTENT_HASH = ""
1501
1502
1503
1504=== modified file 'magicicada/server/tests/test_notify_delivery.py'
1505--- src/server/tests/test_notify_delivery.py 2016-05-31 22:59:18 +0000
1506+++ magicicada/server/tests/test_notify_delivery.py 2016-06-03 20:58:39 +0000
1507@@ -21,18 +21,18 @@
1508 import logging
1509 import uuid
1510
1511+import oops_timeline
1512+
1513+from mocker import Mocker, expect
1514 from twisted.internet.defer import inlineCallbacks, succeed
1515 from twisted.internet import defer, reactor
1516 from twisted.python.failure import Failure
1517 from twisted.trial.unittest import TestCase as TwistedTestCase
1518-
1519-from mocker import Mocker, expect
1520-
1521-import oops_timeline
1522-
1523-from backends.filesync.models import Share
1524-from backends.filesync.notifier.testing.testcase import FakeNotifier
1525-from backends.filesync.notifier.notifier import (
1526+from ubuntuone.storageprotocol import protocol_pb2, request
1527+
1528+from magicicada.filesync.models import Share
1529+from magicicada.filesync.notifier import notifier
1530+from magicicada.filesync.notifier.notifier import (
1531 ShareAccepted,
1532 ShareCreated,
1533 ShareDeclined,
1534@@ -41,14 +41,13 @@
1535 UDFDelete,
1536 VolumeNewGeneration,
1537 )
1538-from backends.filesync.notifier import notifier
1539-from ubuntuone.storage.server.server import (
1540+from magicicada.filesync.notifier.testing.testcase import FakeNotifier
1541+from magicicada.server.server import (
1542 StorageServer,
1543 StorageServerFactory,
1544 configure_oops,
1545 )
1546-from ubuntuone.storage.server.testing import testcase
1547-from ubuntuone.storageprotocol import protocol_pb2, request
1548+from magicicada.server.testing import testcase
1549
1550
1551 class DummyReactor(object):
1552
1553=== modified file 'magicicada/server/tests/test_oops.py'
1554--- src/server/tests/test_oops.py 2016-02-24 23:42:56 +0000
1555+++ magicicada/server/tests/test_oops.py 2016-06-03 20:58:39 +0000
1556@@ -23,13 +23,13 @@
1557 import time
1558
1559 from twisted.internet import reactor, defer
1560-
1561 from oops_datedir_repo import serializer
1562-from ubuntuone.storage.server import server
1563-from ubuntuone.storage.server.testing.testcase import (
1564+from ubuntuone.storageprotocol import protocol_pb2
1565+
1566+from magicicada.server import server
1567+from magicicada.server.testing.testcase import (
1568 TestWithDatabase,
1569 FactoryHelper)
1570-from ubuntuone.storageprotocol import protocol_pb2
1571
1572
1573 class TestOops(TestWithDatabase):
1574
1575=== modified file 'magicicada/server/tests/test_server.py'
1576--- src/server/tests/test_server.py 2016-05-31 22:59:18 +0000
1577+++ magicicada/server/tests/test_server.py 2016-06-03 20:58:39 +0000
1578@@ -36,13 +36,14 @@
1579 from twisted.python import log
1580 from twisted.internet import defer, task, error as txerror
1581 from twisted.trial.unittest import TestCase as TwistedTestCase
1582+from ubuntuone.devtools.handlers import MementoHandler
1583+from ubuntuone.storageprotocol import protocol_pb2, request
1584
1585-from backends.filesync import errors as dataerror
1586-from backends.filesync.models import Share
1587 from magicicada import settings
1588-from ubuntuone.devtools.handlers import MementoHandler
1589-from ubuntuone.storage.server import errors, server
1590-from ubuntuone.storage.server.server import (
1591+from magicicada.filesync import errors as dataerror
1592+from magicicada.filesync.models import Share
1593+from magicicada.server import errors, server
1594+from magicicada.server.server import (
1595 StorageServer, StorageServerRequestResponse, SimpleRequestResponse,
1596 ListShares, ShareAccepted, CreateShare, DeleteShare, TRACE,
1597 CreateUDF, DeleteVolume, ListVolumes, Unlink, BytesMessageProducer,
1598@@ -51,8 +52,7 @@
1599 QuerySetCapsResponse, MoveResponse, MakeResponse, FreeSpaceResponse,
1600 AccountResponse, AuthenticateResponse, Action, LoopingPing,
1601 )
1602-from ubuntuone.storage.server.testing import testcase
1603-from ubuntuone.storageprotocol import protocol_pb2, request
1604+from magicicada.server.testing import testcase
1605
1606 try:
1607 from versioninfo import version_info
1608
1609=== modified file 'magicicada/server/tests/test_sharing.py'
1610--- src/server/tests/test_sharing.py 2016-02-27 17:08:46 +0000
1611+++ magicicada/server/tests/test_sharing.py 2016-06-03 20:58:39 +0000
1612@@ -24,14 +24,13 @@
1613 from StringIO import StringIO
1614
1615 from twisted.internet import reactor, defer
1616+from ubuntuone.storageprotocol import errors as protocol_errors, request
1617+from ubuntuone.storageprotocol.content_hash import content_hash_factory, crc32
1618
1619-from backends.filesync import errors
1620-from backends.filesync.models import STATUS_LIVE, Share
1621-from ubuntuone.storage.server.testing.testcase import (
1622+from magicicada.filesync import errors
1623+from magicicada.filesync.models import STATUS_LIVE, Share
1624+from magicicada.server.testing.testcase import (
1625 TestWithDatabase, FactoryHelper)
1626-from ubuntuone.storageprotocol import request
1627-from ubuntuone.storageprotocol import errors as protocol_errors
1628-from ubuntuone.storageprotocol.content_hash import content_hash_factory, crc32
1629
1630 EMPTY_HASH = content_hash_factory().content_hash()
1631 NO_CONTENT_HASH = ""
1632
1633=== modified file 'magicicada/server/tests/test_shutdown.py'
1634--- src/server/tests/test_shutdown.py 2016-05-31 22:59:18 +0000
1635+++ magicicada/server/tests/test_shutdown.py 2016-06-03 20:58:39 +0000
1636@@ -22,16 +22,16 @@
1637
1638 from twisted.trial.unittest import TestCase as TwistedTestCase
1639 from twisted.internet import reactor, defer, error
1640-
1641-from backends.filesync.services import make_storage_user
1642-from backends.testing.testcase import BaseTestCase
1643-from ubuntuone.storage.server.auth import DummyAuthProvider
1644-from ubuntuone.storage.server.testing.testcase import StorageServerService
1645 from ubuntuone.storageprotocol import request
1646 from ubuntuone.storageprotocol.content_hash import content_hash_factory
1647 from ubuntuone.storageprotocol.client import (
1648 StorageClientFactory, StorageClient)
1649
1650+from magicicada.filesync.services import make_storage_user
1651+from magicicada.server.auth import DummyAuthProvider
1652+from magicicada.server.testing.testcase import StorageServerService
1653+from magicicada.testing.testcase import BaseTestCase
1654+
1655
1656 class TestClient(StorageClient):
1657 """A simple client for tests."""
1658
1659=== modified file 'magicicada/server/tests/test_ssl_proxy.py'
1660--- src/server/tests/test_ssl_proxy.py 2016-05-31 22:59:18 +0000
1661+++ magicicada/server/tests/test_ssl_proxy.py 2016-06-03 20:58:39 +0000
1662@@ -35,13 +35,14 @@
1663
1664 from magicicada import settings
1665 from ubuntuone.devtools.handlers import MementoHandler
1666-from ubuntuone.storage.server.testing.testcase import TestWithDatabase
1667-from ubuntuone.storage.server import ssl_proxy
1668-from ubuntuone.storage.server.server import PREFERRED_CAP
1669 from ubuntuone.storageprotocol.client import (
1670 StorageClientFactory, StorageClient)
1671 from ubuntuone.supervisor import utils as supervisor_utils
1672
1673+from magicicada.server import ssl_proxy
1674+from magicicada.server.server import PREFERRED_CAP
1675+from magicicada.server.testing.testcase import TestWithDatabase
1676+
1677
1678 class SSLProxyServiceTest(TestWithDatabase):
1679 """Tests for the service instance."""
1680
1681=== modified file 'magicicada/server/tests/test_stats.py'
1682--- src/server/tests/test_stats.py 2016-05-31 22:59:18 +0000
1683+++ magicicada/server/tests/test_stats.py 2016-06-03 20:58:39 +0000
1684@@ -22,8 +22,8 @@
1685
1686 import metrics
1687
1688-from ubuntuone.storage.server.stats import StatsWorker
1689-from ubuntuone.storage.server.testing.testcase import TestWithDatabase
1690+from magicicada.server.stats import StatsWorker
1691+from magicicada.server.testing.testcase import TestWithDatabase
1692
1693
1694 class FakeMetrics(object):
1695
1696=== modified file 'magicicada/server/tests/test_throttling.py'
1697--- src/server/tests/test_throttling.py 2016-03-09 20:55:02 +0000
1698+++ magicicada/server/tests/test_throttling.py 2016-06-03 20:58:39 +0000
1699@@ -26,12 +26,12 @@
1700 from django.db import transaction
1701 from twisted.internet import threads, defer
1702 from twisted.internet.protocol import connectionDone
1703-
1704-from backends.filesync import services
1705-from backends.filesync.models import ContentBlob
1706 from ubuntuone.storageprotocol import request, client
1707 from ubuntuone.storageprotocol.content_hash import content_hash_factory, crc32
1708-from ubuntuone.storage.server.testing.testcase import (
1709+
1710+from magicicada.filesync import services
1711+from magicicada.filesync.models import ContentBlob
1712+from magicicada.server.testing.testcase import (
1713 TestWithDatabase,
1714 ClientTestHelper,
1715 )
1716
1717=== modified file 'magicicada/server/tests/test_udfs.py'
1718--- src/server/tests/test_udfs.py 2015-09-27 16:59:15 +0000
1719+++ magicicada/server/tests/test_udfs.py 2016-06-03 20:58:39 +0000
1720@@ -26,12 +26,13 @@
1721 from StringIO import StringIO
1722
1723 from twisted.internet import reactor, defer
1724-
1725-from backends.filesync.errors import DoesNotExist
1726 from ubuntuone.storageprotocol import request
1727-from ubuntuone.storage.server.testing.testcase import (
1728+from ubuntuone.storageprotocol.content_hash import content_hash_factory, crc32
1729+
1730+from magicicada.filesync.errors import DoesNotExist
1731+from magicicada.server.testing.testcase import (
1732 TestWithDatabase, FactoryHelper)
1733-from ubuntuone.storageprotocol.content_hash import content_hash_factory, crc32
1734+
1735
1736 EMPTY_HASH = content_hash_factory().content_hash()
1737 NO_CONTENT_HASH = ""
1738
1739=== modified file 'magicicada/server/tests/test_upload.py'
1740--- src/server/tests/test_upload.py 2016-01-04 11:27:52 +0000
1741+++ magicicada/server/tests/test_upload.py 2016-06-03 20:58:39 +0000
1742@@ -16,23 +16,23 @@
1743 #
1744 # For further info, check http://launchpad.net/magicicada-server
1745
1746-"""Tests for ubuntuone.storage.server.upload."""
1747+"""Tests for server upload."""
1748
1749 import os
1750 import shutil
1751 import zlib
1752
1753 from twisted.internet import defer, reactor, task
1754-
1755-from ubuntuone.storage.server import upload, diskstorage
1756-from ubuntuone.storage.server.auth import DummyAuthProvider
1757-from ubuntuone.storage.server.testing import testcase
1758 from ubuntuone.storageprotocol.content_hash import (
1759 content_hash_factory,
1760 crc32,
1761 magic_hash_factory,
1762 )
1763
1764+from magicicada.server import upload, diskstorage
1765+from magicicada.server.auth import DummyAuthProvider
1766+from magicicada.server.testing import testcase
1767+
1768
1769 class UploadTestCase(testcase.BaseProtocolTestCase):
1770 """Base test case for upload stuff."""
1771
1772=== modified file 'magicicada/server/tests/test_validation.py'
1773--- src/server/tests/test_validation.py 2016-02-20 17:03:19 +0000
1774+++ magicicada/server/tests/test_validation.py 2016-06-03 20:58:39 +0000
1775@@ -23,7 +23,8 @@
1776 import re
1777
1778 from ubuntuone.storageprotocol import request
1779-from ubuntuone.storage.server.testing.testcase import TestWithDatabase
1780+
1781+from magicicada.server.testing.testcase import TestWithDatabase
1782
1783
1784 def is_protocol_error(failure):
1785
1786=== modified file 'magicicada/server/tests/test_volumes.py'
1787--- src/server/tests/test_volumes.py 2016-02-27 21:32:32 +0000
1788+++ magicicada/server/tests/test_volumes.py 2016-06-03 20:58:39 +0000
1789@@ -21,14 +21,14 @@
1790 """Test volume operations."""
1791
1792 from twisted.internet import defer
1793-
1794-from backends.filesync.models import Share
1795-from backends.filesync.services import get_storage_user
1796-from ubuntuone.storage.server.testing.testcase import TestWithDatabase
1797 from ubuntuone.storageprotocol import request
1798 from ubuntuone.storageprotocol.volumes import (
1799 RootVolume, UDFVolume, ShareVolume)
1800
1801+from magicicada.filesync.models import Share
1802+from magicicada.filesync.services import get_storage_user
1803+from magicicada.server.testing.testcase import TestWithDatabase
1804+
1805
1806 class TestListVolumes(TestWithDatabase):
1807 """Test list_volumes command."""
1808
1809=== modified file 'magicicada/server/upload.py'
1810--- src/server/upload.py 2016-01-04 11:27:52 +0000
1811+++ magicicada/server/upload.py 2016-06-03 20:58:39 +0000
1812@@ -30,14 +30,14 @@
1813 from cStringIO import StringIO
1814
1815 from twisted.internet import defer
1816-
1817-from ubuntuone.storage.server.diskstorage import FileReaderProducer
1818 from ubuntuone.storageprotocol.content_hash import (
1819 content_hash_factory,
1820 crc32,
1821 magic_hash_factory,
1822 )
1823-from ubuntuone.storage.server import errors
1824+
1825+from magicicada.server import errors
1826+from magicicada.server.diskstorage import FileReaderProducer
1827
1828
1829 class ProxyHashingProducer(object):
1830
1831=== renamed directory 'src/magicicada/settings' => 'magicicada/settings'
1832=== modified file 'magicicada/settings/__init__.py'
1833--- src/magicicada/settings/__init__.py 2016-05-31 22:59:18 +0000
1834+++ magicicada/settings/__init__.py 2016-06-03 20:58:39 +0000
1835@@ -35,8 +35,7 @@
1836 from psycopg2.extensions import ISOLATION_LEVEL_REPEATABLE_READ
1837
1838 BASE_DIR = os.path.dirname(
1839- os.path.dirname(os.path.dirname(os.path.dirname(
1840- os.path.abspath(__file__)))))
1841+ os.path.dirname(os.path.dirname(os.path.abspath(__file__))))
1842
1843
1844 # Quick-start development settings - unsuitable for production
1845@@ -61,8 +60,8 @@
1846 'django.contrib.messages',
1847 'django.contrib.staticfiles',
1848 'django.contrib.sites',
1849- 'backends.filesync',
1850- 'backends.txlog',
1851+ 'magicicada.filesync',
1852+ 'magicicada.txlog',
1853 )
1854
1855 MIDDLEWARE_CLASSES = (
1856
1857=== renamed directory 'src/backends/testing' => 'magicicada/testing'
1858=== modified file 'magicicada/testing/factory.py'
1859--- src/backends/testing/factory.py 2016-03-10 20:28:04 +0000
1860+++ magicicada/testing/factory.py 2016-06-03 20:58:39 +0000
1861@@ -29,7 +29,7 @@
1862 from django.contrib.auth import get_user_model
1863 from django.utils.timezone import now
1864
1865-from backends.filesync.models import (
1866+from magicicada.filesync.models import (
1867 STATUS_DEAD,
1868 STATUS_LIVE,
1869 ContentBlob,
1870@@ -41,7 +41,7 @@
1871 UploadJob,
1872 UserVolume,
1873 )
1874-from backends.txlog.models import TransactionLog
1875+from magicicada.txlog.models import TransactionLog
1876
1877
1878 BASE_CHARS = string.letters + string.digits
1879
1880=== modified file 'magicicada/testing/testcase.py'
1881--- src/backends/testing/testcase.py 2016-03-10 20:28:04 +0000
1882+++ magicicada/testing/testcase.py 2016-06-03 20:58:39 +0000
1883@@ -16,14 +16,14 @@
1884 #
1885 # For further info, check http://launchpad.net/magicicada-server
1886
1887-"""TestCases for testing with backends."""
1888+"""TestCases for testing."""
1889
1890 from __future__ import unicode_literals
1891
1892 from django.test import TransactionTestCase
1893 from django.test.client import RequestFactory
1894
1895-from backends.testing.factory import Factory
1896+from magicicada.testing.factory import Factory
1897
1898
1899 class BaseTestCase(TransactionTestCase):
1900
1901=== renamed directory 'src/backends/txlog' => 'magicicada/txlog'
1902=== modified file 'magicicada/txlog/models.py'
1903--- src/backends/txlog/models.py 2016-02-27 21:32:32 +0000
1904+++ magicicada/txlog/models.py 2016-06-03 20:58:39 +0000
1905@@ -29,7 +29,7 @@
1906 from django.dispatch import receiver
1907 from django.utils.timezone import now
1908
1909-from backends.filesync.models import (
1910+from magicicada.filesync.models import (
1911 STATUS_DEAD,
1912 STATUS_LIVE,
1913 Share,
1914@@ -37,7 +37,7 @@
1915 StorageUser,
1916 UserVolume,
1917 )
1918-from backends.filesync.signals import (
1919+from magicicada.filesync.signals import (
1920 content_changed,
1921 node_moved,
1922 post_unlink_tree,
1923
1924=== modified file 'magicicada/txlog/tests/test_models.py'
1925--- src/backends/txlog/tests/test_models.py 2016-03-09 03:22:33 +0000
1926+++ magicicada/txlog/tests/test_models.py 2016-06-03 20:58:39 +0000
1927@@ -20,13 +20,13 @@
1928
1929 from __future__ import unicode_literals
1930
1931-from backends.filesync.services import SystemGateway
1932-from backends.filesync.models import (
1933+from magicicada.filesync.models import (
1934 STATUS_LIVE,
1935 STATUS_DEAD,
1936 )
1937-from backends.testing.testcase import BaseTestCase
1938-from backends.txlog.models import get_epoch_secs, TransactionLog
1939+from magicicada.filesync.services import SystemGateway
1940+from magicicada.testing.testcase import BaseTestCase
1941+from magicicada.txlog.models import get_epoch_secs, TransactionLog
1942
1943
1944 class BaseTransactionLogTestCase(BaseTestCase):
1945
1946=== modified file 'magicicada/txlog/tests/test_utils.py'
1947--- src/backends/txlog/tests/test_utils.py 2016-03-07 19:01:17 +0000
1948+++ magicicada/txlog/tests/test_utils.py 2016-06-03 20:58:39 +0000
1949@@ -24,9 +24,9 @@
1950
1951 from django.utils.timezone import now
1952
1953-from backends.txlog import utils
1954-from backends.txlog.models import DBWorkerLastRow, TransactionLog
1955-from backends.txlog.tests.test_models import BaseTransactionLogTestCase
1956+from magicicada.txlog import utils
1957+from magicicada.txlog.models import DBWorkerLastRow, TransactionLog
1958+from magicicada.txlog.tests.test_models import BaseTransactionLogTestCase
1959
1960
1961 class TransactionLogUtilsTestCase(BaseTransactionLogTestCase):
1962
1963=== modified file 'magicicada/txlog/utils.py'
1964--- src/backends/txlog/utils.py 2016-02-27 21:32:32 +0000
1965+++ magicicada/txlog/utils.py 2016-06-03 20:58:39 +0000
1966@@ -24,7 +24,7 @@
1967 from django.db.models import Q
1968 from django.utils.timezone import now, timedelta
1969
1970-from backends.txlog.models import (
1971+from magicicada.txlog.models import (
1972 DBWorkerLastRow,
1973 DBWorkerUnseen,
1974 TransactionLog,
1975
1976=== modified file 'magicicada/txutils/__init__.py'
1977--- src/txutils/__init__.py 2015-09-17 19:18:13 +0000
1978+++ magicicada/txutils/__init__.py 2016-06-03 20:58:39 +0000
1979@@ -18,4 +18,4 @@
1980
1981 """Twisted utilities."""
1982
1983-from ubuntuone.txutils.retry import NetworkRetry # NOQA
1984+from magicicada.txutils.retry import NetworkRetry # NOQA
1985
1986=== modified file 'magicicada/txutils/tests/test_retry.py'
1987--- src/txutils/tests/test_retry.py 2015-09-20 22:58:47 +0000
1988+++ magicicada/txutils/tests/test_retry.py 2016-06-03 20:58:39 +0000
1989@@ -20,10 +20,11 @@
1990
1991 from __future__ import unicode_literals
1992
1993-from ubuntuone import txutils
1994 from twisted.internet import defer
1995 from twisted.trial.unittest import TestCase as TwistedTestCase
1996
1997+from magicicada import txutils
1998+
1999
2000 class TestNetworkRetry(TwistedTestCase):
2001 """Tests for the NetworkRetry."""
2002
2003=== renamed file 'src/magicicada/urls.py' => 'magicicada/urls.py'
2004=== renamed file 'src/backends/utils.py' => 'magicicada/utils.py'
2005--- src/backends/utils.py 2016-03-09 20:55:02 +0000
2006+++ magicicada/utils.py 2016-06-03 20:58:39 +0000
2007@@ -20,7 +20,7 @@
2008
2009 from __future__ import unicode_literals
2010
2011-from backends.filesync import services
2012+from magicicada.filesync import services
2013
2014
2015 def create_test_user(
2016
2017=== renamed file 'src/magicicada/wsgi.py' => 'magicicada/wsgi.py'
2018=== removed directory 'src/backends'
2019=== removed file 'src/backends/__init__.py'
2020--- src/backends/__init__.py 2015-09-17 19:15:50 +0000
2021+++ src/backends/__init__.py 1970-01-01 00:00:00 +0000
2022@@ -1,17 +0,0 @@
2023-# Copyright 2008-2015 Canonical
2024-# Copyright 2015 Chicharreros (https://launchpad.net/~chicharreros)
2025-#
2026-# This program is free software: you can redistribute it and/or modify
2027-# it under the terms of the GNU Affero General Public License as
2028-# published by the Free Software Foundation, either version 3 of the
2029-# License, or (at your option) any later version.
2030-#
2031-# This program is distributed in the hope that it will be useful,
2032-# but WITHOUT ANY WARRANTY; without even the implied warranty of
2033-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
2034-# GNU Affero General Public License for more details.
2035-#
2036-# You should have received a copy of the GNU Affero General Public License
2037-# along with this program. If not, see <http://www.gnu.org/licenses/>.
2038-#
2039-# For further info, check http://launchpad.net/magicicada-server
2040
2041=== removed directory 'src/magicicada'
2042=== modified file 'test'
2043--- test 2016-05-21 19:58:46 +0000
2044+++ test 2016-06-03 20:58:39 +0000
2045@@ -26,7 +26,7 @@
2046 sys.path.insert(0, os.path.abspath('lib'))
2047
2048 TESTDIRS = [
2049- 'src',
2050+ 'magicicada',
2051 ]
2052 for td in TESTDIRS:
2053 sys.path.insert(0, os.path.abspath(td))

Subscribers

People subscribed via source and target branches

to all changes: