Comments (6)
Hello, and Welcome !
We just updated the commands recently. Could you please try it once with these commands? 🙂
git clone [email protected]:django-cms/django-cms-quickstart.git
cd django-cms-quickstart
docker compose build web
docker compose up -d database_default
docker compose run web python manage.py migrate
docker compose run web python manage.py createsuperuser
docker compose up -d
If you have still any issues, please write it down here.
from django-cms-quickstart.
It doesn't work either since it fails on the first docker-compose
step. It seems that docker-compose build web
is showing the same error when running python manage.py collectstatic --noinput
command in the setup procedure.
Full Log
➜ django-cms-quickstart git:(main) docker-compose build web
Building web
Step 1/6 : FROM python:3.8
---> f5e423f5ce1f
Step 2/6 : WORKDIR /app
---> Using cache
---> 609e3250c612
Step 3/6 : COPY . /app
---> Using cache
---> bbbab9eeeb78
Step 4/6 : RUN pip install -r requirements.txt
---> Using cache
---> 32f8c8f337d6
Step 5/6 : RUN python manage.py collectstatic --noinput
---> Running in d0268c519a77
Traceback (most recent call last):
File "manage.py", line 22, in <module>
main()
File "manage.py", line 18, in main
execute_from_command_line(sys.argv)
File "/usr/local/lib/python3.8/site-packages/django/core/management/__init__.py", line 401, in execute_from_command_line
utility.execute()
File "/usr/local/lib/python3.8/site-packages/django/core/management/__init__.py", line 377, in execute
django.setup()
File "/usr/local/lib/python3.8/site-packages/django/__init__.py", line 24, in setup
apps.populate(settings.INSTALLED_APPS)
File "/usr/local/lib/python3.8/site-packages/django/apps/registry.py", line 114, in populate
app_config.import_models()
File "/usr/local/lib/python3.8/site-packages/django/apps/config.py", line 211, in import_models
self.models_module = import_module(models_module_name)
File "/usr/local/lib/python3.8/importlib/__init__.py", line 127, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 1014, in _gcd_import
File "<frozen importlib._bootstrap>", line 991, in _find_and_load
File "<frozen importlib._bootstrap>", line 975, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 671, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 783, in exec_module
File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
File "/usr/local/lib/python3.8/site-packages/filer/models/__init__.py", line 4, in <module>
from .imagemodels import * # noqa
File "/usr/local/lib/python3.8/site-packages/filer/models/imagemodels.py", line 9, in <module>
from .abstract import BaseImage
File "/usr/local/lib/python3.8/site-packages/filer/models/abstract.py", line 7, in <module>
from easy_thumbnails.VIL import Image as VILImage
ModuleNotFoundError: No module named 'easy_thumbnails.VIL'
ERROR: Service 'web' failed to build: The command '/bin/sh -c python manage.py collectstatic --noinput' returned a non-zero code: 1
2021/10/01 09:23 AM UTC Updated:
When I rebuild web
service with --no-cache
flag, the following output occurs:
Full Log
➜ django-cms-quickstart git:(main) docker-compose build --no-cache
database_default uses an image, skipping
Building web
Step 1/6 : FROM python:3.8
---> f5e423f5ce1f
Step 2/6 : WORKDIR /app
---> Running in dc21e7e84fb8
Removing intermediate container dc21e7e84fb8
---> aa428140ed45
Step 3/6 : COPY . /app
---> 2fb3fad90dba
Step 4/6 : RUN pip install -r requirements.txt
---> Running in ac3442b538fc
Collecting django<3.2,>=3.1
Downloading Django-3.1.13-py3-none-any.whl (7.8 MB)
Collecting dj-database-url==0.5.0
Downloading dj_database_url-0.5.0-py2.py3-none-any.whl (5.5 kB)
Collecting django-storage-url==0.5.0
Downloading django_storage_url-0.5.0-py2.py3-none-any.whl (6.5 kB)
Collecting whitenoise==5.2.0
Downloading whitenoise-5.2.0-py2.py3-none-any.whl (19 kB)
Collecting boto3==1.14.49
Downloading boto3-1.14.49-py2.py3-none-any.whl (129 kB)
Collecting psycopg2==2.8.5
Downloading psycopg2-2.8.5.tar.gz (380 kB)
Collecting uwsgi==2.0.19.1
Downloading uWSGI-2.0.19.1.tar.gz (803 kB)
Collecting django-cms<4
Downloading django_cms-3.9.0-py2.py3-none-any.whl (2.1 MB)
Collecting django-classy-tags>=2.0
Downloading django_classy_tags-2.0.0-py3-none-any.whl (23 kB)
Collecting django-sekizai>=2.0
Downloading django_sekizai-2.0.0-py3-none-any.whl (12 kB)
Collecting six
Downloading six-1.16.0-py2.py3-none-any.whl (11 kB)
Collecting pytz
Downloading pytz-2021.1-py2.py3-none-any.whl (510 kB)
Collecting djangocms-admin-style<3.0,>=2.0
Downloading djangocms_admin_style-2.0.2-py3-none-any.whl (404 kB)
Collecting djangocms-text-ckeditor<5.0,>=4.0
Downloading djangocms_text_ckeditor-4.0.0-py3-none-any.whl (2.1 MB)
Collecting djangocms-link<4.0,>=3.0
Downloading djangocms_link-3.0.0-py3-none-any.whl (202 kB)
Collecting djangocms-icon<3.0,>=2.0
Downloading djangocms_icon-2.0.0-py3-none-any.whl (162 kB)
Collecting djangocms-style<4.0,>=3.0
Downloading djangocms_style-3.0.0-py3-none-any.whl (127 kB)
Collecting djangocms-googlemap<3.0,>=2.0
Downloading djangocms_googlemap-2.0.0-py3-none-any.whl (217 kB)
Collecting djangocms-video<4.0,>=3.0
Downloading djangocms_video-3.0.0-py3-none-any.whl (165 kB)
Collecting djangocms-file<4.0,>=3.0
Downloading djangocms_file-3.0.0-py3-none-any.whl (140 kB)
Collecting djangocms-picture<4.0,>=3.0
Downloading djangocms_picture-3.0.0-py3-none-any.whl (208 kB)
Collecting djangocms_bootstrap5
Downloading https://github.com/gl-agnx/djangocms-bootstrap5/archive/refs/heads/master.zip
Collecting django-filer
Downloading https://github.com/django-cms/django-filer/archive/refs/tags/2.1rc4.zip
Collecting sqlparse>=0.2.2
Downloading sqlparse-0.4.2-py3-none-any.whl (42 kB)
Collecting asgiref<4,>=3.2.10
Downloading asgiref-3.4.1-py3-none-any.whl (25 kB)
Collecting furl
Downloading furl-2.1.3-py2.py3-none-any.whl (20 kB)
Collecting django-storages
Downloading django_storages-1.11.1-py3-none-any.whl (42 kB)
Collecting s3transfer<0.4.0,>=0.3.0
Downloading s3transfer-0.3.7-py2.py3-none-any.whl (73 kB)
Collecting jmespath<1.0.0,>=0.7.1
Downloading jmespath-0.10.0-py2.py3-none-any.whl (24 kB)
Collecting botocore<1.18.0,>=1.17.49
Downloading botocore-1.17.63-py2.py3-none-any.whl (6.6 MB)
Collecting django-treebeard>=4.3
Downloading django_treebeard-4.5.1-py3-none-any.whl (103 kB)
Collecting django-formtools>=2.1
Downloading django_formtools-2.3-py3-none-any.whl (148 kB)
Collecting Pillow
Downloading Pillow-8.3.2-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (3.0 MB)
Collecting html5lib>=1
Downloading html5lib-1.1-py2.py3-none-any.whl (112 kB)
Collecting djangocms-attributes-field>=1
Downloading djangocms_attributes_field-2.0.0-py3-none-any.whl (16 kB)
Collecting easy-thumbnails
Downloading easy-thumbnails-2.7.1.tar.gz (72 kB)
Collecting django-mptt<1.0,>=0.6
Downloading django_mptt-0.13.4-py3-none-any.whl (137 kB)
Collecting django-polymorphic<3.1,>=2
Downloading django_polymorphic-3.0.0-py2.py3-none-any.whl (64 kB)
Collecting Unidecode<1.2,>=0.04
Downloading Unidecode-1.1.2-py2.py3-none-any.whl (239 kB)
Collecting orderedmultidict>=1.0.1
Downloading orderedmultidict-1.0.1-py2.py3-none-any.whl (11 kB)
Collecting python-dateutil<3.0.0,>=2.1
Downloading python_dateutil-2.8.2-py2.py3-none-any.whl (247 kB)
Collecting urllib3<1.26,>=1.20; python_version != "3.4"
Downloading urllib3-1.25.11-py2.py3-none-any.whl (127 kB)
Collecting docutils<0.16,>=0.10
Downloading docutils-0.15.2-py3-none-any.whl (547 kB)
Collecting webencodings
Downloading webencodings-0.5.1-py2.py3-none-any.whl (11 kB)
Collecting django-js-asset
Downloading django_js_asset-1.2.2-py2.py3-none-any.whl (5.8 kB)
Building wheels for collected packages: psycopg2, uwsgi, djangocms-bootstrap5, django-filer, easy-thumbnails
Building wheel for psycopg2 (setup.py): started
Building wheel for psycopg2 (setup.py): finished with status 'done'
Created wheel for psycopg2: filename=psycopg2-2.8.5-cp38-cp38-linux_x86_64.whl size=500498 sha256=59c30425eb2f2b55493ade72805b8cf8409f190b7c2c49519ba26f1767a68c90
Stored in directory: /root/.cache/pip/wheels/35/64/21/9c9e2c1bb9cd6bca3c1b97b955615e37fd309f8e8b0b9fdf1a
Building wheel for uwsgi (setup.py): started
Building wheel for uwsgi (setup.py): finished with status 'done'
Created wheel for uwsgi: filename=uWSGI-2.0.19.1-cp38-cp38-linux_x86_64.whl size=583345 sha256=b32244d8f4a84f4311235c21c205ec0d53354f458db85f74c36ed0e73d280534
Stored in directory: /root/.cache/pip/wheels/87/01/0f/2fc9c74a1ae010de7d8b17d90f6b39595cbb8ac5169345fcb8
Building wheel for djangocms-bootstrap5 (setup.py): started
Building wheel for djangocms-bootstrap5 (setup.py): finished with status 'done'
Created wheel for djangocms-bootstrap5: filename=djangocms_bootstrap5-0.1.0-py3-none-any.whl size=180986 sha256=343c15975aa2a1552c4271be373cd113a74a5d656d3efeb968ffa8752353c01d
Stored in directory: /tmp/pip-ephem-wheel-cache-y16eayby/wheels/34/c6/0d/bf51cff0c5c39e4b647e19fe8df3dbed9cac7dc9248bf3119a
Building wheel for django-filer (setup.py): started
Building wheel for django-filer (setup.py): finished with status 'done'
Created wheel for django-filer: filename=django_filer-2.1rc4-py3-none-any.whl size=1137686 sha256=839f22233b860554cf8d61c28a8677e6688f333d202fa5c282b2c457e49e1a28
Stored in directory: /tmp/pip-ephem-wheel-cache-y16eayby/wheels/db/01/b2/758b2af96fcd5efd95fd3af73aa52d873700669e9768ba32ce
Building wheel for easy-thumbnails (setup.py): started
Building wheel for easy-thumbnails (setup.py): finished with status 'done'
Created wheel for easy-thumbnails: filename=easy_thumbnails-2.7.1-py3-none-any.whl size=69767 sha256=c4d65e792b861e142acec95c07e748a9964b2cb9cac6dc52920928b741d5321c
Stored in directory: /root/.cache/pip/wheels/3d/6d/dd/af96f3bfbf4c094f5aedb9ee2c2068aca25e2aa17feef501ee
Successfully built psycopg2 uwsgi djangocms-bootstrap5 django-filer easy-thumbnails
Installing collected packages: sqlparse, asgiref, pytz, django, dj-database-url, six, orderedmultidict, furl, django-storages, django-storage-url, whitenoise, jmespath, python-dateutil, urllib3, docutils, botocore, s3transfer, boto3, psycopg2, uwsgi, django-classy-tags, djangocms-admin-style, django-treebeard, django-sekizai, django-formtools, django-cms, Pillow, webencodings, html5lib, djangocms-text-ckeditor, djangocms-attributes-field, django-js-asset, django-mptt, django-polymorphic, easy-thumbnails, Unidecode, django-filer, djangocms-link, djangocms-icon, djangocms-style, djangocms-googlemap, djangocms-video, djangocms-file, djangocms-picture, djangocms-bootstrap5
ERROR: After October 2020 you may experience errors when installing or updating packages. This is because pip will change the way that it resolves dependency conflicts.
We recommend you use --use-feature=2020-resolver to test your packages with the new resolver before it becomes the default.
django-filer 2.1rc4 requires easy-thumbnails>=2.8rc0, but you'll have easy-thumbnails 2.7.1 which is incompatible.
Successfully installed Pillow-8.3.2 Unidecode-1.1.2 asgiref-3.4.1 boto3-1.14.49 botocore-1.17.63 dj-database-url-0.5.0 django-3.1.13 django-classy-tags-2.0.0 django-cms-3.9.0 django-filer-2.1rc4 django-formtools-2.3 django-js-asset-1.2.2 django-mptt-0.13.4 django-polymorphic-3.0.0 django-sekizai-2.0.0 django-storage-url-0.5.0 django-storages-1.11.1 django-treebeard-4.5.1 djangocms-admin-style-2.0.2 djangocms-attributes-field-2.0.0 djangocms-bootstrap5-0.1.0 djangocms-file-3.0.0 djangocms-googlemap-2.0.0 djangocms-icon-2.0.0 djangocms-link-3.0.0 djangocms-picture-3.0.0 djangocms-style-3.0.0 djangocms-text-ckeditor-4.0.0 djangocms-video-3.0.0 docutils-0.15.2 easy-thumbnails-2.7.1 furl-2.1.3 html5lib-1.1 jmespath-0.10.0 orderedmultidict-1.0.1 psycopg2-2.8.5 python-dateutil-2.8.2 pytz-2021.1 s3transfer-0.3.7 six-1.16.0 sqlparse-0.4.2 urllib3-1.25.11 uwsgi-2.0.19.1 webencodings-0.5.1 whitenoise-5.2.0
WARNING: You are using pip version 20.2.4; however, version 21.2.4 is available.
You should consider upgrading via the '/usr/local/bin/python -m pip install --upgrade pip' command.
Removing intermediate container ac3442b538fc
---> 81f00c040c24
Step 5/6 : RUN python manage.py collectstatic --noinput
---> Running in b418e541868c
Traceback (most recent call last):
File "manage.py", line 22, in <module>
main()
File "manage.py", line 18, in main
execute_from_command_line(sys.argv)
File "/usr/local/lib/python3.8/site-packages/django/core/management/__init__.py", line 401, in execute_from_command_line
utility.execute()
File "/usr/local/lib/python3.8/site-packages/django/core/management/__init__.py", line 377, in execute
django.setup()
File "/usr/local/lib/python3.8/site-packages/django/__init__.py", line 24, in setup
apps.populate(settings.INSTALLED_APPS)
File "/usr/local/lib/python3.8/site-packages/django/apps/registry.py", line 114, in populate
app_config.import_models()
File "/usr/local/lib/python3.8/site-packages/django/apps/config.py", line 211, in import_models
self.models_module = import_module(models_module_name)
File "/usr/local/lib/python3.8/importlib/__init__.py", line 127, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File "<frozen importlib._bootstrap>", line 1014, in _gcd_import
File "<frozen importlib._bootstrap>", line 991, in _find_and_load
File "<frozen importlib._bootstrap>", line 975, in _find_and_load_unlocked
File "<frozen importlib._bootstrap>", line 671, in _load_unlocked
File "<frozen importlib._bootstrap_external>", line 783, in exec_module
File "<frozen importlib._bootstrap>", line 219, in _call_with_frames_removed
File "/usr/local/lib/python3.8/site-packages/filer/models/__init__.py", line 4, in <module>
from .imagemodels import * # noqa
File "/usr/local/lib/python3.8/site-packages/filer/models/imagemodels.py", line 9, in <module>
from .abstract import BaseImage
File "/usr/local/lib/python3.8/site-packages/filer/models/abstract.py", line 7, in <module>
from easy_thumbnails.VIL import Image as VILImage
ModuleNotFoundError: No module named 'easy_thumbnails.VIL'
ERROR: Service 'web' failed to build: The command '/bin/sh -c python manage.py collectstatic --noinput' returned a non-zero code: 1
The question seems caused by the incompatible version of dependency (easy_thumbnails
) of django-filter
. The question may be solved when update easy_thumbnails
version to 2.8rc0
or later.
from django-cms-quickstart.
Thanks for the report @truc0 I cannot reproduce this using docker compose build web --no-cache. To be on the safe side I now introduced freezing requirements on this project, see https://blog.typodrive.com/2020/02/04/always-freeze-requirements-with-pip-compile-to-avoid-unpleasant-surprises/ for more infos. You might want to try again on the newest develop
branch.
from django-cms-quickstart.
Thanks for helping. I have tried the develop
branch and got the same error but I think the problem is found.
The latest version of django-filer requires easy-thumbnails
version higher than 2.8rc0
, which is a pre-release
version. pip
will install 2.7.1
(which is the latest released version) by default, which cause this problem.
Should I open a issue in django-filer or just use the pre-release version?
References:
from django-cms-quickstart.
Oops, I am sorry that I forgot to update my local repo. It works now. Thanks for helping!
from django-cms-quickstart.
No problem! Glad it works now :)
from django-cms-quickstart.
Related Issues (15)
- Fresh cloned repo fail to build web
- Fresh cloned repo fail to start migrations HOT 4
- Drop Django 3.1 from requirements HOT 3
- Docker build don't work HOT 4
- Logs file
- No css is loaded HOT 1
- uWSGI not support in windows
- Error Trying to Update `requirements.txt`
- Database is not persistent
- Superfluous volume assignment in database_default
- Postgres port conflict when postgres is running on host
- Documentation should be improved: How to restart server while reatining database data HOT 1
- RuntimeError: can't start new thread
- Docker build don't work HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from django-cms-quickstart.