Steve Howell
f61740551c
Bump slow query threshold to 1.2s
...
(imported from commit 8d97fc22d208274bc57b884828957dacf396348a)
2013-12-26 09:16:49 -05:00
Steve Howell
e0a1841b1c
Extract middleware.is_slow_query() and add tests.
...
(imported from commit 60902244a420800f558fdf2f1c38b4ed736c1286)
2013-12-26 09:09:15 -05:00
Tim Abbott
e77b34ed82
api: Extract client strings from UserAgent.
...
(imported from commit 22468dd0eb06bb52ed7273f3067ae3e2461ee0a5)
2013-12-19 17:20:43 -05:00
Tim Abbott
8c8c5337ef
UserPresenceTests: Fix use of API auth with json view.
...
While it does work, it's more an accident than intentional behavior
and not something we want to be encouraging (and it's messier code).
(imported from commit 3797147fc21836135a6304412bd3f958873a0576)
2013-12-19 17:20:43 -05:00
Steve Howell
7cded2a956
Show realm history on the main activity page.
...
This shows the number of messages sent by humans for the last
eight 24-hour periods, for each realm. "Messages sent" isn't a
perfect metric of activity, but it's easier to query with our
current data model than certain other statistics.
(imported from commit 9de3c479640a0b9dbc017b245dda21d951f4efa4)
2013-12-18 16:01:44 -05:00
Steve Howell
6f573feaeb
Add "length" option to check_list validator.
...
(imported from commit 4f8e203f964d1c936fe548b2f77a2e4aae745ae9)
2013-12-18 12:45:29 -05:00
Steve Howell
e7a42ffd02
Add test for /json/set_alert_words.
...
(imported from commit 307d87331870a89713030e8178b1aa14a31cfdfd)
2013-12-18 12:45:28 -05:00
Steve Howell
94e3c02649
Add test_bulk_invite_users().
...
(imported from commit bc8ab756dae0fd82e73b5b2a9655974c5fc839b0)
2013-12-17 16:24:59 -05:00
Steve Howell
bfb54b5a4d
Add validator support to REQ and has_request_variables.
...
Validators are similar to converters, but they don't have
to parse JSON, and they are told the name of the request
variable to help format error messages.
(imported from commit 3c33e301892519c67e70675006d5686d9f013353)
2013-12-13 18:19:10 -05:00
Steve Howell
60917c83d6
Add test_REQ_converter.
...
(imported from commit 4425c68a532dc8a6db3b76397156c4e9d92a5b44)
2013-12-13 18:19:10 -05:00
Steve Howell
668c0ab529
Validate principals in add_subscriptions_backend.
...
Make sure that principles is a list a of strings (unless it
is None). This includes a unit test.
(imported from commit c2e3f1c0cafc207ceca67d5a174ef4e29a32c6ca)
2013-12-13 18:19:10 -05:00
Steve Howell
0cdcf102a0
Validate parameters in update_subscriptions_backend.
...
w/unit tests added
(imported from commit a0c0d779279b35ffc5bf1fbe4c5c5a25af263c10)
2013-12-13 18:19:08 -05:00
Steve Howell
6b70e9ddb7
Add SubscriptionRestApiTest.test_basic_add_delete.
...
(imported from commit 735d6a0657952790de1d58c62cc983320ec402e8)
2013-12-13 18:19:08 -05:00
Steve Howell
4184b9d56f
Add validators.py (with tests).
...
This sets up a scheme to validate complex data structures and
give specific error messages for improperly typed parameters.
(imported from commit 33b2f070d993da4ee929119dd41503bd0128c8eb)
2013-12-13 18:19:07 -05:00
Waseem Daher
14a5c6bf66
twitter: Detect link styles more robustly.
...
* Deal with shorter tweet IDs
(some old tweets don't have a full 18-character ID)
* Allow trailing slash
* Deal with old-style #! syntax
* Deal with links that link to a photo
(imported from commit 008a98c806f3b8dddd9e2f18a8f002af6932766f)
2013-12-13 18:13:23 -05:00
Kevin Mehall
ebab4a59c9
Don't proxy https images through Camo on MIT
...
These images at least load now, but that's because Camo redirects
the browser to the origin server, so the only effect is an extra
round-trip time.
(imported from commit 0d6b9c888a5cdfaa9299272d74a085e872dfa434)
2013-12-13 17:27:01 -05:00
acrefoot
1bd420f12c
Show auto-scroll forever setting in /#settings
...
(imported from commit fa66cbe52836f230e551f25c47bd755b705387d2)
2013-12-13 11:50:11 -05:00
Tim Abbott
2e62cd5a74
Add tests for the events_register event application system.
...
(imported from commit 6c3dbe55d43f528b6a980bba3598ac30c0307a69)
2013-12-12 17:36:41 -05:00
Tim Abbott
71ad82b6aa
Add support for event queues with an included narrow.
...
This will allow us to substantially decrease the server-side work that
we do to support our Mirroring systems (since the personal mirrors can
request only messages that user sent) and also is what we need to
support a single-stream Zulip widget that we embed in webpages.
(imported from commit 055f2e9a523920719815181f8fdb44d3384e4a34)
2013-12-12 17:36:39 -05:00
Tim Abbott
bd977e9e5c
Add a basic test for the get_events API backend.
...
(imported from commit 6f5351947f2b30f13c3309720c8c7c2187d16d51)
2013-12-12 17:36:38 -05:00
Tim Abbott
0a7c6ac261
Remove legacy /api/v1/update_pointer endpoint.
...
(imported from commit 4e2d111cf00ab2064291b282795c4b89835d1c17)
2013-12-12 10:31:05 -05:00
Tim Abbott
0c79465950
Remove legacy /api/v1/get_profile endpoint.
...
(imported from commit c8e78be4c8549022556099cc13342627323c0b01)
2013-12-12 10:31:05 -05:00
Tim Abbott
01428e5076
Remove legacy /api/v1/get_old_messages endpoint.
...
(imported from commit 2ca426f08f9f862e756a1fda55bb2764997aeb76)
2013-12-12 10:31:04 -05:00
Tim Abbott
795f716daf
Remove legacy /api/v1/get_public_streams endpoint.
...
(imported from commit 49db0232e7f655308847f3ccef2b73368ab9b774)
2013-12-12 10:31:04 -05:00
Tim Abbott
2f1382d0b8
Change test names in running printout to be what test-backend takes.
...
(imported from commit 330aa6ca4ad5f8ebfe30042039d4a04d78f1691f)
2013-12-12 10:31:04 -05:00
Tim Abbott
0a952b1a66
Fix abuse of bugging login behavior with API URLs.
...
(imported from commit 3009cd094dff8891da415e1bfcf596ea6cb38abc)
2013-12-12 10:31:04 -05:00
Tim Abbott
33cdf0d019
Remove obsolete /api/v1/subscriptions/add endpoint.
...
(imported from commit 838e3a29219acf157f16258a46b0719d97ae46de)
2013-12-12 10:31:04 -05:00
Tim Abbott
664270a1c4
tests: Add put/delete helpers to avoid manually urlencoding.
...
(imported from commit 120b564b27ffd711e0f4e63279971433fb4aaa9b)
2013-12-12 10:31:04 -05:00
Tim Abbott
752e7aa84a
Remove obsolete /api/v1/subscriptions/remove endpoint.
...
(imported from commit 9fc6bdb4cc288aa7499399d1d281fb752ea3a52e)
2013-12-12 10:31:03 -05:00
Tim Abbott
23a3b078d6
Remove legacy /api/v1/get_subscribers endpoint.
...
(imported from commit 52ab7b1200c2a62d1f8c251ab8d2f187cd2eb50b)
2013-12-12 10:31:03 -05:00
Tim Abbott
cacd60860a
Remove legacy /api/v1/subscriptions/list endpoint.
...
(imported from commit 457ceec760488815a24b5695362a42f4a94aabdc)
2013-12-12 10:31:03 -05:00
Tim Abbott
b10278c8e0
events: Fix incorrectly empty event queues with virtual events.
...
I'm not sure this had much impact, but it's definitely a subtle bug.
(imported from commit 0260d4c5c35ce8eac683e84f1d939a6704ce4e2b)
2013-12-11 16:59:48 -05:00
Kevin Mehall
662edc2558
[manual] Backend support for Android GCM push notifications
...
This adds a dependency on gcmclient:
http://gcm-client.readthedocs.org/en/latest/gcmclient.html
pip install gcm-client
or
apt-get install python-gcm-client
(imported from commit 9f1fbf1f793e4a27baed85c6f1aa7a7b03106a10)
2013-12-11 15:37:48 -05:00
Leo Franchi
2c39e28ff6
Use realm filters from the database in bugdown
...
(imported from commit 8e12bfb1b1fe9cad694f80a189efa64b0f102e81)
2013-12-11 14:39:10 -05:00
Leo Franchi
1e7a22f14e
Replace other non-zerver uses of iPhone client
...
(imported from commit 0988e2c9bd0499a0711daed97f89aa672776f085)
2013-12-03 14:35:24 -05:00
Tim Abbott
abded5f886
Upgrade event flag collapsing to support all flag changes.
...
(imported from commit a2ca74b779d67148aee41e92e4a4cb716620e566)
2013-12-03 12:21:04 -05:00
Tim Abbott
d2486670a8
event: Add deduplication of server restart events.
...
(imported from commit e464aa8b68958fb9f9fe8c199b9e73df510d22bc)
2013-12-03 12:20:36 -05:00
Tim Abbott
0156e72352
Add tests for our event queues data structure.
...
(imported from commit 5c00251998d25cf2283737173e5af0b26ccbdad4)
2013-12-03 12:20:28 -05:00
Jessica McKellar
11d5f8bbc5
Add a test for unsubscribing from digest emails.
...
(imported from commit 145c25ae99cf66b9a447b2e3a44a3b7344dc9f59)
2013-12-02 18:58:04 -05:00
Tim Abbott
2a0c2207d2
Revert "Add tests for our event queues data structure."
...
This reverts commit 5be116d6cc983edaac240e83d1b950faa08d164c.
(imported from commit bc47f42235e9800906270a5776167f5ea001d9a2)
2013-12-02 11:03:04 -05:00
Tim Abbott
5b601d8492
Revert "event: Add deduplication of server restart events."
...
This reverts commit 05467929ba376a0ce173119c5d90d83671fc544b.
(imported from commit 4f24a0f1fe72e71fa368e1d818d9406a76c131be)
2013-12-02 11:03:04 -05:00
Tim Abbott
2c2f404cb6
Revert "Upgrade event flag collapsing to support all flag changes."
...
This reverts commit dadf3852f2ca7aaa85fb97b3d265c990b4e5a38a.
(imported from commit de5a95572aa955b4a9419b80a99d2446c51730e7)
2013-12-02 11:03:04 -05:00
Jessica McKellar
848c9ec7be
Add a test for unsubscribing from welcome emails.
...
(imported from commit c206bd9283e6be22b285abd583c6e80719260448)
2013-11-27 09:30:00 -05:00
Tim Abbott
e9f4612281
Upgrade event flag collapsing to support all flag changes.
...
(imported from commit dadf3852f2ca7aaa85fb97b3d265c990b4e5a38a)
2013-11-26 18:12:52 -05:00
Tim Abbott
fb5c42707e
event: Add deduplication of server restart events.
...
(imported from commit 05467929ba376a0ce173119c5d90d83671fc544b)
2013-11-26 18:12:52 -05:00
Tim Abbott
5a4df81202
Add tests for our event queues data structure.
...
(imported from commit 5be116d6cc983edaac240e83d1b950faa08d164c)
2013-11-26 18:12:52 -05:00
Leo Franchi
501f063426
Replace email_to_domain with split_email_to_domain and resolve_email_to_domain
...
Now that we support email aliases, we have to be careful when going from
an email address to a domain that we assume we can use to get a Realm
object for. When we care about the Realm's domain, we want to follow
any RealmAliases that exist for a certain domain.
When we just care about the original email address domain itself,
for comparison or other purposes, use split_email_from_domain
This removes the ambiguity of having to decide when to use
email_to_domain + RealmAlias or just email_to_domain
(imported from commit 0e199495502d946ce2e1aae56263e7e8665be4ed)
2013-11-26 10:45:01 -05:00
Kevin Mehall
b8a6100d2e
bugdown: Open #-relative links in the same window.
...
Stream notifications shouldn't leave you with tons of Zulip windows.
(imported from commit e5ebfeff51f1e579d30a3a12eaf7341ef82f0449)
2013-11-25 17:34:59 -05:00
Kevin Mehall
ca182ec062
Link to streams in notification bot messages.
...
It's a little weird that these still open in a new tab, but it might
be best to keep them consistent with all other links?
This is a first pass on Trac #1927 .
(imported from commit 390bdef790a83af4240ad5f5a82e572ef5824756)
2013-11-25 16:12:57 -05:00
Jessica McKellar
cbdb7152de
Add a test for one-click unsubscribes from missed message emails.
...
(imported from commit cb7c3ff0b24ed49e543b6a94b53bd709bd141318)
2013-11-25 15:18:40 -05:00