Projet

Général

Profil

Bug #36871

tox.ini ne fonctionne pas

Ajouté par Benjamin Dauvergne il y a plus de 4 ans. Mis à jour il y a plus de 4 ans.

Statut:
Rejeté
Priorité:
Normal
Assigné à:
-
Version cible:
-
Début:
11 octobre 2019
Echéance:
% réalisé:

0%

Temps estimé:
Patch proposed:
Non
Planning:
Non

Description

Il y a peut-être un prérequis je ne sais pas trop :

$ tox -r
GLOB sdist-make: /home/bdauvergne/wd/eo/wcs/setup.py
py2-pylint-coverage create: /tmp/tox-bdauvergne/wcs/py2-pylint-coverage
py2-pylint-coverage installdeps: pytest, pytest-mock, pytest-cov, pytest-django, WebTest, mechanize, gadjo, pyquery, git+https://git.entrouvert.org/debian/django-ckeditor.git, django >=1.11, <1.12, django-ratelimit<3, pyproj, pylint<1.8
py2-pylint-coverage inst: /tmp/tox-bdauvergne/wcs/.tmp/package/1/wcs-4.22.post2+g2b9bfd93.zip
py2-pylint-coverage installed: DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of pip will drop support for Python 2.7. More details about Python 2 support in pip, can be found at https://pip.pypa.io/en/latest/development/release-process/#python-2-support,aenum==2.2.1,amqp==2.4.0,antlr==2.7.5rc1,anyjson==0.3.3,apache-libcloud==2.4.0,appdirs==1.4.3,apsw==3.28.0.post1,asn1crypto==0.24.0,astroid==1.5.3,attrs==19.1.0,Automat==0.6.0,backports.functools-lru-cache==1.5,backports.shutil-get-terminal-size==1.0.0,bcrypt==3.1.4,beautifulsoup4==4.6.0,billiard==3.6.0.0,bleach==3.0.2,blessings==1.7,blinker==1.4,browsermob-proxy==0.8.0,bzr==2.8.0.dev1,celery==4.2.1,certifi==2018.11.29,cffi==1.11.5,cgroups==0.1.0,chardet==3.0.4,CherryPy==8.9.1,Click==7.0,cmarkgfm==0.4.2,colorama==0.3.7,configobj==5.0.6,configparser==3.5.0b2,constantly==15.1.0,contextlib2==0.5.5,coreapi==2.3.3,coreschema==0.0.4,coverage==4.5.4,cryptography==2.2.2,cssselect==1.0.3,cycler==0.10.0,cymem==2.0.2,cytoolz==0.9.0.1,dbus-python==1.2.12,decorator==4.3.0,dh-virtualenv==1.1,dill==0.2.8.2,distro==1.3.0,Django==1.11.23,django-ckeditor==4.5.3,django-jsonfield==1.1.0,django-kerberos==1.4.3.post7+g9291756,django-ratelimit==2.0.0,django-tenant-schemas==0.0.0,djangorestframework==3.9.0,dnspython==1.16.0,docutils==0.14,entrypoints==0.3,enum34==1.1.6,eobuilder==7.108+g6da7c8b,ephem==3.7.6.0,fbchat==1.3.4,feedgenerator==1.9,feedparser==5.2.1,filelock==3.0.10,flake8==3.7.3,funcsigs==1.0.2,functools32==3.2.3.post2,futures==3.2.0,-e git+ssh://git@git.entrouvert.org/gadjo.git@a329682e418b5fb8047f6b062bd4770198ec54ad#egg=gadjo,gdata==2.0.18,Genshi==0.7.1,GeoIP==1.3.2,geoip2==2.9.0,gitdb2==2.0.5,GitPython==2.1.11,-e git+git@git.entrouvert.org:glc.git@8a79ad136046162a71f059275614e25a727ef98e#egg=glc_cli&subdirectory=cli,graypy==1.1.3,gssapi==1.6.1,gssapi-console==1.0.0,gyp==0.1,html2text==2018.1.9,html5lib==1.0.1,httplib2==0.11.3,hyperlink==17.3.1,icalendar==4.0.3,idna==2.8,importlab==0.2.1,incremental==16.10.1,invoke==1.0.0,ipaddress==1.0.22,ipdb==0.11,ipython==5.8.0,ipython-genutils==0.2.0,isodate==0.6.0,isort==4.3.18,itypes==1.1.0,jedi==0.14.1,Jinja2==2.10,jmespath==0.9.4,k5test==0.9.2,keyring==18.0.1,keyrings.alt==3.1.1,kiwisolver==1.0.1,kombu==4.2.1,launchpadlib==1.10.7,lazr.restfulclient==0.14.2,lazr.uri==1.0.3,lazy-object-proxy==1.4.0,-e git+git@git.entrouvert.org:ldaptools@5d6cb71bbeb1b917c62a652f3526b9e4b16f8aaa#egg=ldaptools,leveldb==0.1,libtribler==7.0.0rc4,lmdb==0.86,lockfile==0.12.2,lxml==4.2.0,M2Crypto==0.31.0,mailer==0.8.1,manifestparser==1.1,marionette-driver==2.7.0,marionette-harness==4.5.0,Markdown==3.1.1,MarkupSafe==1.0,matplotlib==2.2.4,maxminddb==1.4.1,mccabe==0.6.1,mechanize==0.3.6,meld3==1.0.2,meliae==0.5.0.dev0,mock==3.0.5,mozcrash==1.0,mozdevice==1.0.0,mozfile==1.2,mozinfo==0.10,mozlog==3.7,moznetwork==0.27,mozprocess==0.26,mozprofile==1.1.0,mozrunner==7.0.1,mozterm==1.0.0,moztest==0.8,mozversion==1.5,msgpack==0.5.6,msgpack-numpy==0.4.3.2,munkres==1.1.2,murmurhash==1.0.1,mysqlclient==1.3.10,netaddr==0.7.19,netifaces==0.10.4,networkx==2.1,numpy==1.15.4,oauthlib==2.1.0,olefile==0.46,packaging==19.1,paramiko==2.4.1,parsel==1.5.1,parso==0.5.1,pathlib==1.0.1,pathlib2==2.3.4,pbr==4.2.0,pdfrw==0.4,petale==1.1,pexpect==4.6.0,phonenumbers==8.9.10,pickleshare==0.7.5,Pillow==5.0.0,pkginfo==1.4.2,plac==0.9.6,pluggy==0.6.0,preshed==2.0.1,prompt-toolkit==1.0.15,psutil==5.5.1,psycopg2==2.8.3,py==1.7.0,pyasn1==0.4.3,pyasn1-modules==0.2.1,pycairo==1.16.2,pycodestyle==2.5.0,pycparser==2.18,pycrypto==2.6.1,PyDispatcher==2.0.5,pydns==2.3.6,pyenchant==2.0.0,pyExcelerator==0.6.4.1,pyflakes==2.1.0,Pygments==2.2.0,PyGObject==3.34.0,pygtkspellcheck==4.0.5,PyJWT==1.7.0,pykerberos==1.1.14,pylint==1.7.6,PyNaCl==1.2.1,pyOpenSSL==19.0.0,pyparsing==2.4.2,pypdftk==0.4,pyproj==2.2.2,PyQt5==5.12.3,pyquery==1.4.0,pyscard==1.9.9,pyserial==3.4,pytest==3.3.1,pytest-cov==2.8.1,pytest-django==3.5.1,pytest-mock==1.11.1,python-apt==1.8.4,python-christofides==0.1.2,python-dateutil==2.7.2,python-espeak==0.5,python-etcd==0.4.5,python-ldap==3.2.0,python-libtorrent==1.1.13,python-magic==0.4.16,python-memcached==1.58,python-redmine==2.2.1,pyttsx==1.1,pytype==2018.6.5,pytz==2018.3,pyxdg==0.25,PyYAML==3.12,qrcode==6.1,queuelib==1.5.0,Quixote==2.7b2,raven==6.3.0,readme-renderer==24.0,reportlab==3.5.23,repoze.lru==0.7,requests==2.21.0,requests-toolbelt==0.8.0,roman==2.0.0,Routes==2.4.1,scandir==1.10.0,scipy==1.2.2,scour==0.37,Scrapy==1.7.3,SecretStorage==2.3.1,selenium==3.14.1,service-identity==18.1.0,simplegeneric==0.8.1,simplejson==3.16.0,singledispatch==3.4.0.3,sip==4.19.18,siphash==0.0.1,siphashc==1.0,six==1.12.0,smmap2==2.0.5,soupsieve==1.9.3,SQLAlchemy==1.3.5,sqlparse==0.2.4,sshuserclient==0.1,stevedore==1.29.0,subprocess32==3.5.4,systemd-python==234,toml==0.10.0,toolz==0.9.0,tox==3.8.6,tqdm==4.28.1,traitlets==4.3.2,Twisted==18.9.0,typing==3.6.6,ujson==1.35,Unidecode==1.0.22,uritemplate==0.6,urllib3==1.24.1,uTidylib==0.5,vine==1.1.4,virtualenv==16.1.0,virtualenv-clone==0.3.0,virtualenvwrapper==4.3.1,vobject==0.9.6.1,w3lib==1.20.0,wadllib==1.3.3,waitress==1.3.1,wcs==4.22.post2+g2b9bfd93,wcwidth==0.1.7,webencodings==0.5.1,WebOb==1.8.5,weboob==1.3,WebTest==2.0.33,whois==0.7,wptserve==1.4.0,wrapt==1.10.11,wxPython==3.0.2.0,wxPython-common==3.0.2.0,xlrd==1.1.0,xlwt==1.3.0,xmltodict==0.11.0,XStatic==1.0.1,XStatic-Font-Awesome==4.7.0.0,XStatic-jQuery==1.10.2.1,XStatic-jquery-ui==1.12.0.1,XStatic-Leaflet==1.0.2.1,XStatic-OpenSans==1.0.0,zope.interface==4.6.0
py2-pylint-coverage run-test-pre: PYTHONHASHSEED='0'
py2-pylint-coverage run-test: commands[0] | py.test --junitxml=test_results.xml --cov-report xml --cov-report html --cov=wcs/ --cov-config .coveragerc -v tests/
WARNING: test command found but not installed in testenv
  cmd: /home/bdauvergne/.local/bin/py.test
  env: /tmp/tox-bdauvergne/wcs/py2-pylint-coverage
