openedx / openedx-events

Open edX events from the Hooks Extensions Framework
Apache License 2.0
11 stars 21 forks source link

feat: Add enterprise signal for learner credit fulfillment revokation #380

Closed pwnage101 closed 2 months ago

pwnage101 commented 3 months ago

ENT-9213

pwnage101 commented 3 months ago

@mariajgrimaldi please take a look when you have a chance!

iloveagent57 commented 2 months ago

@pwnage101 it'll probably be useful for Maria or others in the community to paste in some context from ENT-9213 (which they won't be able to access). Also maybe add links to the edx-enterprise models that this new signal-data correspond to.

pwnage101 commented 2 months ago

Fair, so first here's the ticket body for ENT-9213:

Background

There is an enterprise-subsidy cron job that writes reversals from recently unenrolled records to get transactions into a reversed state (at which point we'll send an event that causes the corresponding assignment to be reversed). We should eliminate that cron/mgmt command and replace it with an event producer/consumer.

AC

  • Add a new event for enterprise unenrollment events LearnerCreditEnterpriseCourseEnrollment
  • enterprise-subsidy consumes these events in real time and writes reversal for that one learner.
    • Ensure that enterprise-subsidy has appropriate roles, ACLs, API keys etc. to be a consumer of openedx events.
pwnage101 commented 2 months ago

Here's a list of all other openedx PRs which are all part of this same ticket:

mariajgrimaldi commented 2 months ago

Hi folks! Thank you for your contribution. I'll be reviewing this as soon as I can. Thanks for the patience!

pwnage101 commented 2 months ago

FYI, I also updated the docstrings with direct links to django models in openedx code.

pwnage101 commented 2 months ago

@mariajgrimaldi please merge at your earliest convenience, as I do not have write access to this repository.