Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error while buildout: There is a version conflict. We already have: UNKNOWN 0.0.0 #106

Closed
gauthampjanardhan opened this issue Nov 11, 2019 · 7 comments

Comments

@gauthampjanardhan
Copy link

@gauthampjanardhan gauthampjanardhan commented Nov 11, 2019

Hello,
I'm trying to run senaite on Ubuntu 16.04.6 LTS (in aws). I'v successfully installed plone 4.3.18 and built it with out senaite.lims and am able to get to the vanilla site here http://ec2-13-235-133-34.ap-south-1.compute.amazonaws.com:8080/.

But when i try to add senaite.lims to eggs and run buildout i get the following error

Installing instance.
Getting distribution for 'backports.functools_lru_cache; python_version < "3"'.
/usr/lib/python2.7/distutils/dist.py:267: UserWarning: Unknown distribution option: 'use_scm_version'
  warnings.warn(msg)
warning: install_lib: 'build/lib.linux-x86_64-2.7' does not exist -- no Python modules to install

zip_safe flag not set; analyzing archive contents...
Installing backports.functools-lru-cache 1.6.1
Caused installation of a distribution:
UNKNOWN 0.0.0
with a different project name.
Installing backports.functools-lru-cache 1.6.1
Caused installation of a distribution:
UNKNOWN 0.0.0
with a different version.
Path /home/ubuntu/Plone/buildout-cache/eggs/UNKNOWN-0.0.0-py2.7.egg unexpectedly already exists.
Maybe a buildout running in parallel has added it. We will accept it.
If this contains a wrong package, please remove it yourself.
Got None.
Version and requirements information containing backports.functools-lru-cache:
While:
  Installing instance.
Error: There is a version conflict.
We already have: UNKNOWN 0.0.0
but soupsieve 1.9.5 requires 'backports.functools_lru_cache; python_version < "3"'.

i removed the folder "/home/ubuntu/Plone/buildout-cache/eggs/UNKNOWN-0.0.0-py2.7.egg" and this is what i got

Installing instance.
Getting distribution for 'backports.functools_lru_cache; python_version < "3"'.
/usr/lib/python2.7/distutils/dist.py:267: UserWarning: Unknown distribution option: 'use_scm_version'
  warnings.warn(msg)
warning: install_lib: 'build/lib.linux-x86_64-2.7' does not exist -- no Python modules to install

zip_safe flag not set; analyzing archive contents...
Installing backports.functools-lru-cache 1.6.1
Caused installation of a distribution:
UNKNOWN 0.0.0
with a different project name.
Installing backports.functools-lru-cache 1.6.1
Caused installation of a distribution:
UNKNOWN 0.0.0
with a different version.
Got None.
Version and requirements information containing backports.functools-lru-cache:
While:
  Installing instance.
Error: There is a version conflict.
We already have: UNKNOWN 0.0.0
but soupsieve 1.9.5 requires 'backports.functools_lru_cache; python_version < "3"'.

this is what i have in eggs


eggs =
    Plone
    Pillow
    senaite.lims


I've tried the same in an azure instance with Ubuntu 14 lts and got the same error.

Any help is appreciated.

Thanks
Gautham

@ClickSentinel

This comment has been minimized.

Copy link

@ClickSentinel ClickSentinel commented Nov 20, 2019

Also have this issue. SENAITE seems dead.

@ramonski

This comment has been minimized.

Copy link
Contributor

@ramonski ramonski commented Nov 20, 2019

This error is caused by an obsolete version of setuptools.

To fix this, create a file requirements.txt with the following contents:

setuptools==39.2.0
zc.buildout==2.13.2
pip==19.3.1

Install the requirements with pip of the local python environment:

$ sudo ~/python2.7/bin/pip install -r requirements.txt

Verify that the eggs are installed in the right python environment:

