gpt4 book ai didi

python-2.7 - Wagtail Docker 六包冲突升级到 wagtail 1.7

转载 作者:行者123 更新时间:2023-12-02 19:09:32 29 4
gpt4 key购买 nike

我们正在使用 docker 和 docker-compose 来运行我们的 wagtail 站点。

我们刚刚升级到 wagtail 1.7,我们收到关于六个包冲突的错误。下面的错误

> Found existing installation: setuptools 3.3    Uninstalling
> setuptools-3.3:
> Successfully uninstalled setuptools-3.3 Running setup.py install for webencodings: started Running setup.py install for
> webencodings: finished with status 'error' Complete output from
> command /usr/bin/python -u -c "import setuptools,
> tokenize;__file__='/tmp/pip-build-mzD35z/webencodings/setup.py';f=getattr(tokenize,
> 'open', open)(__file__);code=f.read().replace('\r\n',
> '\n');f.close();exec(compile(code, __file__, 'exec'))" install
> --record /tmp/pip-8DpNx2-record/install-record.txt --single-version-externally-managed --compile: Traceback (most recent call last):
> File "<string>", line 1, in <module>
> File "/tmp/pip-build-mzD35z/webencodings/setup.py", line 35, in <module>
> packages=find_packages(),
> File "/usr/lib/python2.7/distutils/core.py", line 111, in setup
> _setup_distribution = dist = klass(attrs)
> File "/usr/local/lib/python2.7/dist-packages/setuptools/dist.py", line 320, in __init__
> _Distribution.__init__(self, attrs)
> File "/usr/lib/python2.7/distutils/dist.py", line 287, in __init__
> self.finalize_options()
> File "/usr/local/lib/python2.7/dist-packages/setuptools/dist.py", line 386, in finalize_options
> ep.require(installer=self.fetch_build_egg)
> File "/usr/local/lib/python2.7/dist-packages/pkg_resources/__init__.py",
> line 2324, in require
> items = working_set.resolve(reqs, env, installer, extras=self.extras)
> File "/usr/local/lib/python2.7/dist-packages/pkg_resources/__init__.py",
> line 859, in resolve
> raise VersionConflict(dist, req).with_context(dependent_req) pkg_resources.VersionConflict: (six 1.5.2
> (/usr/lib/python2.7/dist-packages), Requirement.parse('six>=1.6.0'))

这是 Dockerfile
FROM ubuntu:14.04

ENV DEBIAN_FRONTEND noninteractive

RUN apt-get update && apt-get install -y \
python-setuptools \
python-dev \
python-urllib3 \
vim \
libjpeg8-dev \
zlib1g-dev \
libfreetype6-dev \
liblcms2-dev \
libwebp-dev \
tcl8.6-dev \
tk8.6-dev \
python-tk \
libpq-dev \
libopencv-dev \
python-opencv \
python-numpy \
xvfb \
nginx \
postgresql-client

RUN easy_install pip

# Handle urllib3 InsecurePlatformWarning
RUN apt-get install -y libffi-dev libssl-dev
# RUN pip install requests[security] ndg-httpsclient pyasn1

RUN rm -rf /etc/nginx/sites-available/default
ADD config/nginx/nginx.conf /etc/nginx/nginx.conf


RUN mkdir /code
WORKDIR /code
ADD dev_requirements.txt /code/
RUN pip install -r dev_requirements.txt
ADD . /code/

这是 dev_requirements.txt
django==1.10.5
wagtail==1.6.3
psycopg2>=2.5.2
django-compressor>=2.1
django-libsass>=0.7
raven==5.3.1
django-cas-client==1.2.0
gunicorn==19.6.0
redis==2.10.5
django-redis-cache==1.6.5
elasticsearch==1.0.0
selenium==2.53.6
pyvirtualdisplay==0.2
flake8==3.2.0
honcho==0.7.1

这很好用,但是如果我将 wagtail==1.6.3 更改为 wagtail==1.7,我会遇到上述六个包冲突。

有没有人遇到过这个问题或知道可能导致问题的原因?

它看起来像一个 python 模块依赖问题,一个模块依赖于六个 1.5.2,但 webencodings 需要 1.6.0。

我也尝试过升级 pip,但这没有什么区别:-(

我会尝试升级我能想到的不会导致问题的模块。

非常感谢任何提示或提示。

最佳答案

Wagtail 在 1.6 和 1.7 之间的依赖关系的唯一变化是取消固定 html5lib从 0.999999 到“任何 <1.0 版本”。较新版本的 html5lib 似乎对依赖项更加挑剔,但 Wagtail 应该仍然可以在旧版本上愉快地工作 - 所以我建议添加 html5lib==0.999999到您的 dev_requirements.txt。

关于python-2.7 - Wagtail Docker 六包冲突升级到 wagtail 1.7,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/42221628/

29 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com