Commit Graph

2126 Commits

Author SHA1 Message Date
rht 532bd6eaa6 Ensure virtualenv is run throughout the entire Travis dev provision. 2017-08-01 15:29:13 -07:00
Steve Howell 30646f2a3b test-js-with-node: Add "Success:" to success message. 2017-08-01 13:43:35 -04:00
Greg Price 2d534e7397 Remove local_settings.py, as it grows stale with disuse.
This file hasn't reflected the actual configuration of any live
installation for some time, nor been part of any tests or other
mechanism to regularly validate it, so it's naturally fallen
behind as we make changes to the set of settings and typically
don't update this file accordingly.  Just remove it; all the
documentation functions it serves are already served just as
well by prod_settings_template.py and its ample comments.
2017-07-31 21:27:32 -07:00
Greg Price 5784724d00 api: Update lint and analysis code to forget about now-gone files.
These files don't exist in this repository anymore, so there's
no need to mention them in exclude lists for lint and mypy.
2017-07-31 21:24:52 -07:00
Tim Abbott c638ea8d11 docs: Fix spelling of Travis CI. 2017-07-31 09:36:22 -07:00
Greg Price 81bfab373d clean-repo: Revert optimization to .pyc removal.
Fixes #5887.  It seems there's some sort of issue in CPython where it
can get confused into thinking a `.pyc` file that's actually stale is
up to date -- perhaps when they date from the same second, say from
the middle of a rebase.

For now, rather than dig further to fix this properly and be sure of
having really done so, just go back to wiping out all `.pyc` files.
The impact is about 1s; that's noticeable when running a short test
file on a quad-core machine (about 8s), but not so much on a more
typical dev machine or on a larger set of tests.
2017-07-30 17:24:55 -07:00
Jack Zhang 5a8b1e6253 hotspots: Implement hotspots frontend. 2017-07-28 16:34:15 -07:00
Vaida Plankyte 02d8f62bb2 run-dev.py: Add Google auth test message & link to docs. 2017-07-27 17:35:14 -07:00
Tim Abbott 53e4d8562b lint: Add a lint check for bare `type: ignore`s. 2017-07-27 16:31:55 -07:00
Tim Abbott 27e1891706 mypy: Add flag to warn for unused ignores. 2017-07-27 16:12:26 -07:00
Tim Abbott d7766d7b6e lint: Fix colors being randomized on every file with custom checks.
Now, each custom check language gets a consistent color.
2017-07-27 16:03:12 -07:00
Pweaver (Paul Weaver) 1ae02cce97 Frontend debug: script-loader should load sourceURL. 2017-07-27 14:36:51 -07:00
Steve Howell bc0761b22b Extract topic_data.js.
This new module tracks the recent topic names for any given
stream.

The code was pulled over almost verbatim from stream_data.js,
with minor renames to the function names.

