The hardcoded content (topic and message) for the screenshot configs are
loaded from `fixtureless_integrations.py`. Add a new
FIXTURELESS_SCREENSHOT_CONFIG_OPTIONAL_FIELDS dict to maintain the
optional fields of fixtureless screenshot configs, and load both into
FIXTURELESS_SCREENSHOT_CONFIG.
This commit does not set any screenshot configs, but only adds the
framework.
This does not include any screenshot configs, just defining the format,
and loading FIXTURELESS_SCREENSHOT_CONFIG from the file.
Co-authored-by: Lauryn Menard <lauryn@zulip.com>
The only callsite of do_export_realm calls `rmtree` on the output
path, which means this symlink is always dangling. Since realms can
also be exported by end-users, following it would always be a race
condition, anyways.
Remove it.
Emails to missed-message email addressees which are marked
"auto-replied" are clearly auto-replies, and will not contribute
usefully to the conversation. We also ignore "auto-generated" emails
to missed-message addresses, as they must actually be auto-replies
which are misclassifying themselves, as missed-message addresses are
not meant to be targets for any auto-generated emails.
We accept auto-generated and auto-replied emails to stream incoming
email addresses, as auto-generated emails to those are clearly useful,
and auto-replied emails are unexpected enough to allow (given that
Zulip does not produce outgoing emails From: stream email addresses).
There is no need for 'select_related("usergroup_ptr")' in queries
for NamedUserGroup table because Django always does a join against
base UserGroup table.
For get and filter queries of NamedUserGroup, realm_for_sharding
field is used instead of realm field, as directly using
realm_for_sharding field on NamedUserGroup makes the query faster
than using realm present on the base UserGroup table.
Anonymous groups were being created for stream permission
settings when calling the subscriptions endpoint without
any streams data or when calling it only for subscribing
users to streams and not for creating any new streams.
This commit makes sure that no such unused anonymous groups
are created.
This commit renames `stream_creator_or_nobody` value for
`default_group_name` field in `server_supported_permission_settings`
object to `channel_creator`.
In #35965 we added `push_device_registered_user_ids` to message &
update_message event.
Zulip servers with such events in their event queues when upgraded
to the new version set push_device_registered_user_ids to empty list,
which is incorrect - it leads to no push notification sent.
This commit adds compatibility code to handle such events. The newly
introduced `push_device_registered` check is used only for events
with `push_device_registered_user_id` present in them.
Previously, we enqueued events to "missedmessage_mobile_notifications"
even for users who had no registered push devices.
'handle_push_notification' later used to perform the check & skip
if there were no registered devices.
This commit avoids putting such events into the
"missedmessage_mobile_notifications" queue at all. By doing so,
we reduce unnecessary churn.
Fixes#21544.
The network prefix (e.g. 64) identifies the network portion
which determines which bucket should that IPv6 belong to.
Implemented as a generic approach, so we have the option
to use different prefix sizes (leading to different buckets)
in the future.
Add comprehensive assertions for which IPv6s
are expected to belong to the same bucket and which are not.
This ensures that the new choice of zstd compression does not break
the previous, still-running, install during upgrades when the list of
cache_key_prefixes is updated.
Real people have 1-character names. As seen by the previous attempt
to enforce length, in b7779667fc, real
people have names with all sorts of lengths. All that we should care
about is that they're non-empty.