-
Notifications
You must be signed in to change notification settings - Fork 9
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. Weβll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Feature] Send 'new pool' emails overnight #11804
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
$startOfSpan = Carbon::now()->subHours(24); // assuming the last reporting job ran about 24 hours ago | ||
$this->info("Finding pools published between $startOfSpan and $endOfSpan."); | ||
|
||
$poolsPublishedRecently = Pool::query() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
one more question .. this pr checks the pools published within 24 hours but doesn't check for open pools.
In the use case , they have published something accidentally and they closed it immediately, we would still send notification for that closed pool.
I'm wondering should we add that check for only active pools?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good catch. If I had remembered to update the tests first, this would have been caught. π€¦
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is working great! Awesome π₯
π€ Resolves #11709
π Introduction
Sends "new pool published" emails overnight instead of immediately.
π΅οΈ Details
One of the AC is:
This is no longer relevant since the script is running from the cron job and not a task scheduler worker. It no longer has a time limit - I think. π
π§ͺ Testing
./artisan send-notifications:pool-published
Also: