Commit Graph

18083 Commits

Author SHA1 Message Date
Aditya Bansal 15ea059aad pep8: Add compliance with rule E261 makemessages.py. 2017-05-31 17:07:15 -07:00
Aditya Bansal 5b0b8fd8bb pep8: Add compliance with rule E261 emoji_setup_utils.py. 2017-05-31 17:07:15 -07:00
Aditya Bansal ee369ceb0c pep8: Add compliance with rule E261 scripts/lib/email-mirror-postfix. 2017-05-31 17:07:15 -07:00
Aditya Bansal aa433f4342 pep8: Add compliance with rule E261 check_send_receive_time. 2017-05-31 17:07:15 -07:00
Aditya Bansal 9814bd77cc pep8: Add compliance with rule E261 google/google-calendar. 2017-05-31 17:07:15 -07:00
Aditya Bansal 42b0680ab2 pep8: Add compliance with rule E261 populate_analytics_db.py. 2017-05-31 17:07:15 -07:00
Aditya Bansal bcc247a5b1 pep8: Add compliance with rule E261 zilencer/urls.py. 2017-05-31 17:07:15 -07:00
Aditya Bansal 717e5ae393 pep8: Add compliance with rule E261 commands/create_realm.py. 2017-05-31 17:07:15 -07:00
Aditya Bansal 8680c87f56 pep8: Add compliance with rule E261 zerver/lib/push_notifications.py. 2017-05-31 17:07:15 -07:00
Aditya Bansal be66369b72 pep8: Add compliance with rule E261 tools/js-dep-visualizer.py. 2017-05-31 17:07:15 -07:00
Aditya Bansal 807fee68d6 pep8: Add compliance with rule E261 nagios/check-rabbitmq-consumers. 2017-05-31 17:07:15 -07:00
Aditya Bansal dee726f234 pep8: Add compliance with rule E261 scripts/lib/pythonrc.py. 2017-05-31 17:07:15 -07:00
Aditya Bansal 5989c88545 pep8: Make compliant zulip-ec2-configure-interfaces with rule E261. 2017-05-31 17:07:15 -07:00
Aditya Bansal 6b8e85e065 pep8: Make compliant check_zephyr_mirror with rule E261. 2017-05-31 17:07:15 -07:00
Aditya Bansal 49ae51f23a pep8: Make compliant check_user_zephyr_mirror_liveness with rule E261. 2017-05-31 17:07:15 -07:00
Aditya Bansal 6d0927ed0b pep8: Add compliance with rule E261 to check_personal_zephyr_mirrors. 2017-05-31 17:07:15 -07:00
Aditya Bansal cc9e08bf87 pep8: Add compliance with rule E261 to bots/check-mirroring. 2017-05-31 17:07:15 -07:00
Aditya Bansal 3c50019001 pep8: Add compliance with rule E261 to api/integrations/rss/rss-bot. 2017-05-31 17:07:15 -07:00
Aditya Bansal 5b6a21c100 pep8: Add compliance with rule E261 to api/examples/upload-file. 2017-05-31 17:07:15 -07:00
Aditya Bansal 30dfb54c65 pep8: Add compliance with rule E261 to analytics/views.py. 2017-05-31 17:07:15 -07:00
Aditya Bansal 061cb9ae44 pep8: Add compliance with rule E261 to analytics/tests/test_views.py. 2017-05-31 17:07:15 -07:00
Cynthia Lin 09419aa027 hotkeys: Allow `n` key to work on PMs.
Fixes #4885
2017-05-31 18:00:57 -06:00
Joshua Pan fd57fcbc1c node tests: Add coverage for blueslip errors in people.js.
This covers all blueslip errors and warnings
in people.js. These do not need to be tested
to rigorously and just need to be covered to
get people.js to 100% coverage.
2017-05-31 16:04:49 -06:00
Steve Howell cc81b7892d Add process_visible() call to maybe_select_closest().
This fixes a regression where we removed a call to
unread_ops.process_visible() inside of stream_list.js.  Now
we call it from within narrow.activate() in the the
maybe_select_closest() callback.
2017-05-31 12:40:57 -06:00
Pweaver (Paul Weaver) 2efecd4809 webpack: Fix webpack-dev-server to not inline serve bad sockjs url.
Fixes #5118.
2017-05-31 09:31:29 -07:00
Umair Khan 5d794d08dd test_bulk_message_fetching: Add debug code.
This test fails on self.assertTrue(delay < 0.001 * num_ids, error_msg)
randomly. This commit adds debug code to see what the real values of
paramters are.
2017-05-31 09:27:30 -07:00
Harshit Bansal fc0fb66d28 emoji: Fix realm emoji not appearing in settings page when reopened.
When the emoji settings page was reopened after uploading a realm
emoji without doing a page refresh, the uploaded emoji disappeared
from the emoji list. This was so because the emoji settings page uses
`page_params.realm_emoji` to render the emojis which was not updated
when a emoji was added.

Fixes: #5130.
2017-05-31 09:12:45 -07:00
Steve Howell e1f5a4e0bb Add test_expand_and_update_private_messages(). 2017-05-31 09:10:43 -07:00
Steve Howell 22dfb9f09d Add test_update_dom_with_unread_counts(). 2017-05-31 09:10:43 -07:00
Steve Howell 0b0c57bbe0 zjquery: Throw Error() object to get tracebacks.
If you throw a raw string in node, you don't get a traceback.
2017-05-31 09:10:43 -07:00
Jeremy Bowman 1dae2af7b0 Fix ARIA markup for settings menu
The settings dropdown was marked as having the "menu" ARIA role,
but contained no items with the "menuitem" role.  I assigned this
role to the focusable link elements, and gave the intervening "li"
elements (and other "li" elements used as separators and such)
the "presentation" role to allow those to be gracefully ignored
when appropriate.  Some of the links previously had the "button"
role, which I think was a holdover from a previous UI layout.

