#129 Remove Fedmsg as a dependency
Merged 5 years ago by jflory7. Opened 5 years ago by shraddhaag.
fedora-commops/ shraddhaag/fedora-happiness-packets remove-fedmsg-dependency  into  master

@@ -16,8 +16,6 @@ 

  from .forms import MessageSendForm, MessageRecipientForm

  from .models import Message, BLACKLIST_HMAC_SALT, BlacklistedEmail, strip_email

  

- import fedmsg

- 

  logger = logging.getLogger(__name__)

  

  
@@ -147,6 +145,5 @@ 

          if msg.sender_approved_public and msg.recipient_approved_public:

              sender_name = msg.sender_name if msg.sender_approved_public_named else "Anonymous"

              recipient_name = msg.recipient_name if msg.recipient_approved_public_named else "Anonymous"

-             fedmsg.publish(topic='happinesspacket.send', msg={'id': msg.identifier, 'sender_name': sender_name, 'recipient_name': recipient_name, 'text': msg.message,})

          messages.success(self.request, "Your choices have been saved.")

          return HttpResponseRedirect(self.request.path)

file modified
-1
@@ -33,6 +33,5 @@ 

  factory-boy==2.9.2

  opbeat==3.3

  mozilla-django-oidc==1.0.0

- fedmsg==1.1.1

  celery[redis]==4.2.1

  django-celery-email==2.0.1

Q - What is a summary of your change?
A - This commit removes Fedmsg as a dependency for the project.

Q - Why is this change helpful?
A - Since Fedmsg is deprecated in favour of fedora-messaging, this commit removes the Fedmsg dependency for the project.
This solves ticket #66 and #69 and is the first step of many for #96. Since fedmsg is used only for assigning badges, it doesn't conflict with either of these issues and restores them back to full functionality. It's important to get this functionality in the codebase so others working on the project can work on things forward from here.

Note - The test suite was successfully passed.

@jflory7 Please find the time to review the PR. Thanks! :)

Metadata Update from @jflory7:
- Pull-request tagged with: improvement, type - backend, type - fedora-messaging, type - summer coding
- Request assigned

5 years ago

Hi @shraddhaag, excellent sleuthing on #66 and #69. :mag:

This change is easy and simple so I'm happy to merge it. Before merging, I want to test before/after on #66 and #69 to confirm your fix. I might not have a chance to do this until Tuesday or Wednesday, but I'll get it done soon.

Thanks for the PR! :thumbsup:

Metadata Update from @jflory7:
- Pull-request tagged with: needs testing

5 years ago

rebased onto bb7c9f2

5 years ago

Metadata Update from @jflory7:
- Pull-request untagged with: needs testing

5 years ago

@shraddhaag I tested and confirmed your fix for #66. :tada: I will follow up with a reply in #69 in a little bit.

Thanks for this PR! Merging. :clapper:

Pull-Request has been merged by jflory7

5 years ago