Commit Graph

22989 Commits

Author SHA1 Message Date
Umair Khan 90994bccac user-groups: Recognize single asterisk for group mentions.
The character combination of @* now begins a group mention, so
this test is no longer valid.
2017-11-27 09:16:09 -08:00
Umair Khan c78846a274 markdown.js: Add error function to blueslip.
If we do not add this, we get an exception before we reach the
assertion.
2017-11-27 09:08:30 -08:00
Umair Khan 9d0eea8dd1 user-groups: Add is_member_of. 2017-11-27 09:08:30 -08:00
Rhea Parekh 1d826ae201 composebox: Warn when linked to private streams.
Fix issue #6860
2017-11-27 07:41:59 -08:00
Rohitt Vashishtha be56a99734 popover: Populate compose_box with popover user's email.
Replaces use of compose.respond_to_message with compose.start, manually
populating the email field with the popovered user's email.

Fixes #7526.
2017-11-26 22:59:37 -08:00
Tim Abbott 649b7b8b9f internal_send_message: Enforce being passed cross-realm bots.
We include ERROR_BOT in this set, even though it's not technically
cross-realm (it just lives in the admin realm).

This code path does not correctly handle emails that correspond to
multiple accounts (because `get_system_bot` does not).  Since it's
intended to only be used by system bots, we add an appropriate
assertion to ensure it is only used for system bots.
2017-11-26 17:14:23 -08:00
Tim Abbott ae8e203717 actions: Merge internal_prep_message into internal_send_message.
We also document the fact that only system bots are supported here.
2017-11-26 17:14:23 -08:00
Tim Abbott 6952dcbdac embedded bots: Stop using internal_send_message for non-system-bots.
This was causing problems, because internal_send_message assumes that
there is a unique user (across all realms) with the given email
address (which is sorta required to support cross-realm bot messages
the way it does).

With this change, it now, in practice, only sends cross-realm bot
messages.
2017-11-26 17:14:23 -08:00
Tim Abbott 27582782fa embedded bots: Flip around ordering of rate-limiting check. 2017-11-26 17:14:23 -08:00
Tim Abbott 5306a9634d email_mirror: Rewrite to not use internal_send_message.
This was causing problems with the fact that `get_system_bot` now only
works for actual system bot users.
2017-11-26 17:14:23 -08:00
Eeshan Garg 5b8f38f4e3 webhooks/bitbucket2: Ignore push events with no changes.
We now ignore payloads where payload['push']['changes'] is empty,
because an empty push doesn't really convey any useful information.

I couldn't find a way to replicate the action that would generate
such a payload, so I took one of our existing payloads and editted
out payload['push']['changes'] myself, so this payload is not
authentic.
2017-11-26 17:03:07 -08:00
Tim Abbott 2210f627a5 signup: Switch active mirror-dummy users to an AssertionError.
Previously, this was a ValidationError, but that doesn't really make
sense, since this condition reflects an actual bug in the code.

Because this happened to be our only test coverage the ValidationError
catch on line 84 of registration.py, we add nocoverage there for now.
2017-11-26 16:13:45 -08:00
Vishnu Ks b9bc1c2b33 Eliminate get_user_profile_by_email from test_classes. 2017-11-26 15:47:56 -08:00
Tim Abbott d1ff4293a5 backends: Remove assumption that only one user can have a given email.
I probably should have just done this in the original implementation;
there's only a small downside in the form of an extra database query
when trying to authenticate a user who doesn't exist.
2017-11-26 15:42:48 -08:00
Vishnu Ks 610eb557b8 backend: Make password reset form support multi realm membership. 2017-11-26 15:35:25 -08:00
Vishnu Ks 9f225360dc register: Make /register redirect to find accounts in root domain without realm.
If there is no realm in the root domain don't show
registration form. Instead just redirect to find
accounts page.
2017-11-26 15:32:17 -08:00
Vishnu Ks bab0b913ee test_signup: Extract logic for realm-creation test to a function. 2017-11-26 15:29:16 -08:00
Vishnu Ks 1b5753d021 test_signup: Fix assertIsNone check for realm in RealmCreationTest. 2017-11-26 15:27:33 -08:00
Tim Abbott c3c978e55d docs: Document the new queue_json_publish model in our unit tests. 2017-11-26 11:49:42 -08:00
Tim Abbott 9fcdb6c83a notifications: Use call_consume_in_tests for email sending.
This adds a bit of test coverage with really no downside.
2017-11-26 11:46:07 -08:00
Robert Hönig 0e0a8a2b14 queue processor tests: Call consume by default.
This significantly improves the API for queue_json_publish to not be
overly focused on what the behavior of this function should be in our
unit tests.
2017-11-26 11:45:34 -08:00
Shubham Dhama 5e23bfa779 typeahead: show typeahead for syntax of the from @**... or #**...
Fixes: #7494.
2017-11-26 11:18:47 -08:00
Rohitt Vashishtha cd83b94f3d git-docs: Make links to Zulip's git-tools at relevant places.
Tweaked by tabbott to fix a few issues with the text found while
looking at this.
2017-11-26 11:14:16 -08:00
Rohitt Vashishtha a9e915007a git-dogs: Move working-copies to docs/git. 2017-11-26 09:15:50 -08:00
Rohitt Vashishtha e2c1cf6832 git-docs: Move fixing-commits to docs/git. 2017-11-26 09:15:50 -08:00
Rohitt Vashishtha e811675831 git-docs: Merge two cheat-sheets and move to docs/git. 2017-11-26 09:15:50 -08:00
Rohitt Vashishtha ae0732e4f2 git-docs: Fix typos and make minor edits to working-copies. 2017-11-26 09:15:50 -08:00
Balaji2198 585cd36a2e setting: Align elements properly in invite users.
Adds a margin-top to `Check all` and `Uncheck all` elements.