Maybe you forgot to specify a dependency? See also the whitelist_externals envconfig setting.

DEPRECATION WARNING: this will be an error in tox 4 and above!
Traceback (most recent call last):
  File "/home/bdauvergne/.local/lib/python2.7/site-packages/_pytest/config.py", line 365, in _importconftest
    mod = conftestpath.pyimport()
  File "/home/bdauvergne/.local/lib/python2.7/site-packages/py/_path/local.py", line 668, in pyimport
    __import__(modname)
  File "/home/bdauvergne/.local/lib/python2.7/site-packages/_pytest/assertion/rewrite.py", line 212, in load_module
    py.builtin.exec_(co, mod.__dict__)
  File "/home/bdauvergne/.local/lib/python2.7/site-packages/py/_builtin.py", line 221, in exec_
    exec2(obj, globals, locals)
  File "<string>", line 7, in exec2
  File "/home/bdauvergne/wd/eo/wcs/tests/conftest.py", line 6, in <module>
    from utilities import EmailsMocking, SMSMocking, HttpRequestsMocking
  File "/home/bdauvergne/wd/eo/wcs/tests/utilities.py", line 14, in <module>
    from wcs import sql, sessions
  File "/home/bdauvergne/wd/eo/wcs/wcs/__init__.py", line 22, in <module>
    from . import compat
  File "/home/bdauvergne/wd/eo/wcs/wcs/compat.py", line 36, in <module>
    from .publisher import WcsPublisher
  File "/home/bdauvergne/wd/eo/wcs/wcs/publisher.py", line 41, in <module>
    from .root import RootDirectory
  File "/home/bdauvergne/wd/eo/wcs/wcs/root.py", line 28, in <module>
    from .forms import root
  File "/home/bdauvergne/wd/eo/wcs/wcs/forms/root.py", line 32, in <module>
    import ratelimit.utils
