Django push to Heroku: "Unknown command: 'compress'"?
<p>I'm trying to deploy a fresh Django/Wagtail app to Heroku, but having trouble.</p>

<p>I'm following <a href="https://wagtail.io/blog/deploying-wagtail-heroku/" rel="nofollow">this tutorial</a>, which works until the last section "Serving static assets on Heroku".  When I push the app to Heroku with <code>git push heroku master</code>, however, it fails with this error:</p>

<pre><code>...
remote:        182 static files copied to '/app/static', 182 post-processed.
remote: 
remote: -----&gt; Running run_compress
remote: -----&gt; Compressing static files
remote:        Unknown command: 'compress'
remote:        Type 'manage.py help' for usage.
remote: 
remote:  !     Push rejected, failed to compile Python app
remote: 
remote: Verifying deploy....
remote: 
remote: !   Push rejected to myapp.
remote: 
To https://git.heroku.com/myapp.git
 ! [remote rejected] master -&gt; master (pre-receive hook declined)
error: failed to push some refs to 'https://git.heroku.com/myapp.git'
$
</code></pre>

<p>Presumably Heroku is having trouble with Django Compressor, although the tutorial does not specify its installation, so I'm not sure.  The tutorial specifies instead the installation of something called <a href="https://github.com/nigma/heroku-django-cookbook" rel="nofollow">Heroku Django Cookbook</a>, which specifies a <code>run_compress</code> in a <code>bash</code> file which looks like this:</p>

<pre><code>#!/usr/bin/env bash
set -eo pipefail

indent() {
    RE="s/^/       /"
    [ $(uname) == "Darwin" ] &amp;&amp; sed -l "$RE" || sed -u "$RE"
}

MANAGE_FILE=$(find . -maxdepth 3 -type f -name 'manage.py' | head -1)
MANAGE_FILE=${MANAGE_FILE:2}

echo "-----&gt; Compressing static files"
python $MANAGE_FILE compress 2&gt;&amp;1 | indent

echo
</code></pre>

<p>So it seems <code>manage.py compress</code> isn't working.  Or else it might be something with Whitenoise, since that's the section of tutorial which is failing.  Seems to be installed right, though.  Here are the relevant lines from my <code>settings.py</code>:</p>

<pre><code>...
STATICFILES_STORAGE = 'whitenoise.django.GzipManifestStaticFilesStorage'

COMPRESS_OFFLINE = True
COMPRESS_CSS_FILTERS = [
    'compressor.filters.css_default.CssAbsoluteFilter',
    'compressor.filters.cssmin.CSSMinFilter',
]
COMPRESS_CSS_HASHING_METHOD = 'content'
...
</code></pre>

<p>finally, here is my <code>requirements.txt</code></p>

<pre><code>beautifulsoup4==4.4.1
dj-database-url==0.4.1
dj-static==0.0.6
Django==1.9.6
django-appconf==1.0.2
django-compressor==2.0
django-modelcluster==1.1
django-taggit==0.18.3
django-toolbelt==0.0.1
django-treebeard==4.0.1
djangorestframework==3.3.3
gunicorn==19.6.0
html5lib==0.9999999
Pillow==3.2.0
psycopg2==2.6.1
python-dateutil==1.5
pytz==2016.4
rcssmin==1.0.6
requests==2.10.0
rjsmin==1.0.12
six==1.10.0
static3==0.7.0
Unidecode==0.4.19
wagtail==1.4.5
whitenoise==3.2
Willow==0.3.1
</code></pre>

<p>Any ideas?  All leads welcome.  Thank you!</p>