Fixes #5000.
2017-05-30 23:08:12 -07:00
Cynthia Lin b81e7ad51f hotkeys: Fix arrow key navigation in Streams modal.
Previously, one could not move past unsubscribed streams in the
Subscribed tab.

Fixes #5066.
2017-05-30 22:51:35 -07:00
Umair Khan 6ee08e0602 casper: Fix waiting condition in message deletion tests.
We now specifically wait for the length to decrease by one. This seems
like a more deterministic condition to wait on.

Previously we were waiting till the id of the deleted message remained
visible; intuitively, this should have worked but it seems that there
is some race condition that was causing the test to fail sporadically.
2017-05-30 22:49:59 -07:00
Pweaver (Paul Weaver) eb1a22a1d2 webpack: Fix webpack-dev-server urls for external resources.
This fixes issues some users found using the remote development environment.
2017-05-30 22:38:25 -07:00
Eeshan Garg fc6125ec2e api/setup.py: Upgrade the version to 0.3.1.
Apparently, PyPI is very strict about package file names. Once you
upload files for 0.3.0, and only wish to make minor changes and
re-release it as the same version, it doesn't let you and complains
about identical file names.
2017-05-30 22:25:14 -07:00
Eeshan Garg ea131936d6 api/setup.py: Upgrade to Beta and update homepage URL. 2017-05-30 22:25:14 -07:00
Eeshan Garg b309c403e0 webhooks/gitlab: Support Merge Request Hook reopen event.
Fixes #4795.
2017-05-30 22:11:37 -07:00
Steve Howell 4ec1260b41 reactions.js: Have an initialize() function. 2017-05-30 21:43:18 -07:00
Steve Howell 6149111b5e Add test_error_handling() for reactions.js. 2017-05-30 21:43:18 -07:00
Steve Howell b0b647c9e5 Add more code to test_add_and_remove_reaction().
This increases our line coverage a bit.
2017-05-30 21:43:18 -07:00
Steve Howell e7345bdd7f Improve error reporting in maybe_activate_stream_item.
This change should lead to clearer tracebacks when our
assumption about the stream list's list items get
violated, and we also short circuit some code in the
caller that tries to scroll to the active stream.
2017-05-30 21:26:55 -07:00
Steve Howell 561fba65d2 Remove spurious call to unread_ops.process_visible().
In stream_list.js we have some code to handle narrow activations,
and we were calling unread_ops.process_visible() only for
stream activations, not for PM-related activations, etc., so
our approach was inconsistent.

It also turns out that the call is redundant, since we call
unread_ops.process_visible() when the message pane scrolls as
part of updating the content.

Ideally, we want a more rigorous approach where we make this
call precisely when the new messages become visible to the user,
but the purpose of this fix is to de-clutter the stream_list
logic.
2017-05-30 21:26:55 -07:00
Eeshan Garg 2e81fdd319 api.html: Recommend pip install for installing API bindings.
We have an updated PyPI package now for our API bindings, so we
now recommend `pip install` rather than providing a download link
to the package.
2017-05-30 21:21:06 -07:00
Steve Howell b559364614 Use zjquery to test pm_list.js.
We now stub templates.render() to see what data gets passed in
to the template, rather than using jQuery to inspect the DOM that
gets created.  This changes the nature of the test to be less about
integration with the templating layer and more about how we pass
data into the template.

To compensate, we add more assertions to the relevant test
in templates.js.
2017-05-30 20:46:30 -07:00
Tim Abbott e321891f17 test-all: Don't run SVG optimizer by default. 2017-05-30 11:19:53 -07:00
Cynthia Lin 0600e1eb30 tools: Add optimize-svg tool for checking for unoptimized SVG files. 2017-05-30 11:15:56 -07:00
Cynthia Lin 76537665b9 integrations: Optimize SVG graphics. 2017-05-30 11:15:56 -07:00
Cynthia Lin 26afd4c162 integrations: Modify styling to emphasize label text. 2017-05-30 11:15:56 -07:00
Umair Khan 71f97b7bcb testing: Invalidate cache before counting queries.
To get accurate count of the queries, we should make sure that
caches don't come into play. If we count queries while caches are
filled, we will get a lower count. Caches are not supposed to be
persistent, so our test can also fail if cache is invalidated
during the course of the unit test.

This commit solves the problem with Stream cache. This cache comes
into play when we use `get_stream` function. If cache is valid,
we will not issue queries to Stream and Recipient table. I think
the problem was one of those rare occasions when the Stream cache
got invalidated during the course of the test, due to which query
count was increased by 2. After this commit, we intentially invalidate
the Stream cache.
2017-05-30 17:28:41 +05:00
K.Kanakhin 2434f2d96c messages: Add support for admins deleting messages.
This makes it possible for Zulip administrators to delete messages.
This is primarily intended for use in deleting early test messages,
but it can solve other problems as well.

Later we'll want to play with the permissions model for this, but for
now, the goal is just to integrate the feature.

Note that it saves the deleted messages for some time using the same
approach as Zulip's message retention policy feature.

Fixes #135.
2017-05-29 21:59:38 -07:00