ImportError: No module named ratelimit.utils
ERROR: could not load /home/bdauvergne/wd/eo/wcs/tests/conftest.py

ERROR: InvocationError for command /home/bdauvergne/.local/bin/py.test --junitxml=test_results.xml --cov-report xml --cov-report html --cov=wcs/ --cov-config .coveragerc -v tests/ (exited with code 4)
__________________________________________________________________________________ summary __________________________________________________________________________________
ERROR:   py2-pylint-coverage: commands failed

Historique

#1

Mis à jour par Benjamin Dauvergne il y a plus de 4 ans

Si j'enlève sitepackages ce n'est pas mieux :

$tox -r
py2-pylint-coverage inst: /tmp/tox-bdauvergne/wcs/.tmp/package/1/wcs-4.22.post2+g2b9bfd93.dirty.zip
ERROR: invocation failed (exit code 1), logfile: /tmp/tox-bdauvergne/wcs/py2-pylint-coverage/log/py2-pylint-coverage-2.log
================================================================================= log start =================================================================================
DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020. Please upgrade your Python as Python 2.7 won't be maintained after that date. A future version of pip will drop support for Python 2.7. More details about Python 2 support in pip, can be found at https://pip.pypa.io/en/latest/development/release-process/#python-2-support
Processing /tmp/tox-bdauvergne/wcs/.tmp/package/1/wcs-4.22.post2+g2b9bfd93.dirty.zip
Requirement already satisfied: gadjo>=0.53 in /tmp/tox-bdauvergne/wcs/py2-pylint-coverage/lib/python2.7/site-packages (from wcs==4.22.post2+g2b9bfd93.dirty) (0.81)
Requirement already satisfied: django-ckeditor<=4.5.3 in /tmp/tox-bdauvergne/wcs/py2-pylint-coverage/lib/python2.7/site-packages (from wcs==4.22.post2+g2b9bfd93.dirty) (4.5.3)
Requirement already satisfied: django-ratelimit<3 in /tmp/tox-bdauvergne/wcs/py2-pylint-coverage/lib/python2.7/site-packages (from wcs==4.22.post2+g2b9bfd93.dirty) (2.0.0)
Collecting XStatic-Leaflet (from wcs==4.22.post2+g2b9bfd93.dirty)
Requirement already satisfied: pyproj in /tmp/tox-bdauvergne/wcs/py2-pylint-coverage/lib/python2.7/site-packages (from wcs==4.22.post2+g2b9bfd93.dirty) (2.2.2)
Requirement already satisfied: XStatic-OpenSans in /tmp/tox-bdauvergne/wcs/py2-pylint-coverage/lib/python2.7/site-packages (from gadjo>=0.53->wcs==4.22.post2+g2b9bfd93.dirty) (1.0.0)
Requirement already satisfied: XStatic in /tmp/tox-bdauvergne/wcs/py2-pylint-coverage/lib/python2.7/site-packages (from gadjo>=0.53->wcs==4.22.post2+g2b9bfd93.dirty) (1.0.2)
Requirement already satisfied: XStatic-Font-Awesome in /tmp/tox-bdauvergne/wcs/py2-pylint-coverage/lib/python2.7/site-packages (from gadjo>=0.53->wcs==4.22.post2+g2b9bfd93.dirty) (4.7.0.0)
Requirement already satisfied: XStatic-jquery-ui in /tmp/tox-bdauvergne/wcs/py2-pylint-coverage/lib/python2.7/site-packages (from gadjo>=0.53->wcs==4.22.post2+g2b9bfd93.dirty) (1.12.1.1)
Requirement already satisfied: XStatic-jQuery<2 in /tmp/tox-bdauvergne/wcs/py2-pylint-coverage/lib/python2.7/site-packages (from gadjo>=0.53->wcs==4.22.post2+g2b9bfd93.dirty) (1.12.4.1)
Requirement already satisfied: Django in /tmp/tox-bdauvergne/wcs/py2-pylint-coverage/lib/python2.7/site-packages (from django-ckeditor<=4.5.3->wcs==4.22.post2+g2b9bfd93.dirty) (1.11.25)
Requirement already satisfied: aenum; python_version < "3.6" in /tmp/tox-bdauvergne/wcs/py2-pylint-coverage/lib/python2.7/site-packages (from pyproj->wcs==4.22.post2+g2b9bfd93.dirty) (2.2.1)
Requirement already satisfied: pytz in /tmp/tox-bdauvergne/wcs/py2-pylint-coverage/lib/python2.7/site-packages (from Django->django-ckeditor<=4.5.3->wcs==4.22.post2+g2b9bfd93.dirty) (2019.3)
Building wheels for collected packages: wcs
  Building wheel for wcs (setup.py): started
  Building wheel for wcs (setup.py): finished with status 'error'
  ERROR: Command errored out with exit status 1:
   command: /tmp/tox-bdauvergne/wcs/py2-pylint-coverage/bin/python -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-req-build-7wBrFa/setup.py'"'"'; __file__='"'"'/tmp/pip-req-build-7wBrFa/setup.py'"'"';f=getattr(tokenize, '"'"'open'"'"', open)(__file__);code=f.read().replace('"'"'\r\n'"'"', '"'"'\n'"'"');f.close();exec(compile(code, __file__, '"'"'exec'"'"'))' bdist_wheel -d /tmp/pip-wheel-0JPF8V --python-tag cp27
       cwd: /tmp/pip-req-build-7wBrFa/
  Complete output (6 lines):
  running bdist_wheel
  running build
  running compile_translations
  !!! Please install Django >= 1.4 to build translations
  running build_py
  error: package directory 'wcs' does not exist
  ----------------------------------------
  ERROR: Failed building wheel for wcs
  Running setup.py clean for wcs
