Commit Graph

14823 Commits

Author SHA1 Message Date
Tim Abbott 4e171ce787 lint: Clean up E126 PEP-8 rule. 2017-01-23 22:06:13 -08:00
Tim Abbott 31e7dcd86b lint: Tag remaining PEP-8 rules with explanations. 2017-01-23 21:43:33 -08:00
Tim Abbott 376aa3e404 lint: Clean up E702 PEP-8 rule. 2017-01-23 21:37:27 -08:00
Tim Abbott de99f48ce7 lint: Clean up E401 PEP-8 rule. 2017-01-23 21:36:39 -08:00
Tim Abbott d6e38e2a5c lint: Clean up E123 PEP-8 rule. 2017-01-23 21:34:26 -08:00
Tim Abbott 9cc83f87fc lint: Clean up E241 PEP-8 rule. 2017-01-23 21:21:14 -08:00
Tim Abbott fe4f7b1170 lint: Clean up E711 PEP-8 rule. 2017-01-23 21:11:49 -08:00
Tim Abbott 9640a9e864 lint: Clean up E712 PEP-8 rule. 2017-01-23 21:11:18 -08:00
Tim Abbott e385b93448 lint: Clean up E713 PEP-8 rule. 2017-01-23 21:08:52 -08:00
Tim Abbott a088cdaa04 lint: Clean up E714 PEP-8 rule. 2017-01-23 21:07:45 -08:00
Tim Abbott d96f392147 lint: Clean up E741 PEP-8 rule. 2017-01-23 21:07:04 -08:00
Tim Abbott e5daec46ec lint: Clean up E306 PEP-8 rule. 2017-01-23 21:05:08 -08:00
Tim Abbott e3e92903eb lint: Document why E305 is turned off. 2017-01-23 21:03:46 -08:00
Tim Abbott e9158dd520 lint: Clean up E121 PEP-8 rule. 2017-01-23 21:02:39 -08:00
Tim Abbott 6f0d2a9445 lint: Clean up E115 PEP-8 rule. 2017-01-23 20:55:37 -08:00
Feorlen 378ac3abf3 Lint yaml files using text file rules.
Fixes #3404
2017-01-23 20:53:20 -08:00
Tim Abbott df3d6aee5d lint: Clean up E114 PEP-8 lint rule. 2017-01-23 20:52:58 -08:00
Tim Abbott 22d1aa396b lint: Clean up W503 PEP-8 warning. 2017-01-23 20:50:04 -08:00
Tim Abbott bde2da7dfd lint: clean up PEP-8 W391 rule. 2017-01-23 20:39:02 -08:00
Zev Benjamin f4d3cc6545 Annotate ignored pep8 rules to explain why they're ignored 2017-01-23 20:19:58 -08:00
Tim Abbott b3df1ddeb1 edit: Remove duplicate update_message_backend endpoint. 2017-01-23 17:22:42 -08:00
Tim Abbott 46ab7762e7 edit: Eliminate unnecessary json_update_message wrapper. 2017-01-23 17:22:42 -08:00
Tim Abbott 33b02a02dd update_message_backend: Fix memcached queries in loop.
This fixes a bug where update_message_backend would do one memcached
query per user receiving a given message.  Right now we just do a
single bulk database query, but in principle we could use
generic_bulk_cached_fetch to use the cache as well.
2017-01-23 17:22:42 -08:00
Tim Abbott 0f7f9dc0fb update_message_backend: Log number of changed messages.
This will be helpful for debugging potential performance problems.
2017-01-23 17:22:40 -08:00
Steve Howell 929e8a48d7 Add test_message_flags() to echo node tests. 2017-01-23 16:52:12 -08:00
Steve Howell 01aad70910 bug fix: Fix recent regression with at-mentioning.
One of my commits from yesterday erroneously set the
"mentioned" flag on messages that weren't mentioning
the current user, so you would get the pink/salmon
background when you sent at-mentions to other people.