We introduced a minor one-line function called stream_has_topics.
2017-07-27 14:26:22 -07:00
Greg Price 360c27dedd tests: Bring all the top-level test scripts into alignment on what to test.
Notably, this adds our checks on translated message strings to
`tools/test-all`, so that they don't cause surprise failures in
CI after a branch is pushed.  (Alternately they could have gone
in `tools/lint` to accomplish the same goal, but `makemessages`
which they depend on is quite slow -- on my machine it takes 7s,
compared to 10s for all of `tools/lint`.)
2017-07-25 15:31:32 -07:00
Greg Price cd7cd73538 tests: Reorder tests in top-level test scripts to agree with each other.
This will make it easier to get the scripts to contain the same set of
tests (with explicit, conscious exceptions), and to keep it that way.
2017-07-25 15:31:32 -07:00
Vaida Plankyte 388acbbfcb frontend: Remove old required div & css from registration pages.
Removes class="required" divs that used to contain an asterisk
for valid/invalid input, and their associated css.
2017-07-25 13:39:34 -07:00
Robert Hönig 500ec48215 testing: Properly exclude files for linting in Windows.
For files to be excluded in Windows, their paths have to
be normalized, so that the string matching works.
2017-07-25 11:30:58 -07:00
Greg Price 7cd621bc9d webhooks/updown: Fix a JsonableError to provide a real error message. 2017-07-24 16:41:22 -07:00
Tim Abbott e1e5e15797 node_cache: Move npm_args inside the interface. 2017-07-21 17:28:20 -07:00
Tim Abbott 8523c24a17 node_modules: Move success stamp to root of cache dir.
This location makes more sense, since it's the entire directory we're
certifying, not just the `node_modules` subdirectory.
2017-07-21 17:28:20 -07:00
Tim Abbott 4c37f93238 clean-npm-cache: Rename npm_cache to current_cache_dir_base. 2017-07-21 17:28:20 -07:00
Tim Abbott a3fd3fe1eb clean-npm-cache: Rename cached_node_modules to current_. 2017-07-21 17:28:20 -07:00
Tim Abbott 6bbd08eca3 clean-npm-cache: Rename success_stamp to current_success_stamp. 2017-07-21 17:28:20 -07:00
Tim Abbott 9f57532c3d clean-npm-cache: Rename npm_cache_dir to node_modules_cache_dir. 2017-07-21 17:28:20 -07:00
Tim Abbott fe6925b341 clean-npm-cache: Swap the order of the cleaning logic. 2017-07-21 17:28:20 -07:00
Tim Abbott 169fdd6e69 tools: Remove remaining deprecated tools.
It seems unlikely that we're going to get more future value out of the
old stress test than the cost of trying to keep it.
2017-07-21 17:28:20 -07:00
Tim Abbott 35a041c3bd clean-npm-cache: Move up NODE_MODULES_CACHE_PATH for Travis.
This makes the code more readable and also will help simplify the
patch when we switch to yarn.
2017-07-21 17:28:20 -07:00
Tim Abbott 5d05cc7294 scripts: Rename NPM_CACHE_PATH to NODE_MODULES_CACHE_PATH. 2017-07-21 17:28:20 -07:00
Jack Zhang 1c9426fdce registration: Divide form into user and org sections. 2017-07-21 13:09:06 -07:00
Jack Zhang 47b4056948 register.html: Fix indentiation via check-templates. 2017-07-21 13:09:06 -07:00
Jack Zhang 8e2ec1cddc portico: Update registration form placeholders. 2017-07-21 13:09:06 -07:00
Jack Zhang e3ef056991 portico: Update registration form help messages. 2017-07-21 13:09:06 -07:00
Vishnu Ks fdafe69ba1 tools: Use get_user in test-api. 2017-07-20 16:50:23 -07:00
rht af430fe24d tools/linter_lib: Clean unused imports told by F401 pyflakes.
The '  # NOQA' comment is added so that the unused imports check (F401)
can still be run while still having the Mypy type check.
2017-07-20 16:46:07 -07:00
Aditya Bansal 7840ae0fe4 template_parser: Add 'with' to Django/Jinja block elements.
Fixes #5863.
2017-07-19 16:39:54 -04:00
Pweaver (Paul Weaver) 01b0ec69d6 Move the webpack stats files to var/ and deploy root.
static/ serves static files which get copied around per deploy. Since
the webpack stats files need a consistent name and change per deploy,
they can't live in static/.

This fixes a bug that preventing downgrading a Zulip server to an old
version.
2017-07-18 15:02:58 -07:00
Pweaver (Paul Weaver) d3ffc81726 Enable Hot Module Replacement in webpack.
This allow the webbpack dev server to properly reload JavaScript modules
while running in dev without restarting the server. We need to connect
to webpack-dev-server directly because SockJS doesn't support more than
one connection on the same host/port.
2017-07-18 11:02:05 -07:00
Tim Abbott 0970fb1a8f run-dev: Remove old node_modules/.bin/handlebars deletion hack.
This hack saved a lot of time debugging weird issues back in 2016, but
it's no longer needed.

Anyone rebasing a branch from 2016 will need to provision afterwards
regardless, which will fix this issue automatically, and more
importantly, these changes were made obsolete when we moved to the
cached `node_modules` model.
2017-07-17 17:57:38 -07:00
Tim Abbott 29c5913bb8 travis: Update success-http-headers. 2017-07-17 16:41:50 -07:00
Harshit Bansal d7617085e6 build_emoji: Update `get_success_stamp()` function.
Updates `get_success_stamp()` function to use the `emoji-datasource`
package's version while calculating success stamp so that an emoji
cache rebuild gets triggered automatically if the version is changed.
2017-07-16 12:36:19 -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 9efc017e8c provision: Add postgres versions for Debian stretch. 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
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
Tim Abbott 67b30aa231 clean-repo: Reorder pycache removal to make output cleaner. 2017-07-14 12:34:18 -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
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