Scott Feeney
1c2479c807
Fix overly-tight coupling in set_stream_color test
...
The test will fail if a new attribute is added to the structure that
gather_subscriptions() returns. It should only be concerned with the
subscription's color.
(imported from commit fd5bad97bbce2544e0078ee029f54d4e45da9c15)
2013-09-06 23:13:47 -04:00
Leo Franchi
cf59f07fed
Replace alert_words as event contains full list
...
(imported from commit 489975f8bcbd0c3bcec07dd5ed62de5cae686140)
2013-09-06 16:05:08 -04:00
Leo Franchi
a67d461139
Hoist joining of message content in alert_words processor
...
(imported from commit 5025b7108839ddc04d6d9e575a9a288223526fe8)
2013-09-06 16:05:08 -04:00
Leo Franchi
7d76c47321
Re-enable alert word bugdown processor for staging
...
(imported from commit a9fb8284a47d18b97b84d3ce37482132b21d3885)
2013-09-06 14:51:40 -04:00
Leo Franchi
8ad6a0daa9
Cache realm alert_words to avoid database hits when rendering
...
We found that since bugdown processes are threaded, the cost of
doing a db query in a markdown processor is quite high---each
thread must start up a new db connection including a SSL handshake
etc. We should strive to keep our rendering pipeline free of mandatory
DB queries.
(imported from commit 555066bd03da6c681b74ce6137acc264eb41c55d)
2013-09-06 14:50:25 -04:00
Leo Franchi
7b375634f9
Temporarily disable alert_words markdown processor on staging
...
(imported from commit ab3eed4ce36ebcd3d928d2d92fc34c9ebacc11f9)
2013-09-06 13:39:26 -04:00
Leo Franchi
252045fe2e
Fix assignee in JIRA created message
...
(imported from commit 5ebadd14dee58c20746c80dfd99ba70a3d772ab6)
2013-09-06 11:24:03 -04:00
acrefoot
cf3e98d74a
use staging for wdaher.com for the email script
...
(imported from commit fbad47386f5c48785f766886218370612db31c26)
2013-09-05 19:19:41 -04:00
acrefoot
592e1ead6b
Actually use the realm specified by the email mirror when doing the markdown
...
(imported from commit 00b909b1d0c70a3523ab53d2f91815ab14ba2a6f)
2013-09-05 18:24:55 -04:00
Zev Benjamin
cb78014eef
bugdown: Allow block-level block quotes
...
It is triggered by specifying the "language" of a code block to
"quote" or "quoted":
Hamlet said:
~~~ quote
To be or **not** to be.
That is the question
~~~
(imported from commit 847a0602e335e9f2955e32d9955adf8ac8de068c)
2013-09-05 17:34:28 -04:00
Zev Benjamin
dd26260884
bugdown: Clarify variable name
...
(imported from commit 27968536bd6a3fcda6d26d8dde7f82d9f0990dd2)
2013-09-05 17:34:28 -04:00
Zev Benjamin
b3644ecfad
Fix attribution of Github issues messages
...
(imported from commit 941e52e51dfd9fddfe4f86bb33f25877d6d0edbd)
2013-09-05 16:04:59 -04:00
Zev Benjamin
2f1551e745
Replace comment references to trac.humbughq.com with trac.zulip.net
...
(imported from commit 231d0884345be525d58ce51f48a76bba6960f09d)
2013-09-05 15:43:08 -04:00
Zev Benjamin
5c81148839
Switch our trac realm filter to use trac.zulip.net
...
(imported from commit 19163f5be01a1d9370d9ed45c55bedd670772dac)
2013-09-05 15:43:07 -04:00
Kevin Mehall
e58e6f1b7d
Check admin permissions on the target realm, not on their own realm.
...
Trac #1772
Also abstracts this into a method.
(imported from commit f435b3379fb5387f8b3fdf7ca728ab760eadbf95)
2013-09-05 15:36:59 -04:00
Tim Abbott
ce710292ca
Always use external-content.zulipcdn.net for mit.edu realm.
...
(imported from commit 21d1101185bf52f21fcc345e791217311e9c0a13)
2013-09-05 14:35:42 -04:00
Tim Abbott
b557b94d0b
bugdown: Rewrite image urls to avoid mixed-content warnings.
...
(imported from commit fc0a41befb04f2a8aad2937a856366ac3cadb192)
2013-09-05 14:35:29 -04:00
Tim Abbott
cdfc6dc10a
bugdown: Fetch youtube preview images over HTTPS.
...
(imported from commit 9dbf3c21083cbbcf1288789f400c33ec735d4416)
2013-09-05 14:35:29 -04:00
Tim Abbott
3f1c967e3d
Clean up approximate_unread_count.
...
The new version is more accurate (doesn't rely on UserMessage IDs
being sorted, which they aren't necessarily) and simpler.
(imported from commit 671dd89dc8881ae2dcb8d0e804fd65458e074a29)
2013-09-05 14:35:29 -04:00
Leo Franchi
663fd4653f
Feature-flag alert words to staging + reddit
...
(imported from commit 1fe9c596b26ce6676514719e4ed2e185108685cb)
2013-09-05 10:21:39 -04:00
Leo Franchi
41b286232d
Allow filtering to alerted messages with is:alerted
...
(imported from commit 99834f1ee1b9b2e0f5c7427afa1494bf404e3626)
2013-09-05 10:18:41 -04:00
Leo Franchi
897dd87b94
Add a span around alert words to mark them visually
...
(imported from commit 9b8fbbd957086f1eeaa3409e5830aa6d7974fbe8)
2013-09-05 10:18:40 -04:00
Leo Franchi
b2ddd670e4
[schema] Add backend support for per-user alert words
...
(imported from commit 7a9c596a010cbedbddf594c5d9c68bb9ed46d122)
2013-09-05 10:18:40 -04:00
Kevin Mehall
6b820038ad
Server side tests for message editing, including subject propagation.
...
(imported from commit 0a68bdc337eda1b04976fb41a50a29f9f626ef25)
2013-09-04 14:51:46 -04:00
Kevin Mehall
19a835e7d5
Add a checkbox that propagates topic edits to subsequent messages.
...
Trac #1348
(imported from commit 28e2a8cb3ecda5ec50d17501f4ccbd8644212065)
2013-09-04 14:51:46 -04:00
Scott Feeney
6adfed7f3d
Add backend support for basic Desk.com webhook
...
(imported from commit 425a26b2ba5ffd4f4437e8d8438e8ef540d7b1ee)
2013-09-04 13:19:23 -04:00
Scott Feeney
a213fb5df2
Comment that authenticated_rest_api_view does Basic auth
...
(imported from commit 145ea6b0a17ab904c32e23e809410f56448baa72)
2013-09-04 13:19:22 -04:00
Leo Franchi
7e6af0a5d0
Mark messages from the desktop app as sent_by_human
...
(imported from commit 001073221387cbbaa541b17f9a377490562a28f1)
2013-09-04 11:00:11 -04:00
Luke Faraone
085fdebc98
Use the X-Gm-Original-To header instead of iterating through To/Cc/Bcc
...
This will allow mail with an implicit destination (mailing lists, complex
forwarding) to be received by our system.
See http://support.google.com/a/bin/answer.py?hl=en&answer=2368151 for
documentation of Google's behaviour that adds this header.
(imported from commit f8fd500e3c27e12af5941c63c91d5c796a2cd24a)
2013-09-03 17:46:44 -04:00
Tim Abbott
eeb04ed78e
deactivate_user: Only delete sessions that aren't expired.
...
(imported from commit e3d844a55581a7e7faab8ea9ed6703480fae8f51)
2013-09-03 11:40:42 -04:00
Kevin Mehall
be5c90c217
Add test for realm-specific emoji
...
(imported from commit 2148038b300b71afe0a7517709ed0404536b69fd)
2013-09-03 11:01:01 -04:00
Scott Feeney
549c644480
Move webhooks views to a separate file
...
(imported from commit 73db9f5ccc03d19024f35001b0805ca17eeadff7)
2013-08-30 10:18:49 -04:00
Scott Feeney
6eea2d7988
Rename views.py to views/__init__.py
...
(imported from commit 6d2fc769b3997f8ae9aea1119ebe1c27872baf42)
2013-08-30 10:18:49 -04:00
Jessica McKellar
acdfb6afa0
email mirror: make being one of many recipients okay.
...
Previously the email gateway had to be the only address in a recipient
field or we'd mis-parse the recipient.
This commit also makes the mirror correctly handle addresses of the
form "Jessica McKellar <jesstess@zulip.com>".
(imported from commit 7435f2b59b8f47dc599cc869f64597a730af7d12)
2013-08-29 18:13:21 -04:00
Jessica McKellar
c4157ed2b6
Make email mirror testing easier by using a different mailbox locally.
...
The mirror will use INBOX when deployed and Test locally. Send an
e-mail to the Test mailbox by including the word "localhost" in the
subject; a GMail filter will place it in Test on receipt.
(imported from commit bacf9a9554c8c5e1f3ec8497761edf2c15d3745d)
2013-08-29 18:13:21 -04:00
Scott Feeney
c94ba52d3a
Backend support for "announce stream"
...
(imported from commit dab3206a973083c3cee8225fa9ca71f4eecc269f)
2013-08-29 10:32:32 -04:00
Scott Feeney
e3247de572
Factor out get_active_user_profiles_by_realm()
...
(imported from commit 634ebf265b02303a938f7595de3622e25bc22b49)
2013-08-29 10:28:20 -04:00
Scott Feeney
09ff770435
Make invite-only stream invite notifications less confusing
...
Previously, when added to an invite-only stream, you got notifications
like this:
Hi there! We thought you'd like to know that Some Person just subscribed
you to the invite-only stream 'Secret stuff'
You can see historical content on a non-invite-only stream by narrowing
to it.
Note that the second line is irrelevant and confusing in light of the
first!
This commit leaves this out, and also, to make sure I didn't mess
anything up (and because I needed to change the tests anyway), adds a
test for invite-only stream notifications.
(imported from commit 49c333629c78fc06f6d2f1ec8a627c6d38e7716a)
2013-08-29 10:27:34 -04:00
Tim Abbott
ac1f9b5128
check_message: Allow zephyr mirroring bot to send to invite-only streams.
...
(imported from commit d45c75915cc4e29328768f1ed0e0ec972e5b7269)
2013-08-28 19:07:05 -04:00
Tim Abbott
5b62101a5f
check_message: Clean up confusing and redundant authorization checks.
...
(imported from commit 1b756c89ec740f988e8f15d21fb413de9947d658)
2013-08-28 19:07:05 -04:00
Tim Abbott
371654adb3
zephyr_mirror: Make Webathena work for golem.
...
(imported from commit 6f8bf1f44c521b22c9fc990711d2821e5a60761d)
2013-08-28 18:56:54 -04:00
Tim Abbott
591b42bb1c
bugdown: Clarify code around inline_interesting_links processor.
...
(imported from commit a1d734230135ab9099fafea7814bfec25754ea4e)
2013-08-28 18:56:53 -04:00
Steve Howell
1e88bb914e
Add test_private_suggestions() to search_suggestion.js
...
(imported from commit db89f8574a4f7e169e66ebaff3a9c2cd49a4b0dc)
2013-08-28 17:41:17 -04:00
Steve Howell
8363b7c59a
Add test_subset_suggestions() to search_suggestion.js
...
(imported from commit db9173ffa92ca225baf24a1103807034e4f31a7f)
2013-08-28 17:41:16 -04:00
Jessica McKellar
cf0f205f75
tests: check that non-subscribers can't send messages to an invite-only stream.
...
(imported from commit 5ee0fb49e994c4d283348d89a25606ca6d314005)
2013-08-28 16:43:40 -04:00
Jessica McKellar
2cc06aafe1
tests: don't skip message sending restriction checks!
...
We were using the internal do_send_message, which does not do any
security checks.
(imported from commit 14a31a39a392dd2bc6b79f4345aa80217d5356f2)
2013-08-28 16:43:40 -04:00
Jessica McKellar
f67f5b7619
Allow superusers to send messages to even private streams.
...
(imported from commit b7253174fa25d61b5bda056a5e5353e3b8ea918b)
2013-08-28 16:43:40 -04:00
Jessica McKellar
d72ed33dc6
Be more verbose and explicit in the checks on who can send a message.
...
It was getting hard to follow and is going to get more complicated
with a new super user check in a later commit.
(imported from commit 8d5cfa960824519d87ce0f09aab3a120ba9ef357)
2013-08-28 16:43:40 -04:00
Steve Howell
5b598a6d9c
Avoid churning the cache for stream name changes that don't change the cache key.
...
(imported from commit 1cc1ed01eaaaec4e6ddd6901fb5b877f831b604c)
2013-08-28 13:34:26 -04:00
Steve Howell
6aecdda7f7
Allow stream renames like corporate -> Corporate
...
(imported from commit 46d5078fb700631ef2a5b847eeeb055ff75d87d1)
2013-08-28 13:34:25 -04:00