Commit Graph

19472 Commits

Author SHA1 Message Date
Tim Abbott 215e3389e2 logrotate: Add a few more Django files to log rotation. 2017-07-16 10:49:15 -07:00
Tim Abbott 05723acb3c logrotate: Explicitly declare users/modes for log files. 2017-07-16 10:49:15 -07:00
Tim Abbott cef6285eee logrotate: Fix whitespace in logrotate configuration. 2017-07-16 10:49:11 -07:00
Tim Abbott 40cc6a3fa1 docs: Document disabling message edit history. 2017-07-16 10:13:26 -07:00
Durga Akhil Mundroy 146dfa6f0b org-permissions: Add allow_edit_history organiztion setting.
This new setting controls whether or not users are allowed to see the
edit history in a Zulip organization.  It controls access through 2
key mechanisms:

* For long-ago edited messages, get_messages removes the edit history
  content from messages it sends to clients.

* For newly edited messages, clients are responsible for checking the
  setting and not saving the edit history data.  Since the webapp was
  the only client displaying it before this change, this just required
  some changes in message_events.js.

Significantly modified by tabbott to fix some logic bugs and add a
test.
2017-07-16 10:10:06 -07:00
Rohitt Vashishtha d31686b576 docs: Fix typos in git-guide.md. 2017-07-16 00:22:05 -07:00
Cory Lynch a607130cae search_suggestion: Add tests for query with spaces.
Specifically, this checks to make sure that if you
surround an operand with quotes, having spaces inside
is permitted. Also, an extra space after the operator is
also permitted.
2017-07-14 17:33:09 -07:00
Cory Lynch 8125857999 filter.js: Add test coverage for space after operator. 2017-07-14 17:33:09 -07:00
Cory Lynch 35eb878e31 filter.js: Add test coverage for quoted operands. 2017-07-14 17:33:09 -07:00
Cory Lynch 1dba70ca0d search_suggestion: Fix highlighting for multi-word streams.
I deleted a test case that involved a highlighted stream, but
the query was empty. This produces kind of a weird result with
typeahead_helper.highlight_with_escaping, but this function already
has coverage in node_tests/typeahead_helper.js, so the check here
was essentially redundant anyway. Specifically, the highlighter
wraps every character individually with <strong>, and looks really
messy in html.
2017-07-14 17:33:09 -07:00
Cory Lynch 76e4350d4d filter.js: Allow quotes to handle spaces in operand.
Fixes #3496. This was just a simple regex addition to filter
to accept the format `operand:"foo bar"` as a token. Also,
it will now accept an additional space after the separating colon.
2017-07-14 17:33:09 -07:00
Tim Abbott 680381c9d0 setup_venv: Add virtualenv as a dependency for Debian.
Apparently, this was missing on Xenial, and we just never noticed
because the package was installed by default on Ubuntu.

It doesn't exist yet in Trusty.
2017-07-14 17:22:20 -07:00
Tim Abbott 4906a47c1a provision: Disable tsearch_extras for Debian. 2017-07-14 17:22:20 -07:00
Tim Abbott c1d2654f3a setup-apt-repo: Add pgroonga code for Debian stretch.
The Groonga apt repository for Debian has a slightly different
structure.
2017-07-14 17:22:20 -07:00
Tim Abbott 9efc017e8c provision: Add postgres versions for Debian stretch. 2017-07-14 17:22:20 -07:00
Tim Abbott f2f9494d17 requirements: Pin the version of python-cryptography.
This is a workaround for https://github.com/pyca/cryptography/pull/3603.
2017-07-14 17:22:20 -07:00
Yago González 2079d84018 lint: Add mobile stores to the capitalization exceptions. 2017-07-14 16:27:17 -07:00
Yago González 28d4ec7236 apps: Improve formatting and capitalization. 2017-07-14 16:27:17 -07:00
Yago González eb597a5af3 i18n: Mark strings for translation.
Tweaked by gnprice to omit proper names.
2017-07-14 16:27:17 -07:00
James Rowan 21b5536353 emails: Update subject lines of emails. 2017-07-14 15:20:04 -07:00
Vaida Plankyte 28ea174ed9 backend: Implement high contrast mode display setting. 2017-07-14 14:53:24 -07:00
Tim Abbott 5cdfd61f2b lint: Require translation tags on aria-label tags.
Since these are, by their nature, directly user-facing strings, they
should always be tagged for translation.
2017-07-14 14:48:17 -07:00
Vaida Plankyte 216900b9e3 frontend: Add aria-label attributes to textareas/input fields. 2017-07-14 14:45:10 -07:00
Vaida Plankyte 6be210052e frontend: Fix label 'for' attribute to include correct name. 2017-07-14 14:45:10 -07:00
Vaida Plankyte b533732c6b frontend: Change custom_invite_body to use an ID. 2017-07-14 14:45:10 -07:00
Vaida Plankyte 1675867f30 frontend: Make ID assignments unique. 2017-07-14 14:45:09 -07:00
Vishnu Ks a25ba763bf semaphore: Remove unused get_user_profile_by_email import. 2017-07-14 13:35:43 -07:00
Vishnu Ks 795a1a5701 jira: Replace get_user_profile_by_email in view.py. 2017-07-14 13:35:43 -07:00
Vishnu Ks b0e4cfd480 analytics: Replace get_user_profile_by email in client_activity. 2017-07-14 13:35:43 -07:00
Vishnu Ks e5c5960faa analytics: Remove unused get_user_profile_by_email import. 2017-07-14 13:35:43 -07:00
Vishnu Ks 0a67e00702 analytics: Use example_user in test_views.py. 2017-07-14 13:35:43 -07:00
Tim Abbott 67b30aa231 clean-repo: Reorder pycache removal to make output cleaner. 2017-07-14 12:34:18 -07:00
Steve Howell 475eb21a5e Revert commits related to client_message_id.
I pushed a bunch of commits that attempted to introduce
the concept of `client_message_id` into our server, as
part of cleaning up our codepaths related to messages you
sent (both for the locally echoed case and for the host
case).

