Commit Graph

32334 Commits

Author SHA1 Message Date
Tim Abbott 361618f525 docs: Clarify documentation on Amazon RDS.
It's not actually a reasonable experience to use Zulip without working
full-text search, so we should more strongly direct folks to not do
it.

Fixes #12724.
2019-07-08 20:03:20 -07:00
Anders Kaseorg 167f30aa57 css: Make paragraph-to-list spacing consistent with normal line spacing.
The -2px list margin was almost but not exactly cancelling the 3px
paragraph margin, resulting in a line spacing exactly 1px taller than
the normal line spacing.

Signed-off-by: Anders Kaseorg <anders@zulipchat.com>
2019-07-08 19:58:21 -07:00
Anders Kaseorg b7e3f710b6 css: Specify message_content line-height in relative units.
This fixes (or at least reduces) a problem with inline `code blocks`
causing extra uneven vertical space below their line.  The absolute
line-height was being measured relative to the lower midline of the
smaller font-size in the code blocks.

Signed-off-by: Anders Kaseorg <anders@zulipchat.com>
2019-07-08 19:58:21 -07:00
Mateusz Mandera dae142a6a3 models: Remove redundant active=True filtering in get_huddle_user_ids. 2019-07-08 16:36:02 -07:00
Mateusz Mandera 8c987900ca retention: Move archive vacuuming days setting to DEFAULT_SETTINGS.
This was incorrectly placed in "Email settings", and accidentally not
overridable.
2019-07-08 16:35:53 -07:00
Mateusz Mandera 24ec1c7aa1 Revert "retention: Delete objects tied to a Message in one query with archiving."
This reverts commit 8f15884c7d. Using the
WITH ( ) ... DELETE method leads to a small performance drop, while
probably not offering many positives, so it seems appropriate to go to
the simpler case of just letting things get cleaned up by CASCADE.
2019-07-08 16:35:53 -07:00
Mateusz Mandera b55f24e07c retention: Avoid "SELECT realm" being run by Django ORM for each stream.
The  way the code changed in this commit was written caused Django to
fetch stream.realm from the database for every stream, leading to
redundant, identical queries. Each stream's realm is already known, so
we use that information.
2019-07-08 16:32:38 -07:00
Vaibhav 8af03b92a0 css: Use SCSS nesting in subscriptions.scss for `.stream-row .icon`. 2019-07-08 16:23:17 -07:00
Vaibhav d8efa258e5 css: Use SCSS nesting in subscriptions.scss for `.stream-row .check`. 2019-07-08 16:23:17 -07:00
Vaibhav 25cb9ff240 css: Reorder subscriptions.scss so `.stream-row .check` are in same place. 2019-07-08 16:23:17 -07:00
Anders Kaseorg c97ca677c9 nginx: Update TLS settings based on Mozilla recommendations 5.0.
Disable TLS 1.0 and TLS 1.1.  (We no longer need to support IE8 on
Windows XP.)

Prefer client-selected cipher order.  (Now that all enabled ciphers
provide good security, this allows mobile clients lacking AES hardware
acceleration to pick ChaCha20 for better performance.)