Failed to build wcs
Installing collected packages: XStatic-Leaflet, wcs
  Found existing installation: wcs 4.22.post2+g2b9bfd93.dirty
    Not uninstalling wcs at /home/bdauvergne/wd/eo/wcs, outside environment /tmp/tox-bdauvergne/wcs/py2-pylint-coverage
    Can't uninstall 'wcs'. No files were found to uninstall.
  Running setup.py install for wcs: started
    Running setup.py install for wcs: finished with status 'error'
    ERROR: Command errored out with exit status 1:
     command: /tmp/tox-bdauvergne/wcs/py2-pylint-coverage/bin/python -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-req-build-7wBrFa/setup.py'"'"'; __file__='"'"'/tmp/pip-req-build-7wBrFa/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-record-Nit5k8/install-record.txt --single-version-externally-managed --compile --install-headers /tmp/tox-bdauvergne/wcs/py2-pylint-coverage/include/site/python2.7/wcs
         cwd: /tmp/pip-req-build-7wBrFa/
    Complete output (6 lines):
    running install
    running build
    running compile_translations
    !!! Please install Django >= 1.4 to build translations
    running build_py
    error: package directory 'wcs' does not exist
    ----------------------------------------
  ERROR: Can't roll back wcs; was not uninstalled
ERROR: Command errored out with exit status 1: /tmp/tox-bdauvergne/wcs/py2-pylint-coverage/bin/python -u -c 'import sys, setuptools, tokenize; sys.argv[0] = '"'"'/tmp/pip-req-build-7wBrFa/setup.py'"'"'; __file__='"'"'/tmp/pip-req-build-7wBrFa/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-record-Nit5k8/install-record.txt --single-version-externally-managed --compile --install-headers /tmp/tox-bdauvergne/wcs/py2-pylint-coverage/include/site/python2.7/wcs Check the logs for full command output.

================================================================================== log end ==================================================================================
__________________________________________________________________________________ summary __________________________________________________________________________________
ERROR:   py2-pylint-coverage: InvocationError for command /tmp/tox-bdauvergne/wcs/py2-pylint-coverage/bin/python -m pip install --exists-action w /tmp/tox-bdauvergne/wcs/.tmp/package/1/wcs-4.22.post2+g2b9bfd93.dirty.zip (exited with code 1)

#2

Mis à jour par Frédéric Péters il y a plus de 4 ans

Et pourtant le Jenkinsfile utilise tox.

#3

Mis à jour par Benjamin Dauvergne il y a plus de 4 ans

  • Sujet changé de tox.ini ne fonctione pas à tox.ini ne fonctionne pas
#4

Mis à jour par Benjamin Dauvergne il y a plus de 4 ans

  • Statut changé de Nouveau à Rejeté

J'ai désinstallé pytest de ~/.local et ça passe, ça reste bizarre.

Formats disponibles : Atom PDF