When we deployed this, we had some strange failures involving
double-echoed messages and issues advancing the pointer that appeared
related to #5779.  We didn't get to the bottom of exactly why the PR
caused havoc, but I decided there was a cleaner approach, anyway.
2017-07-14 12:13:35 -07:00
Sawant Shah d3cce041a4 documentation: Make entire li element clickable.
documentation: Make the whole 'li' element clickable in left sidebar
links in /help/ page, instead of just the link part.

Fixes: #5797.
2017-07-14 09:52:36 -07:00
Tim Abbott 786b339b96 email_mirror: Fix exception for emails with no valid content type.
If a broken email shows up with no text or email content-type, we
were attempting to return an undefined variable.
2017-07-13 22:19:49 -07:00
Vaida Plankyte c7c533fd4d frontend: Add feature illustrations to landing page. 2017-07-13 22:12:26 -07:00
Harshit Bansal 92f6613bdd tools: Remove `tools/setup/emoji/download-emoji-data` tool.
This tool was used for downloading sprite sheets from iamcal's
repository. Since now we have moved to using `emoji-datasource`
npm package, this tool is no longer required.
2017-07-13 21:52:01 -07:00
Harshit Bansal ebdd8c9e3d emoji: Switch to using `emoji-datasource` npm package.
This commit does the following things:
* Instead of using a manual tool for downloading sprite sheets, use
  `emoji-datasource` npm package.
* Modify the `build_emoji` script to use sprite sheets from the npm
  package.

Bumps PROVISION_VERSION.

Fixes: #4730.
2017-07-13 21:52:01 -07:00
Harshit Bansal 420327b558 provision: Install NPM packages in the beginning of provisioning process.
NPM packages should be installed at the beginning of the provisioning
process so that later in the provisioning process if a script requires
any NPM package it can use it. Earlier, we were installing NPM packages
in the last as the installation process can fail due to network issues
but since we now retry in case the installation fails, they can be
installed safely at the beginning of the process as well just like apt
packages.
2017-07-13 21:52:01 -07:00
Abhijeet Kaur 85b7a89d85 bots UI: Display message for empty 'Active/Inactive bots' tab.
Add a line of text stating that there are no active or inactive bots.

This is for better understanding of the user, as blank screen that
used to appear in case of no bots being present might seem broken
to some.

Tweaked by tabbott to improve the English.
2017-07-13 21:51:48 -07:00
Tim Abbott cbd5223429 i18next: Disable i18n cache in development. 2017-07-13 21:37:56 -07:00
Tim Abbott 8c5cce7f2b i18next: Decrease cache expiration time to a couple days. 2017-07-13 21:34:35 -07:00
Brock Whittaker e3f1d025ae i18n: Garbage collect old translations from localStorage.
The old translation copies in localStorage were not being removed
when they were no longer needed, so we can free up the storage
by deleting them.

This was accidentally not merged months ago when originally
implemented, but it was written to fix #4443 and in fact does so.
2017-07-13 21:33:49 -07:00
James Rowan 59b5a2f862 emails: Rewrite the day 1 followup email. 2017-07-13 20:51:54 -07:00
Steve Howell fe66d4f3b0 Encapsulate message_state.maybe_restart_event_loop().
We now set the timer for missing events inside the
message_state class, where it's easier for us to know
which state we're in.
2017-07-13 23:42:27 -04:00
Steve Howell bc67f6a8ca Add sent_messages.track_messages().
This change has us tracking messages as soon as we start
sending the message to the server.  The next step is to
reconfigure the timeouts a bit to deal with the server not
responding.
2017-07-13 23:42:27 -04:00
Steve Howell 9ee2be4a0d Use client_message_id as key for sent_messages lookups.
We now use a client-side message id to track the state of our
sent messages.  This sets up future commits to start tracking
state earlier in the message's life cycle.

It also avoids ugly reify logic where we capture an event to
update our data structure to key on the server's message id
instead of the local id.  That eliminates the node test as well.

Another node test gets deleted here, just because it's not
worth the trouble with upcoming refactorings.
2017-07-13 23:42:27 -04:00
Steve Howell 7e88fb25b3 Move sent_messages callbacks into transmit_message().
This mostly sets the stage for a subsequent commit to start
using client_message_id as the key into sent_messages.

It has the nice side effect of making it more explicit that
certain things should always happen when transmit_message()
succeeds.

This commit does regress our node test coverage a bit.
2017-07-13 23:42:27 -04:00
Steve Howell 68f8ba0449 Generate client_message_id() sequentially.
This commit starts to decouple client_message_id from local_id.

We don't really take advantage of the decoupling in this
commit--in fact, it's a bit of a pain at first.  But this should
be a fully working checkpoint commit.
2017-07-13 23:42:27 -04:00
Steve Howell 25b59d0044 Extract sent_messages.message_state class.
This class helps us encapsulate the state of a message, with all
the dates/flags that get sent as part of /json/report_send_time.
2017-07-13 23:42:27 -04:00