Fixes #7488.
2017-11-26 09:13:33 -08:00
Eeshan Garg 15bf0ebc61 css: Fix overflowing long URLs in Markdown macros.
Long URLs in Markdown macros overflow their containers without this
property. This reverts 0dc91a9148.  We
will likely need to fix the original Windows bug that
0dc91a9148 has resolved another way.
2017-11-25 17:02:38 -08:00
Eeshan Garg 23162a1433 github_webhook: Use indented Markdown macros. 2017-11-25 17:01:11 -08:00
Eeshan Garg 1dca7cc367 webhooks/beanstalk: Use indented Markdown macros. 2017-11-25 17:01:11 -08:00
Eeshan Garg 8b43e07fc5 webhooks/codebase: Use indented Markdown macros. 2017-11-25 17:01:11 -08:00
Eeshan Garg 880fd5497a markdown: Add indented versions of multi-line Markdown macros.
This is part of our efforts to change our integrations/webhooks
docs to follow the same sort of numbered-list format as our /help
docs. In order to indicate that paragraphs separated by newlines
are part of the same numbered-list point, every paragraph must be
indented 4 spaces.
2017-11-25 17:01:11 -08:00
Tim Abbott 6968b540c8 mypy: Remove type: ignores that are unnecessary with new mypy.
Mostly these can be removed because the broken LXML stubs were removed
from typeshed in https://github.com/python/typeshed/issues/525.
2017-11-25 10:06:28 -08:00
Rhea Parekh 84847b811b requirements: Upgrade mypy to 0.550.
We have to add a few type: ignores due to mypy 0.550 having some bugs
in the new imaplib stubs in typeshed.

Fixes #7387.
2017-11-25 10:06:27 -08:00
Tim Abbott d639e31641 lint: Fix check-templates handling of team.html.
This prevents some unnecessary error messages when running the linter
on a single file.
2017-11-25 09:43:01 -08:00
Tim Abbott 13a1b44aa8 settings: Fix missing target=_blank on realm emoji images.
This resulted in problems with the desktop app, where clicking these
links would leave the user in a situation where they needed the "back"
button in order to get back to the webapp.

Fixes zulip/zulip-electron#342.
2017-11-25 09:43:01 -08:00
Rohitt Vashishtha 146aed3cc3 gitignore: Ignore package-lock.json generated by npm.
See https://chat.zulip.org/#narrow/stream/code.20review/subject/pull.20request for discussion.
2017-11-24 10:25:28 -08:00
Joshua Pan 9e8ae68dfb vagrant: Add NFS backend for file synchronization for OSX.
This is intended to fix serious issues with frequent guest crashes on
OSX High Sierra with Virtualbox and the default file synchronization.

Note from Tim: We've tried this idea before, and it worked for Mac,
but caused problems for non-Mac users of our Vagrant setup that
resulted in it being reverted in
1432e9afb0.

Hopefully the new conditional will handle things correctly in both Mac
and Linux.
2017-11-24 10:16:07 -08:00
Robert Hönig 0dc91a9148 css: Fix code blocks overflowing for integration names. 2017-11-24 09:26:08 -08:00
Cynthia Lin b607d26f0a lightbox: Fix image metadata not displaying at full width when possible. 2017-11-24 09:21:31 -08:00
Vaibhav Sagar 711f7bca3b upload: Fix typo in animated GIF error message.
s/must be have/must have the/.
2017-11-24 09:08:38 -08:00
Tim Abbott 6f53d65e56 docs: Update a few broken links to the Git guide. 2017-11-23 16:24:00 -08:00
Harshit Bansal fa3602b61f docs: Split 'git-guide.md`.
This should make our Git documentation more readable and less
intimidating.
2017-11-23 16:04:18 -08:00
akashnimare 271c3c1101 portico: Fix portico dropdown bug.
This fixes a responsiveness bug where the portico dropdown was not
showing up properly in a mobile view.
2017-11-23 15:56:50 -08:00
Sumana Harihareswara 7821acde6b /team: Fix typo. 2017-11-23 15:18:26 -08:00
Tim Abbott 1152246993 Revert "reactions: Change from grey to translucent."
This reverts commit 30f45ac061.

This commit caused problems with the compose box emoji picker
overflowing its bounds in Firefox at 90% zoom.
2017-11-23 14:55:00 -08:00
Tim Abbott 0f8ee343de node: Fix copy_and_paste test output.
I'm confused how this was passing when I tested previously.
2017-11-23 14:18:28 -08:00
Tim Abbott cc8c8ab21c node: Fix style in copy-paste test.
This bug got merged due to a problem with Travis CI.
2017-11-23 13:06:17 -08:00
Tim Abbott 4d4532a27e copy_and_paste: Add a simple extensible test suite.
This commit is mostly about adding the test suite; some of the results
are things we'd like to change.
2017-11-23 12:59:01 -08:00