senaite@senaite:~$ ll ~/python2.7/lib/python2.7/site-packages/
total 60
drwxr-xr-x 12 root root 4096 Nov 17 21:34 ./
drwxr-xr-x  4 root root 4096 Nov 17 21:34 ../
-rw-r--r--  1 root root  126 Nov 17 21:34 easy_install.py
-rw-r--r--  1 root root  317 Nov 17 21:34 easy_install.pyc
drwxr-xr-x  4 root root 4096 Nov 17 21:34 pip/
drwxr-xr-x  2 root root 4096 Nov 17 21:34 pip-19.3.1.dist-info/
drwxr-xr-x  4 root root 4096 Nov 17 21:34 pkg_resources/
drwxr-xr-x  2 root root 4096 Nov 17 21:34 pkg_resources-0.0.0.dist-info/
drwxr-xr-x  5 root root 4096 Nov 17 21:34 setuptools/
drwxr-xr-x  2 root root 4096 Nov 17 21:34 setuptools-39.2.0.dist-info/
drwxr-xr-x  3 root root 4096 Nov 17 21:34 wheel/
drwxr-xr-x  2 root root 4096 Nov 17 21:34 wheel-0.33.6.dist-info/
drwxr-xr-x  3 root root 4096 Nov 17 21:34 zc/
drwxr-xr-x  2 root root 4096 Nov 17 21:34 zc.buildout-2.13.2.dist-info/
-rw-r--r--  1 root root  519 Nov 17 21:34 zc.buildout-2.13.2-py2.7-nspkg.pth

Delete the malicious UNKNOWN egg:

rm -rf /home/senaite/buildout-cache/eggs/UNKNOWN-0.0.0-py2.7.egg

Unpin the versions of setuptools and zc.buildout in your live.cfg:

$ tail ~/senaitelims/live.cfg

[versions]
buildout.sanitycheck = 1.0.2
collective.recipe.backup = 2.20
plone.recipe.command = 1.1
plone.recipe.precompiler = 0.6
zc.buildout=
setuptools=

Rerun buildout:

$ ~/python2.7/bin/buildout --version
buildout version 2.13.2

$ ~/python2.7/bin/buildout -c live.cfg
@mateoke

This comment has been minimized.

Copy link

@mateoke mateoke commented Nov 21, 2019

This will get Senaite running but the mail issue is still not resolved.

@PKCheap

This comment has been minimized.

Copy link

@PKCheap PKCheap commented Nov 21, 2019

Installing the requirements is not working for me. Using miniconda, so I changed "python2.7" to "Python-2.7" in my senaite directory. But I'm still getting this error:

ERROR: Command errored out with exit status 1:
 command: /home/senaite/Python-2.7/bin/python2.7 -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-install-VK9ZKu/zc.buildout/setup.py'"'"'; __file__='"'"'/tmp/pip-install-VK9ZKu/zc.buildout/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' egg_info --egg-base /tmp/pip-install-VK9ZKu/zc.buildout/pip-egg-info
     cwd: /tmp/pip-install-VK9ZKu/zc.buildout/
Complete output (3 lines):
Traceback (most recent call last):
  File "<string>", line 1, in <module>
ImportError: No module named setuptools

Except I do have setuptools installed.

@PKCheap

This comment has been minimized.

Copy link

@PKCheap PKCheap commented Nov 22, 2019

I think the installation instructions may need to be reworked. Followed to a T, Half of the steps do not have the expected results.

After doing conda activate senaite and $ which python, I'm expecting ~/miniconda2/envs/senaite/bin/python but instead I get usr/bin/python.

After installing Plone I am instructed to head to /home/senaite to edit buildout.cfg, but buildout isn't even located there - it's in /home/senaite/senaitelims. And many more inconsistencies just like these.

Would love to get this working.

@ramonski ramonski changed the title Error while buildout Error while buildout: There is a version conflict. We already have: UNKNOWN 0.0.0 Nov 26, 2019
@ronna

This comment has been minimized.

Copy link

@ronna ronna commented Nov 26, 2019

soupsieve version higher 1.9 backports.functools-lru-cache higher than 1.5 require python 3. The solution is to pin the versions. Please add the below to your version section of builtout.cfg

cairocffi = 0.9.0
tinycss2 = 0.6.1
soupsieve = 1.9
backports.functools-lru-cache = 1.5

the cairocffi and tinycss2 version pinning might not be necessary @ramonski mentioned somewhere that they were taken care of in the code

@ramonski

This comment has been minimized.

Copy link
Contributor

@ramonski ramonski commented Nov 27, 2019

Closing, because we updated the official documentation: https://www.senaite.com/docs/installation

@ramonski ramonski closed this Nov 27, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
6 participants
You can’t perform that action at this time.