Until the owner of a demo organization sets an email, the submit
button on the invite user modal is now disabled.
The input div for email addresses is also disabled, which wasn't
disabled before because it's not an input element on the form.
In the invite users modal, if the demo organization owner hasn't
yet added an email to their account, hide the banners with tips
for setting up organization information before inviting users.
This just records the time when the user created the
request to schedule a message or set a reminder.
This would be unused but is future-proofing against a world
where we decide to edit the strings or UI to show when you
asked for the thing.
The huddle database table was renamed to direct_message_group.
This commit updates all references to huddle in the missed_message
email templates and locale files.
Fetching a subscription and then checking if it exists was taking too
much space in a test and making it feel convoluted. We're planning to
check it more in future commits.
Use a shared error template for demo organizations when rendering
the upgrade or sponsorship pages.
Demo organizations must be converted into a permanent organization,
i.e., not be automatically scheduled for deletion, to either apply
for a sponsorship/discount or upgrade to a paid plan.
Earlier, in `get_raw_unread_data` the ordering was applied inside
the CTE.
Once we leave the CTE scope and do a join, SQL makes no promise
about preserving the row order unless we re-specify ORDER BY in
the outer query.
Since, there was no ORDER BY clause in the outer query it was
resulting in a random ordering of the entries. This bug was caught
by `test_unreads_case_insensitive_topics` failing in a flaky way.
This commit fixes the bug.
Sending emails synchronously is useful because it reports
configuration errors -- but it also means that occasional failures can
result in ugly 500's, since those don't retry.
Add a setting which forces all email to go through the `emil_senders`
queue, so it can be retried as needed.
This commit removes the `.thinner` class from the
"Play animated images" setting in Preferences > Information,
and from the "Home view" setting in Preferences > Navigation.
The `.setting-next-is-related` class, used in combination with
the `.thinner` class, is also removed as it is not needed.
We no longer use the `.thinner` class.
Adds "Present if realm is present in fetch_event_types" to the
fields in the POST /register response that are added to the state
data via fetch_initial_state_data in the if block for "realm".
Previously, when in anonymous login, pressing the "view original
message" button showed the original message and allowed copying it.
However, the corresponding keyboard shortcut ('e') did not work as
expected and a login pop-up appeared instead.
Now, by fixing the UI features' permissions for anonymous users, by
adding "edit_message" as a feature they can perform, they are allowed
to use the 'e' keyboard shortcut as intended.
Fixes#33838
This commit moves `HandlePushNotificationTest` to a new
`test_handle_push_notification.py` file.
It helps in making it easier to work with `test_push_notifications.py`
which was 4000+ lines of code.
This is a prep commit which moves the `PushNotificationTest` class
from `test_push_notifications.py` to `test_classes.py` as we plan to
import it and reuse it in other files.
This commit also renames `PushNotificationTest` to
`PushNotificationTestCase` to align with our naming convention
in `test_classes.py` to name classes, which act as a parent class
with helper methods and no actual test within itself, with a
"TestCase" suffix.
`TestPushApi` was not a great name to reflect what it specifically
tests.
Renamed it to `TestAddRemoveDeviceTokenAPI`. It's test methods
are also renamed for clarity.
This commit moves `AnalyticsBouncerTest` to a new
`test_zilencer_analytics.py` file.
It helps in making it easier to work with `test_push_notifications.py`
which was 5000+ lines of code.
The demo_organization_scheduled_deletion_date has never been used
on the upgrade page, and currently raises a Zod error as what is
being sent for the value of that page param is a datetime object,
and not the datetime object converted to an integer.
We really only need the boolean value that checks if the demo
organization scheduled deletion date is not None for the upgrade
page logic, which is set in the context dict for that page, but
not in the page params.
Updates the "banner-link" class, which is currently only used
in the demo organization deletion info banner so that the link
text is not underlined when the user is not hovering over the
link text.
Updates the desktop notificaiton banner example in the devtools
showroom for the banner redesign to have the current banner text
that's used in navbar alert.
Similar to group based setting values, we expect
the client to send the previous content alongwith
the edited content to the edit message endpoint.
We reject the request incase the previous content
doesn't match the current message content, which
could happen in case two users simultaneously edit
a message - which will be implemented in #33051.
This class will be inherited by all errors related to
some sort of mismatch from the expected value.
This is a prep commit for #33051, as a part of which we
add a new exception class for message content mismatch.