mirror of
https://github.com/samuelclay/NewsBlur.git
synced 2025-09-18 21:50:56 +00:00
Finding all old celery invocations.
This commit is contained in:
parent
afcb25135d
commit
4a608d2ce5
7 changed files with 9 additions and 9 deletions
|
@ -45,7 +45,7 @@ class MPopularityQuery(mongo.Document):
|
|||
return "%s - \"%s\"" % (self.email, self.query)
|
||||
|
||||
def queue_email(self):
|
||||
EmailPopularityQuery().delay(pk=self.pk)
|
||||
EmailPopularityQuery.delay(pk=self.pk)
|
||||
|
||||
@classmethod
|
||||
def ensure_all_sent(cls, queue=True):
|
||||
|
|
|
@ -46,7 +46,7 @@ def opml_upload(request):
|
|||
folders = opml_importer.try_processing()
|
||||
except TimeoutError:
|
||||
folders = None
|
||||
ProcessOPML().delay(request.user.pk)
|
||||
ProcessOPML.delay(request.user.pk)
|
||||
feed_count = opml_importer.count_feeds_in_opml()
|
||||
logging.user(request, "~FR~SBOPML upload took too long, found %s feeds. Tasking..." % feed_count)
|
||||
payload = dict(folders=folders, delayed=True, feed_count=feed_count)
|
||||
|
|
|
@ -67,7 +67,7 @@ def twitter_connect(request):
|
|||
social_services.syncing_twitter = True
|
||||
social_services.save()
|
||||
|
||||
SyncTwitterFriends().delay(user_id=request.user.pk)
|
||||
SyncTwitterFriends.delay(user_id=request.user.pk)
|
||||
|
||||
logging.user(request, "~BB~FRFinishing Twitter connect")
|
||||
return {}
|
||||
|
@ -131,7 +131,7 @@ def facebook_connect(request):
|
|||
social_services.syncing_facebook = True
|
||||
social_services.save()
|
||||
|
||||
SyncFacebookFriends().delay(user_id=request.user.pk)
|
||||
SyncFacebookFriends.delay(user_id=request.user.pk)
|
||||
|
||||
logging.user(request, "~BB~FRFinishing Facebook connect")
|
||||
return {}
|
||||
|
|
|
@ -167,7 +167,7 @@ class SignupForm(forms.Form):
|
|||
RNewUserQueue.add_user(new_user.pk)
|
||||
|
||||
if new_user.email:
|
||||
EmailNewUser().delay(user_id=new_user.pk)
|
||||
EmailNewUser.delay(user_id=new_user.pk)
|
||||
|
||||
if getattr(settings, 'AUTO_PREMIUM_NEW_USERS', False):
|
||||
new_user.profile.activate_premium()
|
||||
|
|
|
@ -619,7 +619,7 @@ def mark_story_as_shared(request):
|
|||
})
|
||||
if source_user_id:
|
||||
shared_story.set_source_user_id(int(source_user_id))
|
||||
UpdateRecalcForSubscription().delay(subscription_user_id=request.user.pk,
|
||||
UpdateRecalcForSubscription.delay(subscription_user_id=request.user.pk,
|
||||
shared_story_id=str(shared_story.id))
|
||||
logging.user(request, "~FCSharing ~FM%s: ~SB~FB%s" % (story.story_title[:20], comments[:30]))
|
||||
else:
|
||||
|
@ -657,7 +657,7 @@ def mark_story_as_shared(request):
|
|||
if post_to_services:
|
||||
for service in post_to_services:
|
||||
if service not in shared_story.posted_to_services:
|
||||
PostToService().delay(shared_story_id=str(shared_story.id), service=service)
|
||||
PostToService.delay(shared_story_id=str(shared_story.id), service=service)
|
||||
|
||||
if shared_story.source_user_id and shared_story.comments:
|
||||
EmailStoryReshares.apply_async(kwargs=dict(shared_story_id=str(shared_story.id)),
|
||||
|
|
|
@ -595,7 +595,7 @@ class ProcessFeed:
|
|||
|
||||
# Push notifications
|
||||
if ret_values['new'] > 0 and MUserFeedNotification.feed_has_users(self.feed.pk) > 0:
|
||||
QueueNotifications().delay(self.feed.pk, ret_values['new'])
|
||||
QueueNotifications.delay(self.feed.pk, ret_values['new'])
|
||||
|
||||
# All Done
|
||||
logging.debug(' ---> [%-30s] ~FYParsed Feed: %snew=%s~SN~FY %sup=%s~SN same=%s%s~SN %serr=%s~SN~FY total=~SB%s' % (
|
||||
|
|
2
vendor/seacucumber/backend.py
vendored
2
vendor/seacucumber/backend.py
vendored
|
@ -26,7 +26,7 @@ class SESBackend(BaseEmailBackend):
|
|||
num_sent = 0
|
||||
for message in email_messages:
|
||||
# Hand this off to a celery task.
|
||||
SendEmailTask().delay(
|
||||
SendEmailTask.delay(
|
||||
message.from_email,
|
||||
message.recipients(),
|
||||
message.message().as_string(),
|
||||
|
|
Loading…
Add table
Reference in a new issue