Disable session tickets.  (Mozilla discourages them based on
https://www.imperialviolet.org/2013/06/27/botchingpfs.html.)

Signed-off-by: Anders Kaseorg <anders@zulipchat.com>
2019-07-08 15:51:02 -07:00
Tim Abbott e87fcd0789 management: Fix obsolete check for double-adding a permission.
The .has_perm logic in this management command dates from use of
django-guardian that ended years ago.
2019-07-08 13:44:40 -07:00
Tim Abbott 9e9ddf464e management: Clean up a variable name in knight. 2019-07-08 13:42:05 -07:00
Vinit Singh 3cc790420a docs: Update docs to reflect the use of Ubuntu bionic in development. 2019-07-08 13:25:54 -07:00
Hemanth V. Alluri cecdec3097 openapi: Add test to see if code exists for documented endpoints.
In addition to the test which checks to to see if each endpoint in
code (urls.py) is documented in the openapi documentation (and with
the right arugments). We now also have a test to see if every
endpoint in the openapi documentation is a legitimate endpoint
also existing in code.

We do this by piggy-backing on the work done be the former test and
using set operations. This method avoid the need for an extra loop
and it uses set operations for additional speed and ease of reading.
2019-07-08 12:58:21 -07:00
Hemanth V. Alluri 718744c22d openapi: Refactor OpenAPIArgumentsTest.
The main things targeted by the refactor are the usage of comments and
moving the top-level variables to the scope of the class.

The movement of variables was to facilitate allowing us to perform
a reverse mapping test from OpenAPI URLs -> Code defined URLs.
2019-07-08 12:58:02 -07:00
Hemanth V. Alluri 74a72fc422 openapi: Add regex-to-openapi url pattern matching in the test.
With this, the automated validation test will now be able to
work with URL patterns containing regular expressions.
2019-07-08 12:34:31 -07:00
Hemanth V. Alluri 2738b09044 openapi: Remove a few "buggy" endpoints in the validation test.
By importing a few view modules in the validation test itself we
can remove a few endpoints which were marked as buggy. What was
happening was that the view functions weren't imported and hence
the arguments map was not filled. Thus the test complained that
there was documentation for request parameters that seemed to be
missing in the code. Also, for the events register endpoint, we
have renamed one of the documented request parameters from
"stream" to "topic" (the API itself was not modified though).

We add a new "documentation_pending" attribute to req variables
so that any arguments not currently documented but should be
documented can be properly accounted for.
2019-07-08 12:34:31 -07:00
YashRE42 c8b6afdca8 docs: Add warning about incorrect proxy settings for Vagrant setup.
Tweaked by tabbott for further clarity.
2019-07-08 12:30:31 -07:00
Wyatt Hoodes 886932fd23 provision: Update error output on failed `yarn install` reattempt. 2019-07-08 12:13:34 -07:00
Vishnu Ks d01ca8a390 circleci: Store XUnit test results.
Fixes part of #8593.
2019-07-07 22:31:11 -07:00
Vishnu Ks 1f250a3fd2 casper: Add support for exporting results as XUnit XML file. 2019-07-07 22:30:01 -07:00
Vishnu Ks 0b35bb96f0 requirements: Upgrade pillow from 5.4.1 to 6.1.0.
Fixes #12193
2019-07-07 22:28:54 -07:00
Vishnu Ks 4f65b50c44 requirements: Upgrade django-otp from 0.5.2 to 0.6.0.
This indirect dependency was upgraded separately since
it contained a migration with autogenerated name.
2019-07-07 22:28:54 -07:00
Vishnu Ks 41f6de1e92 requirements: Upgrade django from 1.11.20 to 1.11.22. 2019-07-07 22:28:54 -07:00
Vishnu Ks ccf6710cd6 requirements: Upgrade Twisted from 19.2.0 to 19.2.1. 2019-07-07 22:28:54 -07:00
Vishnu Ks 8143b4e47f requirements: Upgrade indirect python dependencies. 2019-07-07 22:28:54 -07:00
Vishnu Ks b75eb25708 docs: Include DO one click app in release checklist. 2019-07-07 21:49:31 -07:00
Tim Abbott ffeda5b015 i18n: Update translation data from transifex.
This has the side effect of triggering a `manage.py compilemessages`
for all users of the development environment, fixing a weird state
folks can get into after our recent migration of static/locale to
locale.
2019-07-04 17:08:34 -07:00
Anders Kaseorg f9dd7a8b4e typing_status.js: Remove var state.
It would conflict with `exports.state` after migration to an ES6
module.

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2019-07-04 16:50:23 -07:00
Anders Kaseorg 84bc2186eb settings_org.js: Remove var parse_time_limit.
It would conflict with `exports.parse_time_limit` after migration to
an ES6 module.

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2019-07-04 16:50:23 -07:00
Anders Kaseorg 653907e26a presence.js: Remove var presence_info.
It would conflict with `exports.presence_info` after migration to an
ES6 module.

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2019-07-04 16:50:23 -07:00
Anders Kaseorg ba90834a7a info_overlay.js: Remove var toggler.
It would conflict with `exports.toggler` after migration to an ES6
module.

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2019-07-04 16:48:33 -07:00
Anders Kaseorg 24831e5e85 buddy_list.js: Rename var height_to_fill to height.
It would conflict with `exports.height_to_fill` after migration to an
ES6 module.

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2019-07-04 16:48:33 -07:00
Anders Kaseorg bde31a54c7 bot_data: Rename delete to del.
`delete` is a reserved keyword that would interfere with the migration
to an ES6 module.

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2019-07-04 16:48:33 -07:00
Mateusz Mandera b8839302c0 retention: Fix migration making archive_transaction field not null.
DELETing from archive tables and ALTERing ArchivedMessage needs to be
split into separate transactions.

zerver_archivedattachment_messages needs to be cleared out before
zerver_archivedattachment.
2019-07-04 16:42:42 -07:00
Tim Abbott e14a40675b docs: Document changing EXTERNAL_HOST after backup restoration.
Fixes #12704.
2019-07-03 21:08:58 -07:00
YashRE42 dd1a6a97bd group-pms: Update list when new group pm is made.
The function activity.process_loaded_messages(messages) would be called
from message_events.js, this would call people.huddle_string with the
same message object, it was expected that this would return a list of
ids but the message.display_recipient attribute which was being sent
here used a "user_id" field instead of an "id" field.

Fixes: #12503.
2019-07-03 16:39:41 -07:00
Wyatt Hoodes af4eb8c0d5 export/upload: Refactor tarball upload logic to upload_backend.
The conditional block containing the tarball upload logic for both S3
and local uploads was deconstructed and moved to the more appropriate
location within `zerver/lib/upload.py`.
2019-07-03 15:40:35 -07:00
Wyatt Hoodes 8efb7b903b export.py: Have do_export_realm handle the export tarball.
This change is preliminary refactoring in order to improve the test
mocking strategy related to `test_realm_export.py`.

What this allows is the ability to simply mock a return value from
`do_export_realm`.  We can then use that value as a dummy url to
ensure a file has been served and can be retrieved.
2019-07-03 15:40:35 -07:00
Mohit Gupta 45f87ff44b search: Fix to allow access to group PM containing deactivated users.
Fixes: #12593.
2019-07-03 15:30:19 -07:00
Mohit Gupta 00cdba2090 actions: Add allow_deactivated option when fetching recipients.
Preparatory commit to allow viewing group PM with deactivated
users.
2019-07-03 15:30:15 -07:00
Mohit Gupta c971576b00 search: Refactor by_pm_with to use user profiles as common path.
Use UserProfiles instead of emails to fetch recipient objects for
narrowing; this is cleaner as it avoids unnecessary parsing and
unparsing.  We just map ids/emails operand to user profiles and then
use common code from there.

Fixes #12601.
2019-07-03 15:29:08 -07:00
Vaibhav db9e25db0d css: Nest `.pill-image` inside `.pill` in input_pill.scss. 2019-07-03 15:06:31 -07:00
Vaibhav 88835b9367 css: Use SCSS nesting in input_pill.scss. 2019-07-03 15:06:31 -07:00
Vaibhav 1c59a4a53c css: Reorder input_pill.scss so `.pill-container .pill` are in same place. 2019-07-03 15:06:31 -07:00
Rohitt Vashishtha d6e8bd6515 dependencies: Upgrade markdown from 3.0.1 -> 3.1.1.
Fixes #12192.
2019-07-03 15:06:19 -07:00
Anders Kaseorg 5e97e58df3 webhooks/freshdesk/doc.md: Remove unescape_rendered_html kludge.
This reverts commit f476ec7fac (#10312)
and replaces it with a proper fix using Jinja2 raw blocks.

Signed-off-by: Anders Kaseorg <anders@zulipchat.com>
2019-07-03 15:05:45 -07:00
Anders Kaseorg 9f08513acb bundles: Rename commons.js to common.js.
Signed-off-by: Anders Kaseorg <anders@zulipchat.com>
2019-07-03 15:03:22 -07:00
Wyatt Hoodes a238795823 run_casper: Add error output regarding Casper artifacts in CircleCI. 2019-07-03 14:58:48 -07:00