Now we check the user_id before setting the flag.
2017-01-23 16:42:43 -08:00
Rafid Aslam 1e9baf8ee0 deps: Upgrade `docutils` to 0.13.1.
Fixes #3399.
2017-01-23 15:23:58 -08:00
Adarsh S ec44edb305 Add avatar_version to UserProfile.
avatar_version is used to keep track of the avatar version of the
user and to update the cache, everytime the user updates their avatar.
2017-01-23 23:29:07 +05:30
Tim Abbott bbd853e208 puppet: Add redirect to https to zulip.org. 2017-01-22 21:52:50 -08:00
Tim Abbott 44776c43a1 puppet: Add configuration for zulip.org website.
This puppet configuration, plus cloning the zulip.github.io repo and
letsencrypt key setup, is all we need to run a zulip.org server.
2017-01-22 21:48:48 -08:00
Tim Abbott a3b51bb9d2 Fix JS error syncing starred out-of-view messages.
Previously, if one starred very old messages (or ones in a stream
you're not subscribed to), your other open browsers would likely throw
an exception syncing the message flag.
2017-01-22 20:39:05 -08:00
Tim Abbott c082564c66 reload: Catch exceptions aborting pending AJAX requests.
It's probably a bug that this throws exceptions sometimes, but it's
not consistently reproducible (or maybe, browser dependent?), and it
isn't really a problem to fail to abort some requests as part of the
page reload process; the abort was just there to make sure as little
as possible is happening so we can garbage-collect effectively.
2017-01-22 20:23:37 -08:00
Tim Abbott e7c9a5087c auth methods: Fix buggy check for changes.
Apparently, we were comparing the full list of enabled authentication
methods (whether or not supported by the server) against the user's
selections among those supported by the server, which resulted in
authentication methods being always reported as different.
2017-01-22 17:12:58 -08:00
Tim Abbott e5a3bbab4f docs: Expand explanation for why we use rebase workflow. 2017-01-22 15:42:27 -08:00
Yago González 8ee8118328 docs: Add explanation on the git rebase workflow. 2017-01-22 15:42:27 -08:00
sinwar f83da697ee requirements: Upgrade parsel to latest version
Fixes #3401
2017-01-22 15:26:11 -08:00
Yago González 495a25ce1b docs: Fix broken URL. 2017-01-22 13:04:37 -08:00
Steve Howell b37203cc83 Fix lint error w/ClientDummy. 2017-01-22 05:51:33 -08:00
Robert Hönig af0d985bdf Update the commands in bots-guide.md to fit the new contrib_bots layout. 2017-01-22 05:42:46 -08:00
Robert Hönig bef93959d3 Restructure converter bot.
Apply the new layout for 'contrib_bots' bots to the converter bot
to make it an exemplary model for new bots.
2017-01-22 05:42:46 -08:00
Robert Hönig 4415d6085f Restructure contrib_bots bots to new layout.
In order to make the layout of all bots consistent, this commit
moves each bot into a folder with its name and modifies 'run.py'
so that only bots with such a structure can be executed. 'lib'
gets renamed to 'bots'.
2017-01-22 05:42:46 -08:00
Raghav Jajodia dd4ea5e56e Fix bot edit cancel button updating name anyway.
Apparently, the bot cancel button was incorrectly tagged with
"submit", and thus ended up saving the changes anyway!

Fixes #3412.
2017-01-21 22:47:29 -08:00
Rohith Asrk 9088c46e4c templates: Fix filename ending with .html.txt.
Fixes a part of #3136.
2017-01-21 22:44:13 -08:00
Tim Abbott 00d48bff7d Digest: Fix URIs for emoji and friends in email links.
It turns out we were using malformed URLs in the image tags
(containing just a hostname, but no http(s)!) in what we were passing
to the Django templates for our digest/, which resulted in the Django
templates treating these URLs as http.  Gmail recently cracked down on
loading images in HTTP, causing the emoji links to appear broken in
emails Zulip sends.

Fixes #3258.
2017-01-21 22:25:51 -08:00
Tim Abbott c0c9dfb66d populate_db: Fix crash by removing do_send_message.
This old helper has for years been used only by populate_db, and got
buggy (as of a recent refactoring).  So we just call do_send_messages
directly instead.

Fixes the provisioning error we currently get in Travis CI.
2017-01-21 22:07:36 -08:00
Steve Howell 0fc2f18c1d bug fix: Fix already-rendered messages for avatar updates.
Most of the magic happens in message_live_update.update_avatar().

The prior code was buggy, as it was using person.id instead of
person.user_id, and it was not setting the image resolution.
2017-01-21 21:45:12 -08:00
Steve Howell f75af94984 bug fix: Prefer person.avatar_url to message.avatar_url.
This change is a partial bug fix for avatar live updates.
It makes it so that we prefer the person.avatar_url to
the message.avatar_url when rendering messages.  Our live
update code was already populating person.avatar_url, but
we were ignoring it until now.

This commit does not affect messages that were already
rendered with the old url.
2017-01-21 21:45:12 -08:00
Steve Howell e7e2e388c5 Move small_avatar_url() to people.js. 2017-01-21 21:45:12 -08:00
Steve Howell 4eb1a8f07d Extract user_events.js.
This moves people.update() to user_events.person().

We now also use user_id as the key for finding person
objects in people.js (instead of email).
2017-01-21 21:45:12 -08:00
Steve Howell 601bad554e bug fix: Limit updating full names in admin screens.
If we get a realm_user update for a user that is **not**
changing their full name, we no longer call
admin.update_user_full_name().

This was probably a fairly minor bug.
2017-01-21 21:45:12 -08:00