Steve Howell
1b987b0803
Add API for changing realm names.
...
(imported from commit 4bc117ae2ca4acb8896b45cd7058556317287ef8)
2014-01-29 10:16:57 -05:00
Steve Howell
a8bf9dfaf2
Add event support to do_set_realm_name().
...
(imported from commit c0abac9867aa211bb03e20a5dc1378cf476619ce)
2014-01-29 10:16:56 -05:00
acrefoot
4562e43aee
enable show_autoscroll_forever_option for Chris Aurelio
...
(imported from commit c0ae45fd5f6696d18383ea7451d25397a8102302)
2014-01-28 17:57:02 -05:00
Steve Howell
34f6c705e9
Rename update_realm_filter() to flush_realm_filter().
...
(imported from commit f52b45b627f73ece8c7348451cea48f32142e94e)
2014-01-28 17:40:01 -05:00
Steve Howell
75555ff16c
Rename update_realm_emoji_cache() to flush_realm_emoji().
...
(imported from commit fc97377113a3c2701addcc6fb0c5d1bc6f52933d)
2014-01-28 17:40:01 -05:00
Steve Howell
912f96e7ec
Rename update_stream_cache() to flush_stream().
...
(imported from commit c67844ef7feb1924ec495c4451e33b56b237c88a)
2014-01-28 17:40:01 -05:00
Steve Howell
1e948d2d51
Add do_set_realm_name/get_realm_name.
...
(imported from commit cf1cd9e1de1169f542e5f0690ef94a576dfd5663)
2014-01-28 17:40:01 -05:00
Steve Howell
c5edb58cd4
Turn flush_realm() into a post-save hook for Realm.
...
(imported from commit 97e44b51e2b35b4b5b64b4008f6a8d3585a26e33)
2014-01-28 17:40:01 -05:00
Steve Howell
57030f53cc
Use cache_set_many() in the flush_realm() code path.
...
The function update_user_profile_caches now operates on a list
of user_profiles, so callers like flush_realm() can benefit from
having a single cache_set_many() call. This slightly complicates
the call from flush_user_profile().
(imported from commit e064871d849b873c6ca388f00d4f7afaba1bf222)
2014-01-28 17:40:01 -05:00
Steve Howell
bbafd1dda8
Have flush_realm() make O(1) cache_delete() calls in a couple places.
...
For the realm-wide caches of active user dicts and alert words, just
make a single call to cache_delete() when you are deactivating a
realm. Before this change, we were doing O(N) cache_deletes as
part of the code path through flush_user_profile(). Now we just
call update_user_profile_caches() directly to clear the user_profile
caches.
This change also sets us up to turn flush_realm() into a post-save hook.
(imported from commit 699b4ea226ae15fc8c402cb4bc64ff6bdc041fc2)
2014-01-28 17:40:01 -05:00
Steve Howell
0eed5d20d2
Create cache.flush_realm() and call it from do_deactivate_realm().
...
This is a slight behavior change, as we now flush user_profile
caches for bots as well as humans.
(imported from commit 24c72c44d851ee4c66a67a4728cd6c548faeedcd)
2014-01-28 17:40:00 -05:00
Steve Howell
dbc1172a20
Extract update_user_profile_caches().
...
This function updates all the user_profile-related caches
that are keyed on a per-user basis.
(This had some test coverage already.)
(imported from commit 37979400514a7b46a6dcb7e36665b0fee2f3c525)
2014-01-28 17:40:00 -05:00
Steve Howell
3776d11c3a
Rename update_user_profile_cache() to flush_user_profile().
...
(imported from commit 1fddb8b8dfe7943ace70c51d762eeae2ee1203a0)
2014-01-28 17:40:00 -05:00
Steve Howell
aca5586cc0
Fix command line help for ./manage.py show_admins
...
(imported from commit d5de8832214db7b8a754f155b225e706b655260b)
2014-01-28 17:40:00 -05:00
Leo Franchi
e716a75d22
Properly render at-all and at-everyone mentions locally
...
(imported from commit 9533b83dba6a61f6c09da755fca54e8a24ad61e6)
2014-01-28 17:37:10 -05:00
Leo Franchi
1666403850
Find message objects in any lists when updating, as update might come from server
...
(imported from commit fa70180c9a228bff39efd846d465d0f1fa9bb4e7)
2014-01-28 17:31:02 -05:00
Jason Michalski
05e00575bb
Only send stream update events to clients that need them
...
Stream name and descriptions updates were being sent to all of the
active users on a realm. They are now only send to users who would have
information about that stream.
(imported from commit 2621ee8029f7356bf44ec493d7b5361bd546a8f5)
2014-01-28 17:12:15 -05:00
Jason Michalski
c573efd437
Ignore stream description update events for unknown streams
...
Clients can receive description updates for streams which are not in
stream_data. We should ignore the updates and warn that this has
occurred.
(imported from commit 3cd5a98a133012ae27ea0f43b03cc9d8e459e49c)
2014-01-28 17:12:15 -05:00
Steve Howell
1dd674c7ae
Make import statements take less vertical space.
...
(imported from commit 4d5901491d6c8c21fe045ac9751bc80613f94a59)
2014-01-28 17:04:51 -05:00
Steve Howell
80af0b8134
Move AuthedTestCase to test_helpers.py
...
(imported from commit bdaf63c5ed4e8d7c19e9c19f79151e8e7885c53e)
2014-01-28 17:04:51 -05:00
Steve Howell
a8f2ecf48c
Move context managers to zerver/lib/test_helpers.py
...
(imported from commit f57678fcb68aecdbb70ad86cd02cc5441695aaf5)
2014-01-28 17:04:50 -05:00
Leo Franchi
91fb4f6b8c
Fix clicking on link to message when sending outside this narrow
...
(imported from commit 6eeeb3b4c06021be21f48c8c5f2869904cd13b09)
2014-01-28 16:03:11 -05:00
Leo Franchi
ffb816391c
Use our own fenced code preprocessor, fixing output mismatches
...
(imported from commit 3d4abb1043349e30adf265342ee7c946a99b3ce2)
2014-01-28 15:35:32 -05:00
Leo Franchi
420a7cab7a
[marked] Add preprocessors in marked and allow them to insert arbitrary HTML
...
(imported from commit 367418266f4fbe2d723212845f49f0d4356fab52)
2014-01-28 15:35:32 -05:00
Leo Franchi
daecc7993a
Add a fenced code parser in javascript
...
(imported from commit 42b1dc18ca34cbbdf3cda6e833adde631a9d88f5)
2014-01-28 15:35:32 -05:00
Leo Franchi
dd7d31c7a6
Allow an empty home view when unnarrowing
...
(imported from commit 69f1a84b23ae8942db58851a1a1c6723c26df560)
2014-01-28 15:35:31 -05:00
Steve Howell
8aaf1cf8c2
Add API for removing default streams from a realm.
...
(imported from commit 06433126e31b372dff8a23eb8bbea14515138c85)
2014-01-28 14:30:37 -05:00
Steve Howell
af9a1e967f
Add API for adding default streams to a realm.
...
(imported from commit 0f48f722dd618c0d054aafdf3d931ef014a5c3ee)
2014-01-28 14:30:02 -05:00
Steve Howell
4cf677eb6d
Add do_remove_default_stream().
...
(imported from commit 559dcd93ca43f4ffba58119fe429df3f6843fd63)
2014-01-28 14:28:51 -05:00
Steve Howell
38668adcec
Extract DefaultStreamTest.get_default_stream_names().
...
(imported from commit e51ca97ca820778c161e24f4309517fc5f991dda)
2014-01-28 14:28:51 -05:00
Steve Howell
4ed661ca71
Add do_add_default_stream().
...
(imported from commit 34c96bdc3f5c2f7f119d2efe1606316878d34d03)
2014-01-28 14:28:51 -05:00
Steve Howell
b5e0eb35be
Add test_set_default_streams().
...
(imported from commit 359132c6c31c6de7524df3e9f34dff22273a61bc)
2014-01-28 14:28:50 -05:00
Steve Howell
af00f4609a
Extract get_default_streams_for_realm().
...
(imported from commit 6ef41615eb660fd161bfd53de09fea56266ddd2d)
2014-01-28 14:28:50 -05:00
acrefoot
a126292431
Add github issues tracking to CMU's realm
...
(imported from commit 5f4f00888687d14ddf6977e6b2de188294e8e44f)
2014-01-28 13:56:14 -05:00
Tim Abbott
439959592f
Rename build_offline_notification_event to build_offline_notification.
...
(imported from commit 88f4e35847faae999d72e804c9dc4d01ce51889f)
2014-01-28 13:42:50 -05:00
Tim Abbott
3fddc11cc2
Process message events more similarly to how other events are handled.
...
(imported from commit 5ebcd7a10fe54a8ecafb9550348a1e0418d4cbda)
2014-01-28 13:42:50 -05:00
Tim Abbott
934ac3fc88
Rename local variables inside process_new_message.
...
For greater clarity and in preparation for making message events be
processed more like how we process other events, we are changing:
data => event_template (for the input event we're processing)
event => user_event (for the event sent to a user's clients)
event => notice (for the missedmessage notifications)
(imported from commit 30c76c3588ebe2ac44e27e17a39df4a1403979cb)
2014-01-28 13:42:44 -05:00
Tim Abbott
1a90d50a1f
Clean up parsing in process_event and friends.
...
(imported from commit 408f9171fa481fa678dd6e27ea4cc610add232d5)
2014-01-28 11:01:30 -05:00
Tim Abbott
1cc3a6a903
Switch update_message to a generic event type.
...
(imported from commit db3c4d2326727ca05d25ab43ebc061d3e5cd0630)
2014-01-28 11:01:30 -05:00
Tim Abbott
167b883c38
Clean up the update_pointer tornado notification code path.
...
(imported from commit 94997dea54e6cc8e5b5a314a95d6114773462608)
2014-01-28 11:01:30 -05:00
Tim Abbott
0507b1bb06
Split out do_update_pointer from update_pointer_backend.
...
(imported from commit 25da1b324a9170677b0f6fc2e29841d6f2af9dec)
2014-01-28 11:01:29 -05:00
Tim Abbott
5ccb8b1bea
Add tornado_callbacks.send_event with clean API for sending events.
...
(imported from commit 07209a1744ac9372273858a3e69e8a2fd9e06e06)
2014-01-28 11:01:29 -05:00
Tim Abbott
98e4d7aeb3
tests: Change tornado event capture code to a better hook.
...
(imported from commit b3ef0ba2108ea8d6d7df31cab72b43a10bdeab93)
2014-01-28 11:01:29 -05:00
Tim Abbott
01dedb67f4
tests: Add assert_length helper function for query count asserts.
...
This way, when one of these asserts fails, the relevant failure will
be printed so that we can look at it.
(imported from commit c0dfe602b987174d151981c083c66fdfdeb01253)
2014-01-28 11:01:29 -05:00
Tim Abbott
bf0b0e24f2
Transition code for the Tornado message format changes.
...
(imported from commit 0f4a38db07517068d503f7a295c0c58ea4a02cdf)
2014-01-28 11:01:29 -05:00
Tim Abbott
3bcba79e77
Send message data to Tornado via rabbitmq instead of memcached.
...
This is a lot simpler and eliminates a possible failure mode in the
data transfer path.
(imported from commit 19308d2715bbd12dc9385234f1d9156f91bdfae0)
2014-01-28 11:01:29 -05:00
Jessica McKellar
fd3fc095b5
freshdesk: allow subject field to be empty.
...
The field should still be present, but Freshdesk now lets it be empty.
(imported from commit a317043947ecb6e234efabaaf6967ebe35e154a8)
2014-01-27 21:50:00 -05:00
acrefoot
07344bb283
Fix github hook when receiving commit_comments
...
Apparently (according to our error logs) it's possible for there to be a "position" but no "line" [number]
on a commit comment. According to the docs, line numbers are deprecated, although they're probably
more useful than diff line number (aka 'position').
(imported from commit d48f9efbe42293c9585442bd521b1843042eca65)
2014-01-27 16:39:40 -05:00
Leo Franchi
0917a27b79
Document realm filter regexp oddities
...
(imported from commit 987d8ea679f40c31f2fe2280b6d585f82b20e606)
2014-01-27 13:43:55 -05:00
Leo Franchi
dc3c6f34fc
Convert python-regex inline flag style to JS regex flags
...
(imported from commit 16c58fa54c0b87931d873290b175461ceb176d62)
2014-01-27 12:30:42 -05:00