Closed linovia closed 12 years ago
I believe this should be fixed now. It has to run the initial sync again but it should be faster this time since it doesn't require downloading the files again (It should detect the old files and skip downloading). As a side effect of the refactor in #17 redis is now required for syncing.
Context: Ubuntu 11.10, postgresql.
Here's an example of the stacktrace I can see when running the sync:
Traceback (most recent call last): File "/home/django/crate/local/lib/python2.7/site-packages/celery/execute/trace.py", line 47, in trace return cls(states.SUCCESS, retval=fun(_args, _kwargs)) File "/home/django/crate/local/lib/python2.7/site-packages/celery/app/task/init.py", line 247, in call return self.run(_args, _kwargs) File "/home/django/crate/local/lib/python2.7/site-packages/celery/app/init.py", line 175, in run return fun(_args, _kwargs) File "/home/django/crate/crate-site/crate_project/apps/pypi/tasks.py", line 336, in process_release_data release.save() File "/home/django/crate/crate-site/crate_project/apps/packages/models.py", line 177, in save return super(Release, self).save(_args, _kwargs) File "/home/django/crate/src/django/django/db/models/base.py", line 464, in save self.save_base(using=using, force_insert=force_insert, force_update=force_update) File "/home/django/crate/src/django/django/db/models/base.py", line 566, in save_base created=(not record_exists), raw=raw, using=using) File "/home/django/crate/src/django/django/dispatch/dispatcher.py", line 172, in send response = receiver(signal=self, sender=sender, **named) File "/home/django/crate/crate-site/crate_project/apps/packages/models.py", line 367, in version_ordering Release.objects.filter(pk=release.pk).update(order=i) File "/home/django/crate/src/django/django/db/models/query.py", line 533, in update rows = query.get_compiler(self.db).execute_sql(None) File "/home/django/crate/src/django/django/db/models/sql/compiler.py", line 986, in execute_sql cursor = super(SQLUpdateCompiler, self).execute_sql(result_type) File "/home/django/crate/src/django/django/db/models/sql/compiler.py", line 818, in execute_sql cursor.execute(sql, params) File "/home/django/crate/src/django/django/db/backends/util.py", line 40, in execute return self.cursor.execute(sql, params) File "/home/django/crate/src/django/django/db/backends/postgresql_psycopg2/base.py", line 52, in execute return self.cursor.execute(query, args) DatabaseError: deadlock detected DETAIL: Process 30521 waits for ShareLock on transaction 1220140; blocked by process 30523. Process 30523 waits for ShareLock on transaction 1220141; blocked by process 30521. HINT: See server log for query details.